Permalink
Browse files

Prevent IE script errors. If IE does not have addEventListener, it al…

…so does not support postMessage. So, there's no reason to register event listeners on IE. IE will just have to be stuck with a fixed size for the embedded iframe.
  • Loading branch information...
1 parent be71025 commit 3a545030658955394c40dc2461500aeca62ed054 @inghamn inghamn committed Apr 11, 2012
Showing with 3 additions and 1 deletion.
  1. +3 −1 templates/html/embed.inc
View
@@ -15,7 +15,9 @@
HOST.origin = e.origin;
}
}
- window.addEventListener('message',handleMessage,false);
+ if (window.addEventListener) {
+ window.addEventListener('message',handleMessage,false);
+ }
</script>
<div id="panel-container">
<div id="content-panel">

0 comments on commit 3a54503

Please sign in to comment.