From: Michael M Slusarz Date: Mon, 10 May 2010 20:51:04 +0000 (-0600) Subject: Bug #9010: IE doesn't bubble change events X-Git-Url: https://git.internetallee.de/?a=commitdiff_plain;h=9bb02a6d29e69561c085953b33afd32e84a98639;p=horde.git Bug #9010: IE doesn't bubble change events --- diff --git a/imp/js/compose-dimp.js b/imp/js/compose-dimp.js index 36676269f..d973cd478 100644 --- a/imp/js/compose-dimp.js +++ b/imp/js/compose-dimp.js @@ -869,7 +869,12 @@ var DimpCompose = { } /* Attach event handlers. */ - document.observe('change', this.changeHandler.bindAsEventListener(this)); + if (Prototype.Browser.IE) { + // IE doesn't bubble change events. + $('identity', 'upload').invoke('observe', 'change', this.changeHandler.bindAsEventListener(this)); + } else { + document.observe('change', this.changeHandler.bindAsEventListener(this)); + } Event.observe(window, 'resize', this.resizeMsgArea.bind(this)); $('compose').observe('submit', Event.stop); $('submit_frame').observe('load', this.attachmentComplete.bind(this));