-
14 Nov 2011 4:09 AM #1
[FNR] TabPanel.update(Widget, TabItemConfig) removes styling
[FNR] TabPanel.update(Widget, TabItemConfig) removes styling
In order to change the caption for tabs after they have been added, I tried to use TabPanel.update as described here: http://dev.sencha.com/deploy/gxt-3.0...temConfig.html
The update itself is working, but the Styling/HTML of the tab header gets fully lost. You can test this issue, with the following code:
Code:public class MyModule implements EntryPoint { public void onModuleLoad() { BorderLayoutContainer container = new BorderLayoutContainer(); container.setWidth(500); container.setHeight(500); final TabPanel tabs = new TabPanel(); final ContentPanel cp1 = new ContentPanel(); cp1.setHeadingHtml("Tab 1 Headline"); final TabItemConfig tabItem1Config = new TabItemConfig("Tab 1"); tabs.add(cp1, tabItem1Config); ContentPanel cp2 = new ContentPanel(); cp2.setHeadingHtml("Tab 2 Headline"); TabItemConfig tabItem2Config = new TabItemConfig("Tab 2"); tabs.add(cp2, tabItem2Config); Button b = new Button("Update the caption for Tab 1"); b.addClickHandler(new ClickHandler () { @Override public void onClick(ClickEvent event) { tabItem1Config.setHTML("New Tab 1"); tabs.update(cp1, tabItem1Config); } }); BorderLayoutData layoutData = new BorderLayoutData(100); container.setCenterWidget(tabs, layoutData); container.setNorthWidget(b, layoutData); RootLayoutPanel.get().add(container); } }
-
21 Nov 2011 5:42 AM #2
Any reaction? Did anybody from the GXT dev team try to reproduce this error with the test case I provided?
-
21 Nov 2011 5:47 AM #3
We bugreport was noted and will be looked into. Please keep in mind that we are still in pre beta stage.
-
29 Nov 2011 1:12 PM #4
Thanks for bringing this to our attention. This bug is now fixed in SVN.
Thank you for reporting this bug. We will make it our priority to review this report.


Reply With Quote