Minor Update
git-svn-id: https://svn.d4science.research-infrastructures.eu/gcube/trunk/portlets/user/tabular-data-portlet@94964 82a268e6-3cf1-43bd-a215-b396298e98cf
This commit is contained in:
parent
8b1ec0fecb
commit
2927ffafd4
|
@ -399,7 +399,7 @@ public class TabularDataController {
|
|||
break;
|
||||
case HISTORY:
|
||||
break;
|
||||
case DISCARD:
|
||||
case UNDO:
|
||||
callDiscard();
|
||||
break;
|
||||
case DISCARDALL:
|
||||
|
|
|
@ -63,8 +63,8 @@ public class FileToolBar {
|
|||
|
||||
// History
|
||||
protected TextButton historyButton;
|
||||
protected TextButton discardButton;
|
||||
protected TextButton discardAllButton;
|
||||
protected TextButton undoButton;
|
||||
//protected TextButton discardAllButton;
|
||||
|
||||
protected TextButton helpButton;
|
||||
|
||||
|
@ -440,19 +440,23 @@ public class FileToolBar {
|
|||
historyLayout.setWidget(0, 0, historyButton);
|
||||
historyLayout.getFlexCellFormatter().setRowSpan(0, 0, 2);
|
||||
|
||||
discardButton = new TextButton("Discard",
|
||||
TabularDataResources.INSTANCE.discard());
|
||||
discardButton.disable();
|
||||
discardButton.setToolTip("Discard the last operation");
|
||||
historyLayout.setWidget(0, 1, discardButton);
|
||||
discardButton.addSelectHandler(new SelectHandler() {
|
||||
undoButton = new TextButton("Undo",
|
||||
TabularDataResources.INSTANCE.discard32());
|
||||
undoButton.disable();
|
||||
undoButton.setScale(ButtonScale.LARGE);
|
||||
undoButton.setIconAlign(IconAlign.TOP);
|
||||
undoButton.setToolTip("Discard last operation");
|
||||
undoButton.setArrowAlign(ButtonArrowAlign.BOTTOM);
|
||||
undoButton.addSelectHandler(new SelectHandler() {
|
||||
|
||||
public void onSelect(SelectEvent event) {
|
||||
eventBus.fireEvent(new RibbonEvent(RibbonType.DISCARD));
|
||||
eventBus.fireEvent(new RibbonEvent(RibbonType.UNDO));
|
||||
}
|
||||
});
|
||||
historyLayout.setWidget(0, 1, undoButton);
|
||||
historyLayout.getFlexCellFormatter().setRowSpan(0, 1, 2);
|
||||
|
||||
discardAllButton = new TextButton("Discard All",
|
||||
/*discardAllButton = new TextButton("Discard All",
|
||||
TabularDataResources.INSTANCE.discardAll());
|
||||
discardAllButton.disable();
|
||||
discardAllButton.setToolTip("Discard all unsaved operations");
|
||||
|
@ -462,7 +466,7 @@ public class FileToolBar {
|
|||
public void onSelect(SelectEvent event) {
|
||||
eventBus.fireEvent(new RibbonEvent(RibbonType.DISCARDALL));
|
||||
}
|
||||
});
|
||||
});*/
|
||||
|
||||
cleanCells(historyLayout.getElement());
|
||||
|
||||
|
@ -538,8 +542,8 @@ public class FileToolBar {
|
|||
templateDeleteButton.enable();
|
||||
timelineButton.disable();
|
||||
historyButton.disable();
|
||||
discardButton.disable();
|
||||
discardAllButton.disable();
|
||||
undoButton.disable();
|
||||
//discardAllButton.disable();
|
||||
break;
|
||||
case TR_CLOSE:
|
||||
case TR_READONLY:
|
||||
|
@ -560,8 +564,8 @@ public class FileToolBar {
|
|||
templateDeleteButton.enable();
|
||||
timelineButton.disable();
|
||||
historyButton.disable();
|
||||
discardButton.disable();
|
||||
discardAllButton.disable();
|
||||
undoButton.disable();
|
||||
//discardAllButton.disable();
|
||||
break;
|
||||
case TR_OPEN:
|
||||
case TABLEUPDATE:
|
||||
|
@ -588,8 +592,8 @@ public class FileToolBar {
|
|||
templateDeleteButton.enable();
|
||||
timelineButton.enable();
|
||||
historyButton.enable();
|
||||
discardButton.enable();
|
||||
discardAllButton.disable();
|
||||
undoButton.enable();
|
||||
//discardAllButton.disable();
|
||||
break;
|
||||
case WIZARD_OPEN:
|
||||
openButton.disable();
|
||||
|
@ -609,8 +613,8 @@ public class FileToolBar {
|
|||
templateDeleteButton.disable();
|
||||
timelineButton.disable();
|
||||
historyButton.disable();
|
||||
discardButton.disable();
|
||||
discardAllButton.disable();
|
||||
undoButton.disable();
|
||||
//discardAllButton.disable();
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
|
|
Loading…
Reference in New Issue