Updated the behavior of the toolbox

git-svn-id: https://svn.d4science.research-infrastructures.eu/gcube/trunk/portlets/user/tabular-data-toolbox-widget@94958 82a268e6-3cf1-43bd-a215-b396298e98cf
This commit is contained in:
Giancarlo Panichi 2014-04-17 10:25:24 +00:00 committed by Giancarlo Panichi
parent 0871ca6bbd
commit 2147e6b014
1 changed files with 25 additions and 0 deletions

View File

@ -6,6 +6,7 @@ import org.gcube.portlets.user.td.widgetcommonevent.client.event.UIStateEvent;
import org.gcube.portlets.user.td.widgetcommonevent.client.event.WidgetRequestEvent;
import org.gcube.portlets.user.td.widgetcommonevent.client.type.UIStateType;
import org.gcube.portlets.user.td.widgetcommonevent.client.type.WidgetRequestType;
import org.gcube.portlets.user.td.widgetcommonevent.shared.TRId;
import com.allen_sauer.gwt.log.client.Log;
import com.google.web.bindery.event.shared.EventBus;
@ -100,8 +101,16 @@ public class ToolBoxPanel extends ContentPanel {
break;
case TR_OPEN:
//this.enable();
updateForOpenPanel();
break;
case TABLECURATION:
updateForCurationPanel(event.getTrId());
break;
case TABLEUPDATE:
updatePanel();
break;
case TR_READONLY:
break;
case WIZARD_OPEN:
//this.disable();
break;
@ -321,4 +330,20 @@ public class ToolBoxPanel extends ContentPanel {
}
}
public void updateForOpenPanel(){
if (state == ToolBoxPanelState.OPENED) {
toolBox.openPropertiesTab();
toolBox.updateTabs();
Log.debug("ToolBoxPanel Updated");
}
}
public void updateForCurationPanel(TRId trId){
if (state == ToolBoxPanelState.OPENED) {
toolBox.openValidationsTableTab(trId);
toolBox.updateTabs();
Log.debug("ToolBoxPanel Updated");
}
}
}