From 3ceaed43ab2a1a1d4d29d6c8bf8a5d310a7adbff Mon Sep 17 00:00:00 2001 From: "Hiral Patel (OpenERP)" Date: Tue, 25 Sep 2012 12:21:11 +0530 Subject: [PATCH] [IMP] Remove error message in Firefox on clicking on an arrow in the left of a feed and on remove notification/quote and reply bzr revid: hip@tinyerp.com-20120925065111-nwib72381na57g7n --- addons/mail/static/src/js/mail.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/addons/mail/static/src/js/mail.js b/addons/mail/static/src/js/mail.js index 57c777441e7..eacd00e7b77 100644 --- a/addons/mail/static/src/js/mail.js +++ b/addons/mail/static/src/js/mail.js @@ -349,7 +349,7 @@ openerp.mail = function(session) { // event: click on 'Reply by email' in msg side menu this.$el.on('click', 'a.oe_mail_msg_reply_by_email', function (event) { if (! self.compose_message_widget) return true; - var msg_id = event.srcElement.dataset.msg_id; + var msg_id = event.target.dataset.msg_id || event.srcElement.dataset.msg_id; if (! msg_id) return false; self.compose_message_widget.refresh({ 'default_composition_mode': 'reply', @@ -370,9 +370,9 @@ openerp.mail = function(session) { on_message_read: function (event) { //TDE: TODO - var msg_id = event.srcElement.dataset.id; + var msg_id = event.target.dataset.id || event.srcElement.dataset.id; if (! msg_id) return false; - $(event.srcElement).parents('li.oe_mail_thread_msg').eq(0).remove(); + $(event.target || event.srcElement).parents('li.oe_mail_thread_msg').eq(0).remove(); return this.ds_notification.call('set_message_read', [parseInt(msg_id)]); },