From 90db80ccef32c1e94982ab64c890098b2182d874 Mon Sep 17 00:00:00 2001
From: windy <1374721899@qq.com>
Date: Mon, 18 Sep 2017 14:00:30 +0800
Subject: [PATCH 1/5] IE8
---
bi/base.js | 2650 ++++++++++++++++++++++----------------------
bi/core.js | 2 +-
dist/bundle.js | 2 +-
dist/bundle.min.js | 2 +-
dist/core.js | 2 +-
src/core/model.js | 2 +-
6 files changed, 1330 insertions(+), 1330 deletions(-)
diff --git a/bi/base.js b/bi/base.js
index eec4127f4..b66938bc2 100644
--- a/bi/base.js
+++ b/bi/base.js
@@ -16086,1331 +16086,1331 @@ BI.Pager = BI.inherit(BI.Widget, {
});
BI.Pager.EVENT_CHANGE = "EVENT_CHANGE";
BI.Pager.EVENT_AFTER_POPULATE = "EVENT_AFTER_POPULATE";
-BI.shortcut("bi.pager", BI.Pager);!(function(){
- var bkExtend = function(){
- var args = arguments;
- if (args.length == 1) args = [this, args[0]];
- for (var prop in args[1]) args[0][prop] = args[1][prop];
- return args[0];
- };
- function bkClass() { }
- bkClass.prototype.construct = function() {};
- bkClass.extend = function(def) {
- var classDef = function() {
- if (arguments[0] !== bkClass) { return this.construct.apply(this, arguments); }
- };
- var proto = new this(bkClass);
- bkExtend(proto,def);
- classDef.prototype = proto;
- classDef.extend = this.extend;
- return classDef;
- };
-
- var bkElement = bkClass.extend({
- construct : function(elm,d) {
- if(typeof(elm) == "string") {
- elm = (d || document).createElement(elm);
- }
- elm = $BK(elm);
- return elm;
- },
-
- appendTo : function(elm) {
- elm.appendChild(this);
- return this;
- },
-
- appendBefore : function(elm) {
- elm.parentNode.insertBefore(this,elm);
- return this;
- },
-
- addEvent : function(type, fn) {
- bkLib.addEvent(this,type,fn);
- return this;
- },
-
- setContent : function(c) {
- this.innerHTML = c;
- return this;
- },
-
- pos : function() {
- var curleft = curtop = 0;
- var o = obj = this;
- if (obj.offsetParent) {
- do {
- curleft += obj.offsetLeft;
- curtop += obj.offsetTop;
- } while (obj = obj.offsetParent);
- }
- var b = (!window.opera) ? parseInt(this.getStyle('border-width') || this.style.border) || 0 : 0;
- return [curleft+b,curtop+b+this.offsetHeight];
- },
-
- noSelect : function() {
- bkLib.noSelect(this);
- return this;
- },
-
- parentTag : function(t) {
- var elm = this;
- do {
- if(elm && elm.nodeName && elm.nodeName.toUpperCase() == t) {
- return elm;
- }
- elm = elm.parentNode;
- } while(elm);
- return false;
- },
-
- hasClass : function(cls) {
- return this.className.match(new RegExp('(\\s|^)nicEdit-'+cls+'(\\s|$)'));
- },
-
- addClass : function(cls) {
- if (!this.hasClass(cls)) { this.className += " nicEdit-"+cls };
- return this;
- },
-
- removeClass : function(cls) {
- if (this.hasClass(cls)) {
- this.className = this.className.replace(new RegExp('(\\s|^)nicEdit-'+cls+'(\\s|$)'),' ');
- }
- return this;
- },
-
- setStyle : function(st) {
- var elmStyle = this.style;
- for(var itm in st) {
- switch(itm) {
- case 'float':
- elmStyle['cssFloat'] = elmStyle['styleFloat'] = st[itm];
- break;
- case 'opacity':
- elmStyle.opacity = st[itm];
- elmStyle.filter = "alpha(opacity=" + Math.round(st[itm]*100) + ")";
- break;
- case 'className':
- this.className = st[itm];
- break;
- default:
- //if(document.compatMode || itm != "cursor") { // Nasty Workaround for IE 5.5
- elmStyle[itm] = st[itm];
- //}
- }
- }
- return this;
- },
-
- getStyle : function( cssRule, d ) {
- var doc = (!d) ? document.defaultView : d;
- if(this.nodeType == 1)
- return (doc && doc.getComputedStyle) ? doc.getComputedStyle( this, null ).getPropertyValue(cssRule) : this.currentStyle[ bkLib.camelize(cssRule) ];
- },
-
- remove : function() {
- this.parentNode.removeChild(this);
- return this;
- },
-
- setAttributes : function(at) {
- for(var itm in at) {
- this[itm] = at[itm];
- }
- return this;
- }
- });
-
- var bkLib = {
- isMSIE : (navigator.appVersion.indexOf("MSIE") != -1),
-
- addEvent : function(obj, type, fn) {
- (obj.addEventListener) ? obj.addEventListener( type, fn, false ) : obj.attachEvent("on"+type, fn);
- },
-
- toArray : function(iterable) {
- var length = iterable.length, results = new Array(length);
- while (length--) { results[length] = iterable[length] };
- return results;
- },
-
- noSelect : function(element) {
- if(element.setAttribute && element.nodeName.toLowerCase() != 'input' && element.nodeName.toLowerCase() != 'textarea') {
- element.setAttribute('unselectable','on');
- }
- for(var i=0;i');
- }
- this.instanceDoc = document.defaultView;
- this.elm.addEvent('mousedown',this.selected.closureListener(this)).addEvent('keypress',this.keyDown.closureListener(this)).addEvent('focus',this.selected.closure(this)).addEvent('blur',this.blur.closure(this)).addEvent('keyup',this.selected.closure(this));
- this.ne.fireEvent('add',this);
- },
-
- remove : function() {
- this.saveContent();
- if(this.copyElm || this.options.hasPanel) {
- this.editorContain.remove();
- this.e.setStyle({'display' : 'block'});
- this.ne.removePanel();
- }
- this.disable();
- this.ne.fireEvent('remove',this);
- },
-
- disable : function() {
- this.elm.setAttribute('contentEditable','false');
- },
-
- getSel : function() {
- return (window.getSelection) ? window.getSelection() : document.selection;
- },
-
- getRng : function() {
- var s = this.getSel();
- if(!s || s.rangeCount === 0) { return; }
- return (s.rangeCount > 0) ? s.getRangeAt(0) : s.createRange();
- },
-
- selRng : function(rng,s) {
- if(window.getSelection) {
- s.removeAllRanges();
- s.addRange(rng);
- } else {
- rng.select();
- }
- },
-
- selElm : function() {
- var r = this.getRng();
- if(!r) { return; }
- if(r.startContainer) {
- var contain = r.startContainer;
- if(r.cloneContents().childNodes.length == 1) {
- for(var i=0;i'+((css) ? '' : '')+''+this.initialContent+'