From 4bf4a73a4a0f047b8c1a8fded181e51c258ba33a Mon Sep 17 00:00:00 2001 From: guy Date: Fri, 31 Mar 2017 14:41:28 +0800 Subject: [PATCH] add --- bi/core.js | 7 +++++-- dist/core.js | 7 +++++-- src/core/controller/controller.floatbox.js | 7 +++++-- 3 files changed, 15 insertions(+), 6 deletions(-) diff --git a/bi/core.js b/bi/core.js index e47cc4482b..8bc0d4a399 100644 --- a/bi/core.js +++ b/bi/core.js @@ -15623,6 +15623,7 @@ BI.FloatBoxController = BI.inherit(BI.Controller, { this.floatManager = {}; this.floatLayer = {}; this.floatContainer = {}; + this.floatOpened = {}; this.zindex = BI.zIndex_floatbox; this.zindexMap = {}; }, @@ -15687,7 +15688,8 @@ BI.FloatBoxController = BI.inherit(BI.Controller, { if (!this._check(name)) { return this; } - if (!this.floatContainer[name].isVisible()) { + if (!this.floatOpened[name]) { + this.floatOpened[name] = true; var container = this.floatContainer[name]; container.element.css("zIndex", this.zindex++); this.modal && container.element.__hasZIndexMask__(this.zindexMap[name]) && container.element.__releaseZIndexMask__(this.zindexMap[name]); @@ -15718,7 +15720,8 @@ BI.FloatBoxController = BI.inherit(BI.Controller, { if (!this._check(name)) { return this; } - if (this.floatContainer[name].isVisible()) { + if (this.floatOpened[name]) { + delete this.floatOpened[name]; this.floatContainer[name].invisible(); this.modal && this.floatContainer[name].element.__releaseZIndexMask__(this.zindexMap[name]); } diff --git a/dist/core.js b/dist/core.js index 9c8a9f4bfe..534d267bf3 100644 --- a/dist/core.js +++ b/dist/core.js @@ -20696,6 +20696,7 @@ BI.FloatBoxController = BI.inherit(BI.Controller, { this.floatManager = {}; this.floatLayer = {}; this.floatContainer = {}; + this.floatOpened = {}; this.zindex = BI.zIndex_floatbox; this.zindexMap = {}; }, @@ -20760,7 +20761,8 @@ BI.FloatBoxController = BI.inherit(BI.Controller, { if (!this._check(name)) { return this; } - if (!this.floatContainer[name].isVisible()) { + if (!this.floatOpened[name]) { + this.floatOpened[name] = true; var container = this.floatContainer[name]; container.element.css("zIndex", this.zindex++); this.modal && container.element.__hasZIndexMask__(this.zindexMap[name]) && container.element.__releaseZIndexMask__(this.zindexMap[name]); @@ -20791,7 +20793,8 @@ BI.FloatBoxController = BI.inherit(BI.Controller, { if (!this._check(name)) { return this; } - if (this.floatContainer[name].isVisible()) { + if (this.floatOpened[name]) { + delete this.floatOpened[name]; this.floatContainer[name].invisible(); this.modal && this.floatContainer[name].element.__releaseZIndexMask__(this.zindexMap[name]); } diff --git a/src/core/controller/controller.floatbox.js b/src/core/controller/controller.floatbox.js index b06e9723b0..e700f34f36 100644 --- a/src/core/controller/controller.floatbox.js +++ b/src/core/controller/controller.floatbox.js @@ -18,6 +18,7 @@ BI.FloatBoxController = BI.inherit(BI.Controller, { this.floatManager = {}; this.floatLayer = {}; this.floatContainer = {}; + this.floatOpened = {}; this.zindex = BI.zIndex_floatbox; this.zindexMap = {}; }, @@ -82,7 +83,8 @@ BI.FloatBoxController = BI.inherit(BI.Controller, { if (!this._check(name)) { return this; } - if (!this.floatContainer[name].isVisible()) { + if (!this.floatOpened[name]) { + this.floatOpened[name] = true; var container = this.floatContainer[name]; container.element.css("zIndex", this.zindex++); this.modal && container.element.__hasZIndexMask__(this.zindexMap[name]) && container.element.__releaseZIndexMask__(this.zindexMap[name]); @@ -113,7 +115,8 @@ BI.FloatBoxController = BI.inherit(BI.Controller, { if (!this._check(name)) { return this; } - if (this.floatContainer[name].isVisible()) { + if (this.floatOpened[name]) { + delete this.floatOpened[name]; this.floatContainer[name].invisible(); this.modal && this.floatContainer[name].element.__releaseZIndexMask__(this.zindexMap[name]); }