Added downscale C-Square
git-svn-id: https://svn.d4science.research-infrastructures.eu/gcube/trunk/portlets/user/tabular-data-portlet@113508 82a268e6-3cf1-43bd-a215-b396298e98cf
This commit is contained in:
parent
66c3f34d0c
commit
866cb5c863
|
@ -857,6 +857,9 @@ public class TabularDataController {
|
|||
case GEOSPATIAL_OCEAN_AREA:
|
||||
openGeospatialOceanArea();
|
||||
break;
|
||||
case DOWNSCALE_CSQUARE:
|
||||
openDownscaleCSquare();
|
||||
break;
|
||||
case GEOMETRY_POINT:
|
||||
openGeometryCreatePoint();
|
||||
break;
|
||||
|
@ -1986,6 +1989,8 @@ public class TabularDataController {
|
|||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
private void openGeometryCreatePoint() {
|
||||
Log.debug("Request Geometry Create Point Tab");
|
||||
if (trId != null) {
|
||||
|
@ -2000,6 +2005,28 @@ public class TabularDataController {
|
|||
}
|
||||
}
|
||||
|
||||
|
||||
private void openDownscaleCSquare() {
|
||||
openDownscaleCSquare(null, null);
|
||||
}
|
||||
|
||||
private void openDownscaleCSquare(String columnLocalId, String columnName) {
|
||||
Log.debug("Request Downscale C-Square Tab");
|
||||
if (trId != null) {
|
||||
WidgetRequestEvent e = new WidgetRequestEvent(
|
||||
WidgetRequestType.DOWNSCALECSQUAREPANEL);
|
||||
e.setTrId(trId);
|
||||
e.setColumnLocalId(columnLocalId);
|
||||
e.setColumnName(columnName);
|
||||
eventBus.fireEvent(e);
|
||||
} else {
|
||||
Log.error("TRId is null");
|
||||
UtilsGXT3.alert("Error", "No tabular resource present");
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
private void openBackgroundMonitor() {
|
||||
Log.debug("Request Open Monitor Background Tab");
|
||||
WidgetRequestEvent e = new WidgetRequestEvent(
|
||||
|
@ -2285,7 +2312,15 @@ public class TabularDataController {
|
|||
columnLocalId,
|
||||
columnName);
|
||||
} else {
|
||||
if (opId.compareTo(GridHeaderOperationId.DOWNSCALECSQUARE
|
||||
.toString()) == 0) {
|
||||
|
||||
openDownscaleCSquare(
|
||||
columnLocalId,
|
||||
columnName);
|
||||
} else {
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -446,13 +446,19 @@ public interface TabularDataResources extends ClientBundle {
|
|||
@Source("flag-blue.png")
|
||||
ImageResource geospatialOceanArea();
|
||||
|
||||
|
||||
@Source("flag-green_32.png")
|
||||
ImageResource geospatialCoordinates32();
|
||||
|
||||
@Source("flag-green.png")
|
||||
ImageResource geospatialCoordinates();
|
||||
|
||||
|
||||
@Source("downscale-csquare_32.png")
|
||||
ImageResource downscaleCSquare32();
|
||||
|
||||
@Source("downscale-csquare.png")
|
||||
ImageResource downscaleCSquare();
|
||||
|
||||
@Source("point_32.png")
|
||||
ImageResource geometryPoint32();
|
||||
|
||||
|
|
Binary file not shown.
After Width: | Height: | Size: 912 B |
Binary file not shown.
After Width: | Height: | Size: 2.4 KiB |
|
@ -47,6 +47,9 @@ public class ModifyToolBar {
|
|||
// Geospatial
|
||||
private TextButton csquareButton;
|
||||
private TextButton oceanAreaButton;
|
||||
private TextButton downscaleCSquareButton;
|
||||
|
||||
// Geometry
|
||||
private TextButton pointButton;
|
||||
|
||||
public ModifyToolBar(EventBus eventBus) {
|
||||
|
@ -243,6 +246,25 @@ public class ModifyToolBar {
|
|||
geospatialLayout.setWidget(0, 1, oceanAreaButton);
|
||||
geospatialLayout.getFlexCellFormatter().setRowSpan(0, 1, 2);
|
||||
|
||||
|
||||
downscaleCSquareButton = new TextButton("Downscale C-Square",
|
||||
TabularDataResources.INSTANCE.downscaleCSquare32());
|
||||
downscaleCSquareButton.disable();
|
||||
downscaleCSquareButton.setScale(ButtonScale.LARGE);
|
||||
downscaleCSquareButton.setIconAlign(IconAlign.TOP);
|
||||
downscaleCSquareButton.setToolTip("Downscale C-Square Coordinates");
|
||||
downscaleCSquareButton.setArrowAlign(ButtonArrowAlign.BOTTOM);
|
||||
downscaleCSquareButton.addSelectHandler(new SelectHandler() {
|
||||
|
||||
public void onSelect(SelectEvent event) {
|
||||
eventBus.fireEvent(new RibbonEvent(
|
||||
RibbonType.DOWNSCALE_CSQUARE));
|
||||
}
|
||||
});
|
||||
|
||||
geospatialLayout.setWidget(0, 2, downscaleCSquareButton);
|
||||
geospatialLayout.getFlexCellFormatter().setRowSpan(0, 2, 2);
|
||||
|
||||
cleanCells(geospatialLayout.getElement());
|
||||
|
||||
// Geometry Group
|
||||
|
@ -314,6 +336,7 @@ public class ModifyToolBar {
|
|||
// Geospatial
|
||||
csquareButton.disable();
|
||||
oceanAreaButton.disable();
|
||||
downscaleCSquareButton.disable();
|
||||
// Geometry
|
||||
pointButton.disable();
|
||||
break;
|
||||
|
@ -330,6 +353,7 @@ public class ModifyToolBar {
|
|||
// Geospatial
|
||||
csquareButton.disable();
|
||||
oceanAreaButton.disable();
|
||||
downscaleCSquareButton.disable();
|
||||
// Geometry
|
||||
pointButton.disable();
|
||||
break;
|
||||
|
@ -347,6 +371,7 @@ public class ModifyToolBar {
|
|||
// Geospatial
|
||||
csquareButton.enable();
|
||||
oceanAreaButton.enable();
|
||||
downscaleCSquareButton.enable();
|
||||
// Geometry
|
||||
pointButton.enable();
|
||||
break;
|
||||
|
@ -362,6 +387,7 @@ public class ModifyToolBar {
|
|||
// Geospatial
|
||||
csquareButton.disable();
|
||||
oceanAreaButton.disable();
|
||||
downscaleCSquareButton.disable();
|
||||
// Geometry
|
||||
pointButton.disable();
|
||||
break;
|
||||
|
|
Binary file not shown.
After Width: | Height: | Size: 912 B |
Binary file not shown.
After Width: | Height: | Size: 2.4 KiB |
|
@ -76,18 +76,18 @@
|
|||
<!-- Specify the app entry point class. -->
|
||||
<entry-point class='org.gcube.portlets.user.td.client.TabularDataPortlet' />
|
||||
|
||||
<!--
|
||||
|
||||
<set-property name="log_ConsoleLogger" value="ENABLED" />
|
||||
<set-property name="log_DivLogger" value="ENABLED" />
|
||||
<set-property name="log_GWTLogger" value="ENABLED" />
|
||||
<set-property name="log_SystemLogger" value="ENABLED" /> -->
|
||||
<set-property name="log_SystemLogger" value="ENABLED" />
|
||||
<!-- Not in GWT 2.6 <set-property name="log_FirebugLogger" value="ENABLED" /> -->
|
||||
|
||||
|
||||
<!--
|
||||
<set-property name="log_ConsoleLogger" value="DISABLED" />
|
||||
<set-property name="log_DivLogger" value="DISABLED" />
|
||||
<set-property name="log_GWTLogger" value="DISABLED" />
|
||||
<set-property name="log_SystemLogger" value="DISABLED" />
|
||||
<set-property name="log_SystemLogger" value="DISABLED" /> -->
|
||||
<!-- Not in GWT 2.6 <set-property name="log_FirebugLogger" value="DISABLED" /> -->
|
||||
|
||||
<!-- Specify the paths for translatable code -->
|
||||
|
|
Loading…
Reference in New Issue