Skip to content

Commit

Permalink
Fix for IE8, test will probably fail on IE8
Browse files Browse the repository at this point in the history
  • Loading branch information
Waxolunist committed Jul 4, 2014
1 parent 1c2f4e2 commit 37f6fee
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions src/views/composer.observe.js
Original file line number Diff line number Diff line change
Expand Up @@ -160,8 +160,11 @@

dom.observe(focusBlurElement, "blur", function(event) {
if (state !== that.getValue(false, false)) {
//create change event
var changeevent = Object.create(event, { type: { value: 'change' } });
//create change event if supported (all except IE8)
var changeevent = event;
if(typeof Object.create == 'function') {
changeevent = Object.create(event, { type: { value: 'change' } });
}
that.parent.fire("change", changeevent).fire("change:composer", changeevent);
}
that.parent.fire("blur", event).fire("blur:composer", event);
Expand Down

0 comments on commit 37f6fee

Please sign in to comment.