|
|
|
@ -1,13 +1,13 @@
|
|
|
|
|
package org.gcube.portlets.user.td.toolboxwidget.client;
|
|
|
|
|
|
|
|
|
|
import org.gcube.portlets.user.td.informationwidget.client.TabularResourceProperties;
|
|
|
|
|
import org.gcube.portlets.user.td.monitorwidget.client.background.MonitorBackgroundPanel;
|
|
|
|
|
import org.gcube.portlets.user.td.resourceswidget.client.ResourcesPanel;
|
|
|
|
|
import org.gcube.portlets.user.td.columnwidget.client.ChangeColumnTypePanel;
|
|
|
|
|
import org.gcube.portlets.user.td.columnwidget.client.DeleteColumnPanel;
|
|
|
|
|
import org.gcube.portlets.user.td.columnwidget.client.LabelColumnPanel;
|
|
|
|
|
import org.gcube.portlets.user.td.columnwidget.client.PositionColumnPanel;
|
|
|
|
|
import org.gcube.portlets.user.td.columnwidget.client.create.AddColumnPanel;
|
|
|
|
|
import org.gcube.portlets.user.td.informationwidget.client.TabularResourceProperties;
|
|
|
|
|
import org.gcube.portlets.user.td.monitorwidget.client.background.MonitorBackgroundPanel;
|
|
|
|
|
import org.gcube.portlets.user.td.resourceswidget.client.ResourcesPanel;
|
|
|
|
|
import org.gcube.portlets.user.td.tablewidget.client.ChangeTableTypePanel;
|
|
|
|
|
import org.gcube.portlets.user.td.tablewidget.client.geometry.GeometryCreatePointPanel;
|
|
|
|
|
import org.gcube.portlets.user.td.tablewidget.client.geospatial.DownscaleCSquarePanel;
|
|
|
|
@ -28,29 +28,26 @@ import org.gcube.portlets.user.tdcolumnoperation.client.MergeColumnPanel;
|
|
|
|
|
import org.gcube.portlets.user.tdcolumnoperation.client.SplitColumnPanel;
|
|
|
|
|
|
|
|
|
|
import com.allen_sauer.gwt.log.client.Log;
|
|
|
|
|
import com.google.gwt.core.client.GWT;
|
|
|
|
|
import com.google.gwt.user.client.ui.Widget;
|
|
|
|
|
import com.google.web.bindery.event.shared.EventBus;
|
|
|
|
|
import com.sencha.gxt.widget.core.client.FramedPanel;
|
|
|
|
|
import com.sencha.gxt.widget.core.client.TabItemConfig;
|
|
|
|
|
import com.sencha.gxt.widget.core.client.TabPanel;
|
|
|
|
|
import com.sencha.gxt.widget.core.client.button.TextButton;
|
|
|
|
|
import com.sencha.gxt.widget.core.client.event.BeforeCloseEvent;
|
|
|
|
|
import com.sencha.gxt.widget.core.client.event.BeforeCloseEvent.BeforeCloseHandler;
|
|
|
|
|
import com.sencha.gxt.widget.core.client.event.SelectEvent;
|
|
|
|
|
|
|
|
|
|
//import org.gcube.portlets.user.td.taskswidget.client.TdTaskController;
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
*
|
|
|
|
|
* @author giancarlo
|
|
|
|
|
* email: <a href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
|
|
|
|
* @author giancarlo email: <a
|
|
|
|
|
* href="mailto:g.panichi@isti.cnr.it">g.panichi@isti.cnr.it</a>
|
|
|
|
|
*
|
|
|
|
|
*/
|
|
|
|
|
public class ToolBox extends TabPanel {
|
|
|
|
|
|
|
|
|
|
private ToolBoxMessages msgs;
|
|
|
|
|
private EventBus eventBus;
|
|
|
|
|
private TabularResourceProperties trProperties;
|
|
|
|
|
private ToolBoxPanel toolBoxPanel;
|
|
|
|
|
private HelpPanel helpPanel;
|
|
|
|
|
private ChangeColumnTypePanel changeColumnTypePanel;
|
|
|
|
|
private AddColumnPanel addColumnPanel;
|
|
|
|
@ -73,16 +70,14 @@ public class ToolBox extends TabPanel {
|
|
|
|
|
private GeospatialCreateCoordinatesPanel geospatialCreateCoordinatesPanel;
|
|
|
|
|
private GeometryCreatePointPanel geometryCreatePointPanel;
|
|
|
|
|
private DownscaleCSquarePanel downscaleCSquarePanel;
|
|
|
|
|
|
|
|
|
|
private FramedPanel taskPanel;
|
|
|
|
|
|
|
|
|
|
private PositionColumnPanel positionColumnPanel;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
public ToolBox(String name, EventBus eventBus, ToolBoxPanel toolBoxPanel) {
|
|
|
|
|
super();
|
|
|
|
|
Log.debug("Create ToolBox");
|
|
|
|
|
this.eventBus = eventBus;
|
|
|
|
|
this.toolBoxPanel = toolBoxPanel;
|
|
|
|
|
this.msgs = GWT.create(ToolBoxMessages.class);
|
|
|
|
|
setId(name);
|
|
|
|
|
setBodyBorder(false);
|
|
|
|
|
setBorders(false);
|
|
|
|
@ -90,8 +85,6 @@ public class ToolBox extends TabPanel {
|
|
|
|
|
setTabScroll(true);
|
|
|
|
|
setCloseContextMenu(true);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public void startTabs() {
|
|
|
|
@ -219,7 +212,7 @@ public class ToolBox extends TabPanel {
|
|
|
|
|
setActiveWidget(positionColumnPanel);
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
public void openLabelColumnTab(TRId trId, String columnName) {
|
|
|
|
|
Log.debug("Open Label Column Tab");
|
|
|
|
|
if (labelColumnPanel == null) {
|
|
|
|
@ -292,7 +285,7 @@ public class ToolBox extends TabPanel {
|
|
|
|
|
setActiveWidget(duplicatesRowsDetectionPanel);
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
public void openDuplicatesRowsDeleteTab(TRId trId) {
|
|
|
|
|
Log.debug("Open Duplicates Rows Delete Tab");
|
|
|
|
|
if (duplicatesRowsDeletePanel == null) {
|
|
|
|
@ -303,8 +296,6 @@ public class ToolBox extends TabPanel {
|
|
|
|
|
setActiveWidget(duplicatesRowsDeletePanel);
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
public void openResourcesTab(TRId trId) {
|
|
|
|
|
Log.debug("Open Resources Tab");
|
|
|
|
@ -326,8 +317,6 @@ public class ToolBox extends TabPanel {
|
|
|
|
|
setActiveWidget(geospatialCreateCoordinatesPanel);
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
public void openGeometryCreatePointTab(TRId trId) {
|
|
|
|
|
Log.debug("Open GeospatialCreateCoordinates Tab");
|
|
|
|
@ -338,23 +327,18 @@ public class ToolBox extends TabPanel {
|
|
|
|
|
}
|
|
|
|
|
setActiveWidget(geometryCreatePointPanel);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
public void openDownscaleCSquareTab(TRId trId, String columnLocalId) {
|
|
|
|
|
Log.debug("Open DownscaleCSquare Tab");
|
|
|
|
|
if (downscaleCSquarePanel == null) {
|
|
|
|
|
addDownscaleCSquarePanel(trId,columnLocalId);
|
|
|
|
|
addDownscaleCSquarePanel(trId, columnLocalId);
|
|
|
|
|
} else {
|
|
|
|
|
downscaleCSquarePanel.update(trId,columnLocalId);
|
|
|
|
|
downscaleCSquarePanel.update(trId, columnLocalId);
|
|
|
|
|
}
|
|
|
|
|
setActiveWidget(downscaleCSquarePanel);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// Close
|
|
|
|
|
public void closePropertiesTabs() {
|
|
|
|
@ -447,8 +431,7 @@ public class ToolBox extends TabPanel {
|
|
|
|
|
positionColumnPanel = null;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
public void closeLabelColumnPanel() {
|
|
|
|
|
Log.debug("Close LabelColumnPanel Tab");
|
|
|
|
|
if (labelColumnPanel != null) {
|
|
|
|
@ -488,7 +471,7 @@ public class ToolBox extends TabPanel {
|
|
|
|
|
duplicatesRowsDetectionPanel = null;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
public void closeDuplicatesRowsDeletePanel() {
|
|
|
|
|
Log.debug("Close DuplicatesRowsDeletePanel Tab");
|
|
|
|
|
if (duplicatesRowsDeletePanel != null) {
|
|
|
|
@ -496,7 +479,6 @@ public class ToolBox extends TabPanel {
|
|
|
|
|
duplicatesRowsDeletePanel = null;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
public void closeNormalizePanel() {
|
|
|
|
|
Log.debug("Close NormalizePanel Tab");
|
|
|
|
@ -521,7 +503,7 @@ public class ToolBox extends TabPanel {
|
|
|
|
|
resourcesPanel = null;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
public void closeGeospatialCreateCoordinatesPanel() {
|
|
|
|
|
Log.debug("Close GeospatialCreateCoordinates Tab");
|
|
|
|
|
if (geospatialCreateCoordinatesPanel != null) {
|
|
|
|
@ -529,25 +511,25 @@ public class ToolBox extends TabPanel {
|
|
|
|
|
geospatialCreateCoordinatesPanel = null;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
public void closeGeometryCreatePointPanel() {
|
|
|
|
|
Log.debug("Close GeometryCreatePoint Tab");
|
|
|
|
|
if (geometryCreatePointPanel != null) {
|
|
|
|
|
remove(geometryCreatePointPanel);
|
|
|
|
|
geometryCreatePointPanel = null;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
public void closeDownscaleCSquarePanel() {
|
|
|
|
|
Log.debug("Close DownscaleCSquare Tab");
|
|
|
|
|
if (downscaleCSquarePanel != null) {
|
|
|
|
|
remove(downscaleCSquarePanel);
|
|
|
|
|
downscaleCSquarePanel = null;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
//
|
|
|
|
|
|
|
|
|
|
public void updateTabs() {
|
|
|
|
@ -619,12 +601,12 @@ public class ToolBox extends TabPanel {
|
|
|
|
|
remove(positionColumnPanel);
|
|
|
|
|
positionColumnPanel = null;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (labelColumnPanel != null) {
|
|
|
|
|
remove(labelColumnPanel);
|
|
|
|
|
labelColumnPanel = null;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (changeTableTypePanel != null) {
|
|
|
|
|
remove(changeTableTypePanel);
|
|
|
|
|
changeTableTypePanel = null;
|
|
|
|
@ -634,7 +616,7 @@ public class ToolBox extends TabPanel {
|
|
|
|
|
remove(duplicatesRowsDetectionPanel);
|
|
|
|
|
duplicatesRowsDetectionPanel = null;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (duplicatesRowsDeletePanel != null) {
|
|
|
|
|
remove(duplicatesRowsDeletePanel);
|
|
|
|
|
duplicatesRowsDeletePanel = null;
|
|
|
|
@ -649,24 +631,22 @@ public class ToolBox extends TabPanel {
|
|
|
|
|
remove(denormalizePanel);
|
|
|
|
|
denormalizePanel = null;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (geospatialCreateCoordinatesPanel != null) {
|
|
|
|
|
remove(geospatialCreateCoordinatesPanel);
|
|
|
|
|
geospatialCreateCoordinatesPanel = null;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (geometryCreatePointPanel != null) {
|
|
|
|
|
remove(geometryCreatePointPanel);
|
|
|
|
|
geometryCreatePointPanel = null;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
if(downscaleCSquarePanel!=null){
|
|
|
|
|
|
|
|
|
|
if (downscaleCSquarePanel != null) {
|
|
|
|
|
remove(downscaleCSquarePanel);
|
|
|
|
|
downscaleCSquarePanel = null;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
forceLayout();
|
|
|
|
|
} catch (Throwable e) {
|
|
|
|
|
Log.error("Error in ToolBox: " + e.getLocalizedMessage());
|
|
|
|
@ -674,17 +654,20 @@ public class ToolBox extends TabPanel {
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// Add
|
|
|
|
|
|
|
|
|
|
protected void addHelpPanel() {
|
|
|
|
|
TabItemConfig propertiesItemConf = new TabItemConfig("Help", false);
|
|
|
|
|
TabItemConfig helpItemConf = new TabItemConfig(msgs.helpItem(), false);
|
|
|
|
|
|
|
|
|
|
helpPanel = new HelpPanel("Help", eventBus);
|
|
|
|
|
helpPanel.setHeaderVisible(false);
|
|
|
|
|
add(helpPanel, propertiesItemConf);
|
|
|
|
|
add(helpPanel, helpItemConf);
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
protected void addTrProperties() {
|
|
|
|
|
TabItemConfig propertiesItemConf = new TabItemConfig("Properties", true);
|
|
|
|
|
TabItemConfig propertiesItemConf = new TabItemConfig(
|
|
|
|
|
msgs.propertiesItem(), true);
|
|
|
|
|
|
|
|
|
|
trProperties = new TabularResourceProperties("TRProperties", eventBus);
|
|
|
|
|
trProperties.setHeaderVisible(false);
|
|
|
|
@ -704,7 +687,7 @@ public class ToolBox extends TabPanel {
|
|
|
|
|
|
|
|
|
|
protected void addMonitorBackgroundPanel() {
|
|
|
|
|
TabItemConfig monitorBackgroundPanelItemConf = new TabItemConfig(
|
|
|
|
|
"Background", true);
|
|
|
|
|
msgs.monitorBackgroundPanelItem(), true);
|
|
|
|
|
|
|
|
|
|
monitorBackgroundPanel = new MonitorBackgroundPanel(eventBus);
|
|
|
|
|
add(monitorBackgroundPanel, monitorBackgroundPanelItemConf);
|
|
|
|
@ -722,7 +705,8 @@ public class ToolBox extends TabPanel {
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
protected void addHistoryPanel() {
|
|
|
|
|
TabItemConfig historyPanelItemConf = new TabItemConfig("History", true);
|
|
|
|
|
TabItemConfig historyPanelItemConf = new TabItemConfig(
|
|
|
|
|
msgs.historyPanelItem(), true);
|
|
|
|
|
|
|
|
|
|
historyPanel = new HistoryPanel(eventBus);
|
|
|
|
|
add(historyPanel, historyPanelItemConf);
|
|
|
|
@ -740,7 +724,7 @@ public class ToolBox extends TabPanel {
|
|
|
|
|
|
|
|
|
|
protected void addChangeColumnTypePanel(TRId trId, String columnName) {
|
|
|
|
|
TabItemConfig changeColumnTypeItemConf = new TabItemConfig(
|
|
|
|
|
"Column Type", true);
|
|
|
|
|
msgs.changeColumnTypeItem(), true);
|
|
|
|
|
|
|
|
|
|
changeColumnTypePanel = new ChangeColumnTypePanel(trId, columnName,
|
|
|
|
|
eventBus);
|
|
|
|
@ -761,7 +745,8 @@ public class ToolBox extends TabPanel {
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
protected void addAddColumnPanel(TRId trId) {
|
|
|
|
|
TabItemConfig addColumnItemConf = new TabItemConfig("Add Column", true);
|
|
|
|
|
TabItemConfig addColumnItemConf = new TabItemConfig(
|
|
|
|
|
msgs.addColumnItem(), true);
|
|
|
|
|
|
|
|
|
|
addColumnPanel = new AddColumnPanel(trId, eventBus);
|
|
|
|
|
add(addColumnPanel, addColumnItemConf);
|
|
|
|
@ -781,8 +766,8 @@ public class ToolBox extends TabPanel {
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
protected void addDeleteColumnPanel(TRId trId, String columnName) {
|
|
|
|
|
TabItemConfig deleteColumnItemConf = new TabItemConfig("Column Delete",
|
|
|
|
|
true);
|
|
|
|
|
TabItemConfig deleteColumnItemConf = new TabItemConfig(
|
|
|
|
|
msgs.deleteColumnItem(), true);
|
|
|
|
|
|
|
|
|
|
deleteColumnPanel = new DeleteColumnPanel(trId, columnName, eventBus);
|
|
|
|
|
add(deleteColumnPanel, deleteColumnItemConf);
|
|
|
|
@ -802,8 +787,8 @@ public class ToolBox extends TabPanel {
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
protected void addSplitColumnPanel(TRId trId, String columnName) {
|
|
|
|
|
TabItemConfig splitColumnItemConf = new TabItemConfig("Column Split",
|
|
|
|
|
true);
|
|
|
|
|
TabItemConfig splitColumnItemConf = new TabItemConfig(
|
|
|
|
|
msgs.splitColumnItem(), true);
|
|
|
|
|
|
|
|
|
|
splitColumnPanel = new SplitColumnPanel(trId, columnName, eventBus);
|
|
|
|
|
add(splitColumnPanel, splitColumnItemConf);
|
|
|
|
@ -823,8 +808,8 @@ public class ToolBox extends TabPanel {
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
protected void addMergeColumnPanel(TRId trId, String columnName) {
|
|
|
|
|
TabItemConfig mergeColumnItemConf = new TabItemConfig("Column Merge",
|
|
|
|
|
true);
|
|
|
|
|
TabItemConfig mergeColumnItemConf = new TabItemConfig(
|
|
|
|
|
msgs.mergeColumnItem(), true);
|
|
|
|
|
|
|
|
|
|
mergeColumnPanel = new MergeColumnPanel(trId, columnName, eventBus);
|
|
|
|
|
add(mergeColumnPanel, mergeColumnItemConf);
|
|
|
|
@ -844,7 +829,8 @@ public class ToolBox extends TabPanel {
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
protected void addGroupByPanel(TRId trId, String columnName) {
|
|
|
|
|
TabItemConfig groupByItemConf = new TabItemConfig("Group By", true);
|
|
|
|
|
TabItemConfig groupByItemConf = new TabItemConfig(msgs.groupByItem(),
|
|
|
|
|
true);
|
|
|
|
|
|
|
|
|
|
try {
|
|
|
|
|
groupByPanel = new GroupByColumnPanel(trId, columnName, eventBus);
|
|
|
|
@ -871,7 +857,7 @@ public class ToolBox extends TabPanel {
|
|
|
|
|
|
|
|
|
|
protected void addTimeAggregationPanel(TRId trId, String columnName) {
|
|
|
|
|
TabItemConfig timeAggregationItemConf = new TabItemConfig(
|
|
|
|
|
"Time Aggregation", true);
|
|
|
|
|
msgs.timeAggregationItem(), true);
|
|
|
|
|
|
|
|
|
|
try {
|
|
|
|
|
timeAggregationPanel = new AggregateByTimeColumnPanel(trId,
|
|
|
|
@ -899,11 +885,11 @@ public class ToolBox extends TabPanel {
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
protected void addPositionColumnPanel(TRId trId, String columnLocalId) {
|
|
|
|
|
TabItemConfig labelColumnItemConf = new TabItemConfig("Position Column",
|
|
|
|
|
true);
|
|
|
|
|
TabItemConfig positionColumnItemConf = new TabItemConfig(
|
|
|
|
|
msgs.positionColumnItem(), true);
|
|
|
|
|
|
|
|
|
|
positionColumnPanel = new PositionColumnPanel(trId, eventBus);
|
|
|
|
|
add(positionColumnPanel, labelColumnItemConf);
|
|
|
|
|
add(positionColumnPanel, positionColumnItemConf);
|
|
|
|
|
|
|
|
|
|
addBeforeCloseHandler(new BeforeCloseHandler<Widget>() {
|
|
|
|
|
|
|
|
|
@ -918,10 +904,10 @@ public class ToolBox extends TabPanel {
|
|
|
|
|
|
|
|
|
|
});
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
protected void addLabelColumnPanel(TRId trId, String columnName) {
|
|
|
|
|
TabItemConfig labelColumnItemConf = new TabItemConfig("Column Label",
|
|
|
|
|
true);
|
|
|
|
|
TabItemConfig labelColumnItemConf = new TabItemConfig(
|
|
|
|
|
msgs.labelColumnItem(), true);
|
|
|
|
|
|
|
|
|
|
labelColumnPanel = new LabelColumnPanel(trId, columnName, eventBus);
|
|
|
|
|
add(labelColumnPanel, labelColumnItemConf);
|
|
|
|
@ -941,8 +927,8 @@ public class ToolBox extends TabPanel {
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
protected void addChangeTableTypePanel(TRId trId) {
|
|
|
|
|
TabItemConfig changeTableTypeItemConf = new TabItemConfig("Table Type",
|
|
|
|
|
true);
|
|
|
|
|
TabItemConfig changeTableTypeItemConf = new TabItemConfig(
|
|
|
|
|
msgs.changeTableTypeItem(), true);
|
|
|
|
|
|
|
|
|
|
changeTableTypePanel = new ChangeTableTypePanel(trId, eventBus);
|
|
|
|
|
add(changeTableTypePanel, changeTableTypeItemConf);
|
|
|
|
@ -963,7 +949,7 @@ public class ToolBox extends TabPanel {
|
|
|
|
|
|
|
|
|
|
protected void addValidationsTablePanel(TRId trId) {
|
|
|
|
|
TabItemConfig validationsTableItemConf = new TabItemConfig(
|
|
|
|
|
"Validations", true);
|
|
|
|
|
msgs.validationsTableItem(), true);
|
|
|
|
|
|
|
|
|
|
validationsTablePanel = new ValidationsTablePanel(trId, eventBus);
|
|
|
|
|
add(validationsTablePanel, validationsTableItemConf);
|
|
|
|
@ -984,7 +970,7 @@ public class ToolBox extends TabPanel {
|
|
|
|
|
|
|
|
|
|
protected void addValidationsTasksPanel(TRId trId) {
|
|
|
|
|
TabItemConfig validationsTasksItemConf = new TabItemConfig(
|
|
|
|
|
"Validations", true);
|
|
|
|
|
msgs.validationsTasksItem(), true);
|
|
|
|
|
|
|
|
|
|
validationsTasksPanel = new ValidationsTasksPanel(trId, eventBus);
|
|
|
|
|
add(validationsTasksPanel, validationsTasksItemConf);
|
|
|
|
@ -1004,7 +990,8 @@ public class ToolBox extends TabPanel {
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
protected void addResourcesPanel(TRId trId) {
|
|
|
|
|
TabItemConfig resourcesItemConf = new TabItemConfig("Resources", true);
|
|
|
|
|
TabItemConfig resourcesItemConf = new TabItemConfig(
|
|
|
|
|
msgs.resourcesItem(), true);
|
|
|
|
|
|
|
|
|
|
resourcesPanel = new ResourcesPanel(trId, eventBus);
|
|
|
|
|
add(resourcesPanel, resourcesItemConf);
|
|
|
|
@ -1026,7 +1013,7 @@ public class ToolBox extends TabPanel {
|
|
|
|
|
protected void addGeospatialCreateCoordinatesPanel(TRId trId,
|
|
|
|
|
RequestProperties requestProperties) {
|
|
|
|
|
TabItemConfig geospatialCreateCoordinatesItemConf = new TabItemConfig(
|
|
|
|
|
"Coordinates", true);
|
|
|
|
|
msgs.geospatialCreateCoordinatesItem(), true);
|
|
|
|
|
|
|
|
|
|
geospatialCreateCoordinatesPanel = new GeospatialCreateCoordinatesPanel(
|
|
|
|
|
trId, requestProperties, eventBus);
|
|
|
|
@ -1046,15 +1033,13 @@ public class ToolBox extends TabPanel {
|
|
|
|
|
|
|
|
|
|
});
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
private void addGeometryCreatePointPanel(TRId trId) {
|
|
|
|
|
TabItemConfig geometryCreatePointItemConf = new TabItemConfig(
|
|
|
|
|
"Points", true);
|
|
|
|
|
msgs.geometryCreatePointItem(), true);
|
|
|
|
|
|
|
|
|
|
geometryCreatePointPanel = new GeometryCreatePointPanel(
|
|
|
|
|
trId, eventBus);
|
|
|
|
|
add(geometryCreatePointPanel,
|
|
|
|
|
geometryCreatePointItemConf);
|
|
|
|
|
geometryCreatePointPanel = new GeometryCreatePointPanel(trId, eventBus);
|
|
|
|
|
add(geometryCreatePointPanel, geometryCreatePointItemConf);
|
|
|
|
|
|
|
|
|
|
addBeforeCloseHandler(new BeforeCloseHandler<Widget>() {
|
|
|
|
|
|
|
|
|
@ -1068,17 +1053,16 @@ public class ToolBox extends TabPanel {
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
private void addDownscaleCSquarePanel(TRId trId, String columnLocalId) {
|
|
|
|
|
TabItemConfig downscaleCSquareItemConf = new TabItemConfig(
|
|
|
|
|
"Downscale C-Square", true);
|
|
|
|
|
msgs.downscaleCSquareItem(), true);
|
|
|
|
|
|
|
|
|
|
downscaleCSquarePanel = new DownscaleCSquarePanel(
|
|
|
|
|
trId, columnLocalId, eventBus);
|
|
|
|
|
add(downscaleCSquarePanel,
|
|
|
|
|
downscaleCSquareItemConf);
|
|
|
|
|
downscaleCSquarePanel = new DownscaleCSquarePanel(trId, columnLocalId,
|
|
|
|
|
eventBus);
|
|
|
|
|
add(downscaleCSquarePanel, downscaleCSquareItemConf);
|
|
|
|
|
|
|
|
|
|
addBeforeCloseHandler(new BeforeCloseHandler<Widget>() {
|
|
|
|
|
|
|
|
|
@ -1092,15 +1076,15 @@ public class ToolBox extends TabPanel {
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
protected void addDuplicatesRowsDetectionPanel(TRId trId) {
|
|
|
|
|
TabItemConfig duplicatesRowsDetectionItemConf = new TabItemConfig(
|
|
|
|
|
"Duplicate Detection", true);
|
|
|
|
|
msgs.duplicatesRowsDetectionItem(), true);
|
|
|
|
|
|
|
|
|
|
duplicatesRowsDetectionPanel = new DuplicatesRowsDetectionPanel(trId, eventBus);
|
|
|
|
|
duplicatesRowsDetectionPanel = new DuplicatesRowsDetectionPanel(trId,
|
|
|
|
|
eventBus);
|
|
|
|
|
add(duplicatesRowsDetectionPanel, duplicatesRowsDetectionItemConf);
|
|
|
|
|
|
|
|
|
|
addBeforeCloseHandler(new BeforeCloseHandler<Widget>() {
|
|
|
|
@ -1116,12 +1100,13 @@ public class ToolBox extends TabPanel {
|
|
|
|
|
|
|
|
|
|
});
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
protected void addDuplicatesRowsDeletePanel(TRId trId) {
|
|
|
|
|
TabItemConfig duplicatesRowsDeleteItemConf = new TabItemConfig(
|
|
|
|
|
"Delete Duplicate", true);
|
|
|
|
|
msgs.duplicatesRowsDeleteItem(), true);
|
|
|
|
|
|
|
|
|
|
duplicatesRowsDeletePanel = new DuplicatesRowsDeletePanel(trId, eventBus);
|
|
|
|
|
duplicatesRowsDeletePanel = new DuplicatesRowsDeletePanel(trId,
|
|
|
|
|
eventBus);
|
|
|
|
|
add(duplicatesRowsDeletePanel, duplicatesRowsDeleteItemConf);
|
|
|
|
|
|
|
|
|
|
addBeforeCloseHandler(new BeforeCloseHandler<Widget>() {
|
|
|
|
@ -1137,11 +1122,10 @@ public class ToolBox extends TabPanel {
|
|
|
|
|
|
|
|
|
|
});
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
protected void addNormalizePanel(TRId trId) {
|
|
|
|
|
TabItemConfig normalizeItemConf = new TabItemConfig("Normalize", true);
|
|
|
|
|
TabItemConfig normalizeItemConf = new TabItemConfig(
|
|
|
|
|
msgs.normalizeItem(), true);
|
|
|
|
|
|
|
|
|
|
normalizePanel = new NormalizePanel(trId, eventBus);
|
|
|
|
|
add(normalizePanel, normalizeItemConf);
|
|
|
|
@ -1161,8 +1145,8 @@ public class ToolBox extends TabPanel {
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
protected void addDenormalizePanel(TRId trId) {
|
|
|
|
|
TabItemConfig denormalizeItemConf = new TabItemConfig("Denormalize",
|
|
|
|
|
true);
|
|
|
|
|
TabItemConfig denormalizeItemConf = new TabItemConfig(
|
|
|
|
|
msgs.denormalizeItem(), true);
|
|
|
|
|
|
|
|
|
|
denormalizePanel = new DenormalizePanel(trId, eventBus);
|
|
|
|
|
add(denormalizePanel, denormalizeItemConf);
|
|
|
|
@ -1181,44 +1165,37 @@ public class ToolBox extends TabPanel {
|
|
|
|
|
});
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
protected void addTdTaskPanel() {
|
|
|
|
|
// TODO
|
|
|
|
|
// tdTaskController = TdTaskController.getInstance();
|
|
|
|
|
// tdTaskController.bindCommonBus(eventBus);
|
|
|
|
|
// tdTaskMainWindow = tdTaskController.getWindowTaskMonitor(); // This
|
|
|
|
|
// is main panel
|
|
|
|
|
|
|
|
|
|
taskPanel = new FramedPanel();
|
|
|
|
|
taskPanel.setHeaderVisible(false);
|
|
|
|
|
TextButton buttonTask = new TextButton("Tasks");
|
|
|
|
|
buttonTask.addSelectHandler(new SelectEvent.SelectHandler() {
|
|
|
|
|
|
|
|
|
|
public void onSelect(SelectEvent event) {
|
|
|
|
|
// tdTaskMainWindow.show();
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
taskPanel.add(buttonTask);
|
|
|
|
|
|
|
|
|
|
TabItemConfig tdTasksItemConf = new TabItemConfig("Tasks", true);
|
|
|
|
|
|
|
|
|
|
add(taskPanel, tdTasksItemConf);
|
|
|
|
|
addBeforeCloseHandler(new BeforeCloseHandler<Widget>() {
|
|
|
|
|
|
|
|
|
|
public void onBeforeClose(BeforeCloseEvent<Widget> event) {
|
|
|
|
|
if (getWidgetCount() == 1) {
|
|
|
|
|
toolBoxPanel.closePanelOnly();
|
|
|
|
|
remove(taskPanel);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/*
|
|
|
|
|
* protected void addTdTaskPanel() { // TODO // tdTaskController =
|
|
|
|
|
* TdTaskController.getInstance(); //
|
|
|
|
|
* tdTaskController.bindCommonBus(eventBus); // tdTaskMainWindow =
|
|
|
|
|
* tdTaskController.getWindowTaskMonitor(); // This // is main panel
|
|
|
|
|
*
|
|
|
|
|
* taskPanel = new FramedPanel(); taskPanel.setHeaderVisible(false);
|
|
|
|
|
* TextButton buttonTask = new TextButton("Tasks");
|
|
|
|
|
* buttonTask.addSelectHandler(new SelectEvent.SelectHandler() {
|
|
|
|
|
*
|
|
|
|
|
* public void onSelect(SelectEvent event) { // tdTaskMainWindow.show();
|
|
|
|
|
*
|
|
|
|
|
* }
|
|
|
|
|
*
|
|
|
|
|
* });
|
|
|
|
|
*
|
|
|
|
|
* taskPanel.add(buttonTask);
|
|
|
|
|
*
|
|
|
|
|
* TabItemConfig tdTasksItemConf = new TabItemConfig("Tasks", true);
|
|
|
|
|
*
|
|
|
|
|
* add(taskPanel, tdTasksItemConf); addBeforeCloseHandler(new
|
|
|
|
|
* BeforeCloseHandler<Widget>() {
|
|
|
|
|
*
|
|
|
|
|
* public void onBeforeClose(BeforeCloseEvent<Widget> event) { if
|
|
|
|
|
* (getWidgetCount() == 1) { toolBoxPanel.closePanelOnly();
|
|
|
|
|
* remove(taskPanel); }
|
|
|
|
|
*
|
|
|
|
|
* }
|
|
|
|
|
*
|
|
|
|
|
* });
|
|
|
|
|
*
|
|
|
|
|
* }
|
|
|
|
|
*/
|
|
|
|
|
}
|
|
|
|
|