Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
Clear All
new posts

    menu items keys

    SmartClient Version: v12.0p_2018-05-26/AllModules Development Only (built 2018-05-26)

    Chrome on OSX

    please try this sample in the showcase:
    Code:
    var menuItems = [
            {title: "test", keyTitle: "Alt+A", keys: {altKey: true, keyName: "A"}, click:"isc.logEcho('Alt+A pressed')"}
        ];
    isc.Menu.create({
        ID: "menu",
        autoDraw: false,
        showShadow: true,
        shadowDepth: 10
    });
    
    menu.setData(menuItems);
    
    var menuButton = isc.MenuButton.create({
        ID: "menuButton",
        autoDraw: false,
        title: "File",
        width: 100,
        menu: menu
    });
    
    isc.HStack.create({
        width: "100%",
        members: [menuButton]
    });
    you'll see that the shortcut key does not work.

    It only works if I declare the menu items at init time:

    Code:
    var menuItems = [
            {title: "test", keyTitle: "Alt+A", keys: {altKey: true, keyName: "A"}, click:"isc.logEcho('Alt+A pressed')"}
        ];
    isc.Menu.create({
        ID: "menu",
        autoDraw: false,
        showShadow: true,
        shadowDepth: 10,
        data: menuItems
    });
    
    var menuButton = isc.MenuButton.create({
        ID: "menuButton",
        autoDraw: false,
        title: "File",
        width: 100,
        menu: menu
    });
    
    isc.HStack.create({
        width: "100%",
        members: [menuButton]
    });
    Is it a bug, or is it by design? This is stopping me from changing the menu items at runtime.

    #2
    We've made a change to address this issue. Please try the next nightly build, dated May 31.

    Regards
    Isomorphic Software

    Comment


      #3
      Thanks, did you fix it in 11.1 also?
      I made the test case using the 12.0 online showcase, but I forgot to mention that I'm using 11.1 builds.

      Comment


        #4
        I see that it's not fixed in 11.1:

        SmartClient Version: v11.1p_2018-06-02/AllModules Development Only (built 2018-06-02)

        Could you please port the fix to 11.1 ?

        Comment


          #5
          The fix has been backported to 11.1. Please try the next nightly build, dated June 05.

          Regards
          Isomorphic Software

          Comment

          Working...
          X