[fusion-commits] r2520 - sandbox/adsk/2.4jbeta2/lib
svn_fusion at osgeo.org
svn_fusion at osgeo.org
Tue Jan 17 05:05:58 EST 2012
Author: liuar
Date: 2012-01-17 02:05:58 -0800 (Tue, 17 Jan 2012)
New Revision: 2520
Modified:
sandbox/adsk/2.4jbeta2/lib/Widget.js
Log:
on behalf of libr(Bruce li)
Integration from trunk http://trac.osgeo.org/fusion/changeset/2518
Modified: sandbox/adsk/2.4jbeta2/lib/Widget.js
===================================================================
--- sandbox/adsk/2.4jbeta2/lib/Widget.js 2012-01-17 10:05:19 UTC (rev 2519)
+++ sandbox/adsk/2.4jbeta2/lib/Widget.js 2012-01-17 10:05:58 UTC (rev 2520)
@@ -119,11 +119,9 @@
if (uiObj.addEvents) {
if (Fusion.Widget.uiInstances[this.type][0].uiObj &&
Fusion.Widget.uiInstances[this.type][0].uiObj.options.active &&
- Fusion.Widget.uiInstances[this.type][0].shouldActivateWith(this)) {
- uiObj.options.active = true;
- if (uiObj.domA) {
- uiObj.domA.addClass('jx' + uiObj.options.type + 'Active');
- }
+ Fusion.Widget.uiInstances[this.type][0].shouldActivateWith(this) &&
+ uiObj.setActive) {
+ uiObj.setActive(true);
}
uiObj.addEvents({
@@ -134,11 +132,9 @@
var instances = Fusion.Widget.uiInstances[this.type];
for (var i=0; i<instances.length; i++) {
var instance = instances[i];
- if (instance.shouldActivateWith(this) && instance.uiObj) {
- instance.uiObj.options.active = false;
- if (instance.uiObj.domA) {
- instance.uiObj.domA.removeClass('jx' + instance.uiObj.options.type + 'Active');
- }
+ if (instance.shouldActivateWith(this) &&
+ instance.uiObj && instance.uiObj.setActive) {
+ instance.uiObj.setActive(false);
}
}
this.deactivate();
@@ -147,11 +143,9 @@
var instances = Fusion.Widget.uiInstances[this.type];
for (var i=0; i<instances.length; i++) {
var instance = instances[i];
- if (instance.shouldActivateWith(this) && instance.uiObj) {
- instance.uiObj.options.active = true;
- if (instance.uiObj.domA) {
- instance.uiObj.domA.addClass('jx' + instance.uiObj.options.type + 'Active');
- }
+ if (instance.shouldActivateWith(this) &&
+ instance.uiObj && instance.uiObj.setActive) {
+ instance.uiObj.setActive(true);
}
}
this.activate();
@@ -164,7 +158,7 @@
/**
*/
shouldActivateWith: function(widget) {
- return true;
+ return false;
},
/**
More information about the fusion-commits
mailing list