olgacosta
olgacosta

Reputation: 1138

GWT and dynamic tabs

Is it possible to create panel with dynamic added tabs in GWT using TabPanel or TabLayoutPanel.

My requirements:

First tab is not closeable and has a celltable. When I select row in the celltable, new tab is created. Newly created tab can be closed. My question:

How to create this architecture in GWT using MVP style and UiBinder?

Upvotes: 0

Views: 879

Answers (1)

Pavlo K.
Pavlo K.

Reputation: 371

Why not? Even if you get some problem in GWT, you always can dive into level below to javascript and make exactly what you need.

Any panel can be dinamically changed. If it is layout panel then you can forceLayout() it at any moment. You can add() or insert() new items to panel and use different selfmade widgets for tabs (you have a lot of possibilities how to add or insert: add(Widget child, Widget tab) or add(Widget child, SafeHtml html)).

Here is an example how it made with ExtGWT, logic is identical but you will have to made widgets for your tabs (that can be closed and not).

Upvotes: 1

Related Questions