/** Remove all portlets (without recording them as closed in the user portlet cache) */ public void removeAllPortlets() { for (int col = 0; col < portletTabs.size(); col++) { List<TabItem> list = new ArrayList<TabItem>(portletTabs.get(col)); for (int row = 0; row < list.size(); row++) { TabItem tab = list.get(row); if (tab.getItemCount() > 0 && tab.getItem(0) instanceof AppPortlet) { AppPortlet appPortlet = (AppPortlet) tab.getItem(0); tab.remove(appPortlet); } tabPanel.remove(tab); } } portletTabs = new ArrayList<List<TabItem>>(); }