Announcement

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

    Is it possible to get a reference to the containing SectionStackSection of an object

    Hi Isomorphic.

    Is it possible to get a reference to the SectionStackSection containing one of my presentation objects (for which I do have a reference)?

    My use case is simple: I need to be able to select one Tab (whose reference I hold in a HashMap for this purpose) in response to a user performing an action or clicking on a button, and if the SectionStackSection is collapsed, I need to also expand it (so that I can effectively show the Tab). Now, from the tab I am able to get:

    Code:
    TabSet ts = targetTab.getTabSet() // the TabSet it belongs to
    Canvas ss = ts.getMasterCanvas() // the SectionStack the TabSet belongs to
    Canvas ss = getParentCanvas() // same as getMasterCanvas()
    But I haven't found an API that will return the actual SectionStackSection the Tab (or TabSet) is located on. And for what I read here, I don't know if this is possible?

    So, if it is possible, would you please point me in the right direction?

    Thanks!

    SmartGWT 6.0p 2016-05-31

    #2
    If this component needs a reference to the SectionStackSecrion you should pass it to the component after the SectionStack is drawn.

    While you could navigate the parent chain and locate the SectionStackSection (it will be a sibling of the components in the section), this would be relying on details of the hierarchy which are not documented and are subject to change.

    Comment


      #3
      Thanks Isomorphic.

      Comment

      Working...
      X