diff --git a/src/main/java/org/gcube/portlets/user/geoportaldataviewer/client/ui/GeonaDataViewMainPanel.ui.xml b/src/main/java/org/gcube/portlets/user/geoportaldataviewer/client/ui/GeonaDataViewMainPanel.ui.xml
index 73a6768..3a2b810 100644
--- a/src/main/java/org/gcube/portlets/user/geoportaldataviewer/client/ui/GeonaDataViewMainPanel.ui.xml
+++ b/src/main/java/org/gcube/portlets/user/geoportaldataviewer/client/ui/GeonaDataViewMainPanel.ui.xml
@@ -40,7 +40,7 @@
+ text="World" title="Center to World">
Share
- View
+ Expand
diff --git a/src/main/java/org/gcube/portlets/user/geoportaldataviewer/client/ui/products/concessioni/LayerConcessioneView.java b/src/main/java/org/gcube/portlets/user/geoportaldataviewer/client/ui/products/concessioni/LayerConcessioneView.java
index 61d0409..4415cab 100644
--- a/src/main/java/org/gcube/portlets/user/geoportaldataviewer/client/ui/products/concessioni/LayerConcessioneView.java
+++ b/src/main/java/org/gcube/portlets/user/geoportaldataviewer/client/ui/products/concessioni/LayerConcessioneView.java
@@ -12,6 +12,7 @@ import org.gcube.portlets.user.geoportaldataviewer.client.ui.util.CustomFlexTabl
import com.github.gwtbootstrap.client.ui.DropdownButton;
import com.github.gwtbootstrap.client.ui.NavLink;
import com.github.gwtbootstrap.client.ui.constants.ButtonType;
+import com.github.gwtbootstrap.client.ui.constants.IconType;
import com.google.gwt.core.client.GWT;
import com.google.gwt.dom.client.Style;
import com.google.gwt.dom.client.Style.Unit;
@@ -52,31 +53,32 @@ public class LayerConcessioneView extends Composite {
initWidget(uiBinder.createAndBindUi(this));
GWT.log("Showing: " + layerDV);
- DropdownButton exportMapButton = new DropdownButton("Export Map as...");
- exportMapButton.setType(ButtonType.LINK);
- exportMapButton.setTitle("Export this map view (OSM + layer) as an image...");
- exportMapButton.setVisible(false);
- Style expButton = exportMapButton.getElement().getStyle();
- expButton.setMarginTop(2, Unit.PX);
-
GWT.log("WMS LINK: " + layerDV.getWmsLink());
if (layerDV.getLayerName() != null && layerDV.getWmsLink() != null) {
+
+ DropdownButton exportMapButton = new DropdownButton("Export Map as...");
+ exportMapButton.setType(ButtonType.LINK);
+ exportMapButton.setIcon(IconType.DOWNLOAD_ALT);
+ exportMapButton.setTitle("Export the map view (OSM + layer) as an image...");
+ Style exportStyle = exportMapButton.getElement().getStyle();
+ exportStyle.setWidth(100, Unit.PCT);
+ exportStyle.setMarginLeft(70, Unit.PCT);
Location italyLocation = ExtentMapUtil.getLocation(PLACE.ITALY);
Coordinate transformedCenterCoordinate = italyLocation.getCoordinate(MAP_PROJECTION.EPSG_3857);
MapView mapView = new MapView(transformedCenterCoordinate,
GeoportalDataViewerConstants.LIGHT_MAP_ITALY_FIT_ZOOM_ON, "70%", "300px");
- exportMapButton.setVisible(true);
- mapViewPanel.add(exportMapButton);
mapViewPanel.add(mapView);
+ mapViewPanel.add(exportMapButton);
String mapServerHost = layerDV.getWmsLink().contains("?")
? layerDV.getWmsLink().substring(0, layerDV.getWmsLink().indexOf("?"))
: layerDV.getWmsLink();
-
+ mapView.addWMSLayer(mapServerHost, layerDV.getLayerName(), layerDV.getBbox());
+
String htmlLinkId = mapView.getPanelMapElementId() + "-image-download";
-
+
for (IMAGE_EXPORT_AS exportType : IMAGE_EXPORT_AS.values()) {
NavLink navLink = new NavLink(exportType.name());
String exportExt = exportType.name().toLowerCase();
@@ -117,16 +119,15 @@ public class LayerConcessioneView extends Composite {
exportMapButton.add(navLink);
}
-
- customTable.addNextKeyValue("Abstract", layerDV.getAbstractSection());
- customTable.addNextKeyValue("Valutazione qualità ", layerDV.getValutazioneQualita());
- customTable.addNextKeyValue("Metodo raccolta dati", layerDV.getMetodoRaccoltaDati());
- customTable.addNextKeyValue("Scala acquisizione dati", layerDV.getScalaAcquisizione());
- customTable.addNextKeyValues("Autori", layerDV.getAuthors(), GeoportalDataViewerConstants.NEW_LINE_BR);
- layerConcessionePanel.add(customTable);
-
- mapView.addWMSLayer(mapServerHost, layerDV.getLayerName(), layerDV.getBbox());
+ //mapViewPanel.add(exportMapButton);
}
+
+ customTable.addNextKeyValue("Abstract", layerDV.getAbstractSection());
+ customTable.addNextKeyValue("Valutazione qualità ", layerDV.getValutazioneQualita());
+ customTable.addNextKeyValue("Metodo raccolta dati", layerDV.getMetodoRaccoltaDati());
+ customTable.addNextKeyValue("Scala acquisizione dati", layerDV.getScalaAcquisizione());
+ customTable.addNextKeyValues("Autori", layerDV.getAuthors(), GeoportalDataViewerConstants.NEW_LINE_BR);
+ layerConcessionePanel.add(customTable);
}
public static native void exportPDF(String layerURL) /*-{