vendor/assets/javascripts/dojox/mobile/ListItem.js in dojox-rails-0.13.0 vs vendor/assets/javascripts/dojox/mobile/ListItem.js in dojox-rails-0.14.0
- old
+ new
@@ -43,14 +43,20 @@
_4.add(this.domNode,"mblVariableHeight");
this.defer(_3.hitch(this,"layoutVariableHeight"),0);
}
if(!this._isOnLine){
this._isOnLine=true;
-this.set({icon:this.icon,deleteIcon:this.deleteIcon,rightIcon:this.rightIcon,rightIcon2:this.rightIcon2});
+this.set({icon:this._pending_icon!==undefined?this._pending_icon:this.icon,deleteIcon:this._pending_deleteIcon!==undefined?this._pending_deleteIcon:this.deleteIcon,rightIcon:this._pending_rightIcon!==undefined?this._pending_rightIcon:this.rightIcon,rightIcon2:this._pending_rightIcon2!==undefined?this._pending_rightIcon2:this.rightIcon2,uncheckIcon:this._pending_uncheckIcon!==undefined?this._pending_uncheckIcon:this.uncheckIcon});
+delete this._pending_icon;
+delete this._pending_deleteIcon;
+delete this._pending_rightIcon;
+delete this._pending_rightIcon2;
+delete this._pending_uncheckIcon;
}
if(_e&&_e.select){
-this.set("checked",this.checked);
+this.set("checked",this._pendingChecked!==undefined?this._pendingChecked:this.checked);
+delete this._pendingChecked;
}
this.setArrow();
this.layoutChildren();
},layoutChildren:function(){
var _10;
@@ -161,10 +167,11 @@
}
}
return this.domNode.firstChild;
},_setIcon:function(_19,_1a){
if(!this._isOnLine){
+this["_pending_"+_1a]=_19;
return;
}
this._set(_1a,_19);
this[_1a+"Node"]=_9.setIcon(_19,this[_1a+"Pos"],this[_1a+"Node"],this[_1a+"Title"]||this.alt,this.domNode,this._findRef(_1a),"before");
if(this[_1a+"Node"]){
@@ -191,9 +198,10 @@
this._setIcon(_20,"uncheckIcon");
},_setRightIcon2Attr:function(_21){
this._setIcon(_21,"rightIcon2");
},_setCheckedAttr:function(_22){
if(!this._isOnLine){
+this._pendingChecked=_22;
return;
}
var _23=this.getParent();
if(_23&&_23.select==="single"&&_22){
_1.forEach(_23.getChildren(),function(_24){