Success! Looks like we've fixed this one. According to our records the fix was applied for EXTJSIV-8167 in 4.2.0.265.
  1. #1
    Sencha User Daniil's Avatar
    Join Date
    Jun 2010
    Location
    Saint-Petersburg, Russia
    Posts
    687
    Vote Rating
    62
    Daniil is a jewel in the rough Daniil is a jewel in the rough Daniil is a jewel in the rough Daniil is a jewel in the rough

      0  

    Default [4.2.0 beta] Ext.menu.CheckItem: minor inconsistency with checked

    [4.2.0 beta] Ext.menu.CheckItem: minor inconsistency with checked


    REQUIRED INFORMATION

    Ext version tested:
    • Ext 4.2.0 beta
    Browser versions tested against:
    • FireFox
    DOCTYPE tested against:
    • <!DOCTYPE html>
    Description:
    • Just minor inconsistency with CheckItem. Its "checked" returns "undefined" before rendering, but "false" after.
    • Sure, it is not a big deal, because we always can use !!checked.
    • But, maybe, the getChecked method could be added which would always return a bool value.
    Steps to reproduce the problem:
    • Run the script
    • Click the "Get checked" button => undefined
    • Click the "Menu" button
    • Click the "Get checked" button => false
    The result that was expected:
    • false in the both cases.
    The result that occurs instead:
    • Before rendering - undefined, after rendering - false.
    Test Case:
    Code:
    Ext.create("Ext.button.Button", {
        id: "Button1",
        renderTo: Ext.getBody(),
        text: "Menu",
        menu: {
            items: {
                xtype: "menucheckitem",
                text: "Test item"
            }
        }
    });
    
    Ext.create("Ext.button.Button", {
        renderTo: Ext.getBody(),
        text: "Get checked",
        handler: function () {
            alert(Ext.getCmp("Button1").menu.items.get(0).checked);
        }
    });
    Ext.NET - ASP.NET for Ext JS
    MVC and WebForms
    Examples | Twitter

  2. #2
    Sencha - Senior Forum Manager mitchellsimoens's Avatar
    Join Date
    Mar 2007
    Location
    St. Louis, MO
    Posts
    33,656
    Vote Rating
    435
    mitchellsimoens has much to be proud of mitchellsimoens has much to be proud of mitchellsimoens has much to be proud of mitchellsimoens has much to be proud of mitchellsimoens has much to be proud of mitchellsimoens has much to be proud of mitchellsimoens has much to be proud of mitchellsimoens has much to be proud of mitchellsimoens has much to be proud of

      0  

    Default


    Thanks for the report! I have opened a bug in our bug tracker.