1. #1
    Sencha User
    Join Date
    Oct 2011
    Posts
    2
    Vote Rating
    0
    ateller101 is on a distinguished road

      0  

    Question Unanswered: can an 'x' or click-to-close icon be added to an overlay modal?

    Unanswered: can an 'x' or click-to-close icon be added to an overlay modal?


    Hi all, when following the example code for 'overlay' I notice that the overlay (as set to modal) pops up just fine and looks great, and I can configure the inside HTML as well as the titling of said modal.

    What I'd like to do is put an icon that dismisses the modal window when clicked and would like this icon to appear flush right following on the title of the modal overlay.

    Please consider the following code:

    Code:
    var overlay = new Ext.Panel({
            
                floating            : true,
                modal                : true,
                centered            : false,
                width                : Ext.is.Phone ? '95%' : '90%',
                height                : Ext.is.Phone ? 220 : '60%',
                styleHtmlContent    : true,
                dockedItems            : overlayTb,
                scroll                : 'vertical',
                contentEl            : 'lipsum',
                cls                    : 'htmlcontent'
            });
            var showCenteredOverlay = function(btn, event) {
                overlay.setCentered(true);
                overlayTb.setTitle('Centered Overlay Test');
                overlay.show();
            };
    The title of the overlay box is "Centered Overlay Test", and I find that if I click anywhere outside the overlay, then the overlay goes away. I'd actually like to leave it focused/active until a user clicks (let's say an 'X') icon to the far right of the overlay title bar in order to dismiss the overlay.

    I've checked through the API documentation and I'm not sure if it's a newb thing or if what I'd like to accomplish is not easily done. Any advice would be great. Thanks.
    Adam

  2. #2
    Sencha - Services Team
    Join Date
    Mar 2007
    Location
    Foristell, MO
    Posts
    1,107
    Answers
    12
    Vote Rating
    3
    jratcliff is on a distinguished road

      0  

    Default


    will the tools config work for you?
    Jack Ratcliff
    Sencha Inc, Green bleeding Senchan

    How to report a bug:
    http://www.sencha.com/forum/showthre...o-report-a-bug

  3. #3
    Ext JS Premium Member
    Join Date
    Feb 2009
    Posts
    422
    Answers
    4
    Vote Rating
    1
    Jangla is on a distinguished road

      0  

    Default


    Why are you using a Panel and not a Window? Ext.Window already has a close button.

Thread Participants: 2

Tags for this Thread

film izle

hd film izle

film sitesi

takipci kazanma sitesi

takipci kazanma sitesi

güzel olan herşey

takipci alma sitesi

komik eğlenceli videolar