Ticket #5351: tryMe.patch
| File tryMe.patch, 1.3 kB (added by dante, 12 months ago) |
|---|
-
Dialog.js
148 148 this.domNode.style.display="none"; 149 149 this.connect(this, "onExecute", "hide"); 150 150 this.connect(this, "onCancel", "hide"); 151 this._modalconnects = []; 151 152 }, 152 153 153 154 onLoad: function(){ … … 162 163 // time (but we defer it until right beforehand, for 163 164 // performance reasons) 164 165 165 this._modalconnects = [];166 167 166 if(this.titleBar){ 168 167 this._moveable = new dojo.dnd.Moveable(this.domNode, { handle: this.titleBar }); 169 168 } … … 281 280 show: function(){ 282 281 // summary: display the dialog 283 282 283 if(this.open){ return; } 284 284 285 // first time we show the dialog, there's some initialization stuff to do 285 286 if(!this._alreadyInitialized){ 286 287 this._setup(); … … 291 292 this._fadeOut.stop(); 292 293 } 293 294 295 this._modalconnects = []; 296 294 297 this._modalconnects.push(dojo.connect(window, "onscroll", this, "layout")); 295 298 this._modalconnects.push(dojo.connect(document.documentElement, "onkeypress", this, "_onKey")); 296 299 … … 346 349 this._underlay.layout(); 347 350 this._position(); 348 351 } 352 }, 353 354 destroy: function(){ 355 if(this.open){ 356 this._fadeOut.duration = 1; 357 this.hide(); 358 } 359 this.inherited(arguments); 349 360 } 350 361 } 351 362 );