Ticket #6739: dialog.patch

File dialog.patch, 1.5 kB (added by guest, 8 months ago)

Test case to show the problem

  • Dialog.js

     
    337337                        // summary: display the dialog 
    338338 
    339339                        if(this.open){ return; } 
    340                          
     340 
     341                        alert(this.domNode); 
    341342                        // first time we show the dialog, there's some initialization stuff to do                        
    342343                        if(!this._alreadyInitialized){ 
    343344                                this._setup(); 
  • tests/test_Dialog.html

     
    5959                        } 
    6060                        setTimeout(function(){thirdDlg.show();},"3000"); 
    6161                } 
     62 
     63                var invite; 
     64                dojo.addOnLoad(function() { 
     65                        invite = new dijit.Dialog({title: "TEST"}, dojo.byId('dialogTest')); 
     66                }); 
     67 
    6268        </script> 
    6369</head> 
    6470<body class="tundra"> 
     
    6672        <h1 class="testTitle">Dijit layout.Dialog tests</h1> 
    6773        <button dojoType="dijit.form.Button" onclick="dijit.byId('dialog1').show()">Show Dialog</button> | 
    6874 
     75    <a href="javascript:invite.show()" style="font-weight:bold;">Open Dialog</a> 
     76 
    6977        <div dojoType="dijit.Dialog" id="dialog1" title="First Dialog" 
    7078                        onfocus="console.log('user focus handler')" 
    7179                        onblur="console.log('user blur handler')" 
     
    98106                </table> 
    99107        </div> 
    100108 
    101  
     109        <div id="dialogTest"></div> 
     110      
    102111        <button dojoType="dijit.form.Button" onclick="createDialog()" title="shows after 3 second delay, with blue background">Programatic Dialog (3 second delay)</button> | 
    103112 
    104113