brud
brud

Reputation: 173

Vaadin: How to identify individual tabs in a TabSheet?

In Vaadin, say I have a Tabsheet, with several Tabs.

If I want to add subtabs to any of the Tabs in the Tabsheet, based on which Tab the subtabs have as their "parent" tab , how do I do this?

Upvotes: 0

Views: 906

Answers (1)

eeq
eeq

Reputation: 2118

Tabs are identified by the Component they hold. So, basically addanother TabSheet as a Tab to have subtabs:

TabSheet tabs = new TabSheet();
TabSheet subTabs = new TabSheet();      
tabs.addTab(subTabs, "Parent tab",null);
subTabs.addTab(new Label("Subtab content"), "Subtab",null);

Upvotes: 3

Related Questions