1. #1
    Touch Premium Member
    Join Date
    Mar 2007
    Posts
    67
    Vote Rating
    0
    JeffBurr is on a distinguished road

      0  

    Default Overlay closes parent

    Overlay closes parent


    I have a simple floating panel that is sliding in to cover the full screen. On this panel is a link to launch another floating panel which uses "showBy" to popup from a link.

    This works well, except that when the secondary panel displays, if you click it, the primary panel slides out and the secondary panel remains! I can't find any event that is firing...

    PHP Code:
    var detailPane Ext.extend(Ext.Panel, {
        
    floatingtrue,
        
    style'top:115px;',
        
    modalfalse,
        
    scroll'vertical',
        
    floatingCls'dtl-floating',
        
    width'100%',
        
    height880,
        
    datanull,
        
    layout'fit',
        
    dockedItems: [{
           
    dock'top',
           
    xytpe'panel',
           
    height70,
           
    cls'fp-artpop-tool'
        
    }],
        
    tpl : [
            
    '<div class="fp-artpop-head"><div>{title}</div></div>',
            
    '<div class="fp-artpop-subhead"><div>{subtitle}</div></div>',
            
    '<div class="fp-artpop-byline"><div>{byline}</div></div>',
            
    '<div class="fp-artpop-body">',
            
    '<tpl if="photo != null">',
               
    '<img src="{photo}" align="left" style="width:400px;margin:0px 0px 0px 0px;">',
            
    '</tpl>',
            
    '{body}</div>'
        
    ],    
        
    listeners: {
            
    afterrender: function() {
              if (!
    this.fakeback) {
                
    this.fakeback this.getEl().createChild({
                    
    cls'fakeback'
                
    });
                
    this.fakeback.setLeft(40);
                
    this.fakeback.setTop(20);
                
                
    this.fakeshare this.getEl().createChild({
                    
    cls'fakeshare'
                
    });
                
    this.fakeshare.setLeft(520);
                
    this.fakeshare.setTop(20);
                
                
    this.fakesave this.getEl().createChild({
                    
    cls'fakesave'
                
    });
                
    this.fakesave.setLeft(630);
                
    this.fakesave.setTop(20);

                
    this.fakeback.on({
            
    tapthis.closeme,
                    
    scopethis
                
    });
                
    this.fakeshare.on({
            
    tapthis.showOverlay,                
                    
    scopethis
                
    });
                
              }            
            }
        },
        
    closeme: function() {
            
    this.overlay.hide();
            
    this.hide('fade');
        },
        
    showOverlay: function(ebtn) {
            
    this.overlay.setCentered(false);
            
    this.overlay.showBy(btn);
        },
        
    overlay: new Ext.Panel({
            
    floatingtrue,
            
    modalfalse,
            
    centeredfalse,
            
    width250,
            
    height220,
            
    styleHtmlContenttrue,
            
    //dockedItems: overlayTb,
            
    scroll'vertical',
            
    contentEl'lipsum',
            
    cls'htmlcontent'
        
    })
    }); 
    Any suggestions?

  2. #2
    Touch Premium Member
    Join Date
    Mar 2007
    Posts
    67
    Vote Rating
    0
    JeffBurr is on a distinguished road

      0  

    Default SOLVED

    SOLVED


    Even though the initial panel is not modal, you apparently need to add

    hideOnMaskTap: false,

    This seems to solve the behavior.

Similar Threads

  1. Overlay close on click event (Sorry, one overlay at a time please!)
    By jeffj in forum Sencha Touch 1.x: Discussion
    Replies: 2
    Last Post: 17 Nov 2010, 3:54 AM
  2. What gets destroyed when a window closes ?
    By keckeroo in forum Ext 3.x: Help & Discussion
    Replies: 0
    Last Post: 9 Oct 2009, 8:59 AM
  3. DateField closes the parent Menu
    By ntulip in forum Ext 3.x: Help & Discussion
    Replies: 3
    Last Post: 18 Aug 2009, 5:31 AM
  4. Tab Closes Once but Not Twice
    By adbox in forum Ext 2.x: Help & Discussion
    Replies: 13
    Last Post: 7 Mar 2009, 11:14 PM