Results 1 to 2 of 2

Thread: [CLOSED][3.1.1] Strange behavior with LoadMask and Opera 10.50 Beta

    Thank you for reporting this bug. We will make it our priority to review this report.
  1. #1
    Ext JS Premium Member dtex-lab's Avatar
    Join Date
    Sep 2009
    Location
    Italy
    Posts
    411

    Default [CLOSED][3.1.1] Strange behavior with LoadMask and Opera 10.50 Beta

    If I instance a LoadMask as a global type, Opera 10.5 Beta have a strange behavior.
    When I call the hide() function, the message disappear... but windows is "freezed"..

    With FF, IE or Chrome it is working fine.

    As workaround is enough to set global variable in the onReady function..
    but I believe it is a bug.

    this is a test case:

    Code:
    <html>
    <head>
    <meta http-equiv='Content-Type' content='text/html; charset=UTF-8' />
    <link rel="stylesheet" type="text/css" href="lib/extjs/resources/css/ext-all.css" />
    <script type="text/javascript" src="lib/extjs/adapter/ext/ext-base.js"></script>
    <script type="text/javascript" src="lib/extjs/ext-all.js"></script>
    <script>
    var WAITING_MASK = new Ext.LoadMask(Ext.getBody(), {
        msg: "waiting opera..."
    });
    //var WAITING_MASK = null;
    Ext.onReady(function () {
        // IF I MOVE THE WAITING_MASK DECLARATION HERE IT IS WORKING. 
        //var WAITING_MASK = new Ext.LoadMask(Ext.getBody(), {msg:"waiting opera..."});
        //WAITING_MASK = new Ext.LoadMask(Ext.getBody(), {msg:"waiting opera..."});
        WAITING_MASK.show();
        new Ext.Viewport({
            layout: 'fit',
            items: {
                xtype: "form",
                items: {
                    xtype: 'textfield',
                    fieldLabel: "test field"
                }
            }
        });
        WAITING_MASK.hide();
    })
    </script>
    </head>
    </body>
    </html>
    If you change
    Code:
    var WAITING_MASK = new Ext.LoadMask(Ext.getBody(), {
        msg: "waiting opera..."
    });
    //var WAITING_MASK = null;
    ...
        //var WAITING_MASK = new Ext.LoadMask(Ext.getBody(), {msg:"waiting opera..."});
        //WAITING_MASK = new Ext.LoadMask(Ext.getBody(), {msg:"waiting opera..."});
        WAITING_MASK.show();
    to
    Code:
    //var WAITING_MASK = new Ext.LoadMask(Ext.getBody(), {
        msg: "waiting opera..."
    });
    var WAITING_MASK = null;
    ...
        //var WAITING_MASK = new Ext.LoadMask(Ext.getBody(), {msg:"waiting opera..."});
        WAITING_MASK = new Ext.LoadMask(Ext.getBody(), {msg:"waiting opera..."});
        WAITING_MASK.show();
    it is working with all browsers

    Ty
    we make IT work for you

  2. #2
    Sencha Premium User evant's Avatar
    Join Date
    Apr 2007
    Location
    Sydney, Australia
    Posts
    19,258

    Default

    Because it's trying to get a reference to the document body. Any dom related calls should be inside an onReady block.
    Twitter - @evantrimboli
    Former Sencha framework engineer, available for consulting.
    As of 2017-09-22 I am not employed by Sencha, all subsequent posts are my own and do not represent Sencha in any way.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •