From 419d9dc00165d2dfc35897610cc373bd393045b7 Mon Sep 17 00:00:00 2001 From: Giancarlo Panichi Date: Thu, 17 Apr 2014 10:38:25 +0000 Subject: [PATCH] Updated the behavior of the toolbox git-svn-id: https://svn.d4science.research-infrastructures.eu/gcube/trunk/portlets/user/tabular-data-toolbox-widget@94961 82a268e6-3cf1-43bd-a215-b396298e98cf --- .../td/toolboxwidget/client/ToolBoxPanel.java | 32 ++++++++++++++----- 1 file changed, 24 insertions(+), 8 deletions(-) diff --git a/src/main/java/org/gcube/portlets/user/td/toolboxwidget/client/ToolBoxPanel.java b/src/main/java/org/gcube/portlets/user/td/toolboxwidget/client/ToolBoxPanel.java index 46d97cd..4b32b12 100644 --- a/src/main/java/org/gcube/portlets/user/td/toolboxwidget/client/ToolBoxPanel.java +++ b/src/main/java/org/gcube/portlets/user/td/toolboxwidget/client/ToolBoxPanel.java @@ -149,7 +149,9 @@ public class ToolBoxPanel extends ContentPanel { } protected void doHistoryTab(){ - if (uiStateType == UIStateType.TR_OPEN) { + if (uiStateType == UIStateType.TR_OPEN + || uiStateType == UIStateType.TABLECURATION + || uiStateType == UIStateType.TABLEUPDATE) { if (state == ToolBoxPanelState.OPENED) { toolBox.openHistoryTab(); Log.debug("ToolBoxPanelSTate.OPENED Add Tabs"); @@ -166,7 +168,9 @@ public class ToolBoxPanel extends ContentPanel { protected void doColumnTypeChangeTab(WidgetRequestEvent event){ Log.debug("WidgetRequestEvent.CHANGECOLUMNTYPEPANEL : ["+event.getTrId()+" ,columnName: "+event.getColumnName()+"]"); - if (uiStateType == UIStateType.TR_OPEN) { + if (uiStateType == UIStateType.TR_OPEN + || uiStateType == UIStateType.TABLECURATION + || uiStateType == UIStateType.TABLEUPDATE) { if (state == ToolBoxPanelState.OPENED) { toolBox.openColumnTypeChangeTab(event.getTrId(), event.getColumnName()); Log.debug("ToolBoxPanelSTate.OPENED Add Tabs"); @@ -183,7 +187,9 @@ public class ToolBoxPanel extends ContentPanel { protected void doDeleteColumnTab(WidgetRequestEvent event){ Log.debug("WidgetRequestEvent.DeleteColumnPanel : ["+event.getTrId()+" ,columnName: "+event.getColumnName()+"]"); - if (uiStateType == UIStateType.TR_OPEN) { + if (uiStateType == UIStateType.TR_OPEN + || uiStateType == UIStateType.TABLECURATION + || uiStateType == UIStateType.TABLEUPDATE) { if (state == ToolBoxPanelState.OPENED) { toolBox.openDeleteColumnTab(event.getTrId(), event.getColumnName()); Log.debug("ToolBoxPanelSTate.OPENED Add Tabs"); @@ -200,7 +206,9 @@ public class ToolBoxPanel extends ContentPanel { protected void doLabelColumnTab(WidgetRequestEvent event){ Log.debug("WidgetRequestEvent.LabelColumnPanel : ["+event.getTrId()+" ,columnName: "+event.getColumnName()+"]"); - if (uiStateType == UIStateType.TR_OPEN) { + if (uiStateType == UIStateType.TR_OPEN + || uiStateType == UIStateType.TABLECURATION + || uiStateType == UIStateType.TABLEUPDATE) { if (state == ToolBoxPanelState.OPENED) { toolBox.openLabelColumnTab(event.getTrId(), event.getColumnName()); Log.debug("ToolBoxPanelSTate.OPENED Add Tabs"); @@ -218,7 +226,9 @@ public class ToolBoxPanel extends ContentPanel { protected void doChangeTableTypeTab(WidgetRequestEvent event){ Log.debug("WidgetRequestEvent.ChangeTableTypePanel : ["+event.getTrId()+"]"); - if (uiStateType == UIStateType.TR_OPEN) { + if (uiStateType == UIStateType.TR_OPEN + || uiStateType == UIStateType.TABLECURATION + || uiStateType == UIStateType.TABLEUPDATE) { if (state == ToolBoxPanelState.OPENED) { toolBox.openChangeTableTypeTab(event.getTrId()); Log.debug("ToolBoxPanelSTate.OPENED Add Tabs"); @@ -236,7 +246,9 @@ public class ToolBoxPanel extends ContentPanel { protected void doDuplicatesRowsTab(WidgetRequestEvent event){ Log.debug("WidgetRequestEvent.DuplicateRowsPanel : ["+event.getTrId()+"]"); - if (uiStateType == UIStateType.TR_OPEN) { + if (uiStateType == UIStateType.TR_OPEN + || uiStateType == UIStateType.TABLECURATION + || uiStateType == UIStateType.TABLEUPDATE) { if (state == ToolBoxPanelState.OPENED) { toolBox.openDuplicatesRowsTab(event.getTrId()); Log.debug("ToolBoxPanelSTate.OPENED Add Tabs"); @@ -253,7 +265,9 @@ public class ToolBoxPanel extends ContentPanel { protected void doValidationsTableTab(WidgetRequestEvent event){ Log.debug("WidgetRequestEvent.ValidationsTablePanel : ["+event.getTrId()+"]"); - if (uiStateType == UIStateType.TR_OPEN) { + if (uiStateType == UIStateType.TR_OPEN + || uiStateType == UIStateType.TABLECURATION + || uiStateType == UIStateType.TABLEUPDATE) { if (state == ToolBoxPanelState.OPENED) { toolBox.openValidationsTableTab(event.getTrId()); Log.debug("ToolBoxPanelSTate.OPENED Add Tabs"); @@ -271,7 +285,9 @@ public class ToolBoxPanel extends ContentPanel { protected void doPropertiesOpenTab(){ - if (uiStateType == UIStateType.TR_OPEN) { + if (uiStateType == UIStateType.TR_OPEN + || uiStateType == UIStateType.TABLECURATION + || uiStateType == UIStateType.TABLEUPDATE) { if (state == ToolBoxPanelState.OPENED) { toolBox.openPropertiesTab(); Log.debug("ToolBoxPanelSTate.OPENED Add Tabs");