Function.prototype.bind = function(obj) {
var fn = this, headArgs = Array.prototype.slice.call(arguments, 1);
- var binded = function(tailArgs) {
- var args = headArgs.concat(tailArgs);
+ var binded = function() {
+ var args = Array.prototype.concat.apply(headArgs, arguments);
return fn.apply(obj, args);
};
return binded;
};
})();
+
+// IE9 text/html data URI
+(function() {
+ if (document.documentMode !== 9)
+ return;
+ // overriding the src property
+ var originalSrcDescriptor = Object.getOwnPropertyDescriptor(
+ HTMLIFrameElement.prototype, 'src');
+ Object.defineProperty(HTMLIFrameElement.prototype, 'src', {
+ get: function() { return this.$src; },
+ set: function(src) {
+ this.$src = src;
+ if (src.substr(0, 14) != 'data:text/html') {
+ originalSrcDescriptor['set'].call(this, src);
+ return;
+ }
+ // for text/html, using blank document and then
+ // document's open, write, and close operations
+ originalSrcDescriptor['set'].call(this, 'about:blank');
+ setTimeout((function() {
+ var doc = this.contentDocument;
+ doc.open('text/html');
+ doc.write(src.substr(src.indexOf(',') + 1));
+ doc.close();
+ }).bind(this), 0);
+ },
+ enumerable: true
+ });
+})();
line-height: 32px;
}
+#controls > button > img {
+ width: 32px;
+ height: 32px;
+}
+
#controls > button[disabled] > img {
opacity: 0.5;
}
-webkit-box-shadow: 0px 4px 10px #000;
}
+#sidebarControls > button > img {
+ width: 32px;
+ height: 32px;
+}
+
#sidebarControls > button[disabled] > img {
opacity: 0.5;
}