Announcement

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

    How to replace the standard Columns selector menu

    I need to replace the Columns selector menu with a customized version. I have it working, but the way I'm identifying the Columns menu item is by it's title (getTitle().equals("Columns")). That won't work when the user chooses a different locale and the title gets translated into another language. Is there another way to identify the standard Columns menu item. I've dumped the javascript object for that menu item and couldn't see any other sort of identifying attribute. Is there some way to get the "Columns" title text in the current locale?

    #2
    While you could match field.title to menuItem.title, you probably do not want to try to reuse or modify the items being generated by SmartGWT here; the particular strategy they use is considered internal. Instead, just generate your own replacement items.

    Comment


      #3
      I am generating my own replacement items. In fact, I'm generating an entire replacement Menu for the Columns menu. I just need a way to identify the standard Columns menu (not the fields) so I can replace the entire Menu with another one. I think all I need to know is how to access the text for the "Columns" menu in the current locale.

      Comment


        #4
        Won't getFieldVisibilitySubmenuTitle() work for you? That is the what it is using to set the title.

        Comment

        Working...
        X