Updated to GWT 2.6.1

git-svn-id: https://svn.d4science.research-infrastructures.eu/gcube/trunk/portlets/user/tabular-data-portlet@101748 82a268e6-3cf1-43bd-a215-b396298e98cf
This commit is contained in:
Giancarlo Panichi 2014-11-27 17:30:11 +00:00
parent 28a825b36e
commit 96b9c8b565
7 changed files with 75 additions and 36 deletions

View File

@ -33,17 +33,17 @@
<attribute name="org.eclipse.jst.component.dependency" value="/WEB-INF/lib"/> <attribute name="org.eclipse.jst.component.dependency" value="/WEB-INF/lib"/>
</attributes> </attributes>
</classpathentry> </classpathentry>
<classpathentry kind="lib" path="/home/giancarlo/gwt-2.5.1/gwt-user.jar"> <classpathentry kind="lib" path="/home/giancarlo/gwt/gwt-2.6.1/gwt-user.jar">
<attributes> <attributes>
<attribute name="javadoc_location" value="file:/home/giancarlo/gwt-2.5.1/doc/javadoc/"/> <attribute name="javadoc_location" value="file:/home/giancarlo/gwt/gwt-2.6.1/doc/javadoc/"/>
</attributes> </attributes>
</classpathentry> </classpathentry>
<classpathentry kind="lib" path="/home/giancarlo/gwt-2.5.1/gwt-dev.jar"> <classpathentry kind="lib" path="/home/giancarlo/gwt/gwt-2.6.1/gwt-dev.jar">
<attributes> <attributes>
<attribute name="javadoc_location" value="file:/home/giancarlo/gwt-2.5.1/doc/javadoc/"/> <attribute name="javadoc_location" value="file:/home/giancarlo/gwt/gwt-2.6.1/doc/javadoc/"/>
</attributes> </attributes>
</classpathentry> </classpathentry>
<classpathentry kind="lib" path="/home/giancarlo/gwt-2.5.1/validation-api-1.0.0.GA.jar" sourcepath="/home/giancarlo/gwt-2.5.1/validation-api-1.0.0.GA-sources.jar"/> <classpathentry kind="lib" path="/home/giancarlo/gwt/gwt-2.6.1/validation-api-1.0.0.GA.jar" sourcepath="/home/giancarlo/gwt/gwt-2.6.1/validation-api-1.0.0.GA-sources.jar"/>
<classpathentry kind="lib" path="/home/giancarlo/gwt-2.5.1/validation-api-1.0.0.GA-sources.jar"/> <classpathentry kind="lib" path="/home/giancarlo/gwt/gwt-2.6.1/validation-api-1.0.0.GA-sources.jar"/>
<classpathentry kind="output" path="target/tabular-data-manager-2.5.0-SNAPSHOT/WEB-INF/classes"/> <classpathentry kind="output" path="target/tabular-data-manager-2.5.0-SNAPSHOT/WEB-INF/classes"/>
</classpath> </classpath>

16
pom.xml
View File

@ -47,7 +47,15 @@
<distroDirectory>distro</distroDirectory> <distroDirectory>distro</distroDirectory>
<configDirectory>config</configDirectory> <configDirectory>config</configDirectory>
<gwtVersion>2.5.1</gwtVersion> <!-- GWT configuration -->
<!-- <gwtVersion>2.5.1</gwtVersion>
<gwtLogVersion>3.2.1</gwtLogVersion>
<gxtVersion>3.0.1</gxtVersion> -->
<!-- Next -->
<gwtVersion>2.6.1</gwtVersion>
<gwtLogVersion>3.3.2</gwtLogVersion>
<gxtVersion>3.1.1</gxtVersion>
<!-- To make this work on gwt-run you need to set up global env vars. on <!-- To make this work on gwt-run you need to set up global env vars. on
MacOSX edit this file /etc/launchd.conf and put "setenv GLOBUS_LOCATION /Users/massi/portal/Portal-Bundle/gCore" MacOSX edit this file /etc/launchd.conf and put "setenv GLOBUS_LOCATION /Users/massi/portal/Portal-Bundle/gCore"
@ -115,13 +123,13 @@
<dependency> <dependency>
<groupId>com.sencha.gxt</groupId> <groupId>com.sencha.gxt</groupId>
<artifactId>gxt</artifactId> <artifactId>gxt</artifactId>
<version>3.0.1</version> <version>${gxtVersion}</version>
</dependency> </dependency>
<dependency> <dependency>
<groupId>com.sencha.gxt</groupId> <groupId>com.sencha.gxt</groupId>
<artifactId>gxt-chart</artifactId> <artifactId>gxt-chart</artifactId>
<version>3.0.1</version> <version>${gxtVersion}</version>
</dependency> </dependency>
<!-- Portlet --> <!-- Portlet -->
@ -435,7 +443,7 @@
<dependency> <dependency>
<groupId>com.allen-sauer.gwt.log</groupId> <groupId>com.allen-sauer.gwt.log</groupId>
<artifactId>gwt-log</artifactId> <artifactId>gwt-log</artifactId>
<version>3.2.1</version> <version>${gwtLogVersion}</version>
</dependency> </dependency>
<dependency> <dependency>

View File

@ -77,11 +77,10 @@ import com.google.gwt.user.client.Window;
import com.google.gwt.user.client.rpc.AsyncCallback; import com.google.gwt.user.client.rpc.AsyncCallback;
import com.google.web.bindery.event.shared.EventBus; import com.google.web.bindery.event.shared.EventBus;
import com.sencha.gxt.widget.core.client.ContentPanel; import com.sencha.gxt.widget.core.client.ContentPanel;
import com.sencha.gxt.widget.core.client.Dialog.PredefinedButton;
import com.sencha.gxt.widget.core.client.box.ConfirmMessageBox; import com.sencha.gxt.widget.core.client.box.ConfirmMessageBox;
import com.sencha.gxt.widget.core.client.container.BorderLayoutContainer.BorderLayoutData; import com.sencha.gxt.widget.core.client.container.BorderLayoutContainer.BorderLayoutData;
import com.sencha.gxt.widget.core.client.event.HideEvent; import com.sencha.gxt.widget.core.client.event.DialogHideEvent;
import com.sencha.gxt.widget.core.client.event.HideEvent.HideHandler; import com.sencha.gxt.widget.core.client.event.DialogHideEvent.DialogHideHandler;
//import org.gcube.portlets.user.tdtemplate.client.TdTemplateController; //import org.gcube.portlets.user.tdtemplate.client.TdTemplateController;
@ -647,10 +646,17 @@ public class TabularDataController {
final ConfirmMessageBox mb = new ConfirmMessageBox("Confirm", final ConfirmMessageBox mb = new ConfirmMessageBox("Confirm",
"Are you sure you want to delete the taular resource?"); "Are you sure you want to delete the taular resource?");
mb.addHideHandler(new HideHandler() { // Next in GXT 3.1.1
public void onHide(HideEvent event) {
if (mb.getHideButton() == mb.getButtonById(PredefinedButton.YES mb.addDialogHideHandler(new DialogHideHandler() {
.name())) {
@Override
public void onDialogHide(DialogHideEvent event) {
switch (event.getHideButton()) {
case NO:
mb.hide();
break;
case YES:
Log.debug("Remove TR:" + trId); Log.debug("Remove TR:" + trId);
TDGWTServiceAsync.INSTANCE.removeTabularResource(trId, TDGWTServiceAsync.INSTANCE.removeTabularResource(trId,
new AsyncCallback<Void>() { new AsyncCallback<Void>() {
@ -667,12 +673,33 @@ public class TabularDataController {
}); });
mb.hide(); mb.hide();
} else if (mb.getHideButton() == mb break;
.getButtonById(PredefinedButton.NO.name())) { default:
mb.hide(); break;
} }
} }
}); });
/*
* GXT 3.0.1 mb.addHideHandler(new HideHandler() { public void
* onHide(HideEvent event) { if (mb.getHideButton() ==
* mb.getButtonById(PredefinedButton.YES .name())) {
* Log.debug("Remove TR:" + trId);
* TDGWTServiceAsync.INSTANCE.removeTabularResource(trId, new
* AsyncCallback<Void>() {
*
* public void onFailure(Throwable caught) {
* UtilsGXT3.alert("Error on Delete", caught.getLocalizedMessage()); }
*
* public void onSuccess(Void result) { requestCloseCurrent(); }
*
* });
*
* mb.hide(); } else if (mb.getHideButton() == mb
* .getButtonById(PredefinedButton.NO.name())) { mb.hide(); } } });
*/
mb.setWidth(300); mb.setWidth(300);
mb.show(); mb.show();
@ -1242,17 +1269,17 @@ public class TabularDataController {
public void onSuccess() { public void onSuccess() {
openWizard(); openWizard();
ReplaceByExternalTD replaceByExternalColWizard; ReplaceByExternalTD replaceByExternalColWizard;
if(colname==null|| colname.isEmpty()){ if (colname == null || colname.isEmpty()) {
replaceByExternalColWizard= new ReplaceByExternalTD( replaceByExternalColWizard = new ReplaceByExternalTD(trId,
trId, "Replace By External Columns", eventBus); "Replace By External Columns", eventBus);
} else { } else {
replaceByExternalColWizard= new ReplaceByExternalTD( replaceByExternalColWizard = new ReplaceByExternalTD(trId,
trId, colname,"Replace By External Columns", eventBus); colname, "Replace By External Columns", eventBus);
} }
replaceByExternalColWizard.addListener(new WizardListener() { replaceByExternalColWizard.addListener(new WizardListener() {
public void failed(String title, String message, public void failed(String title, String message,
Throwable throwable) { Throwable throwable) {
@ -2046,7 +2073,7 @@ public class TabularDataController {
} else { } else {
if (opId.compareTo(GridHeaderOperationId.COLUMNREPLACEBYEXTERNAL if (opId.compareTo(GridHeaderOperationId.COLUMNREPLACEBYEXTERNAL
.toString()) == 0) { .toString()) == 0) {
openReplaceByExternalColWizard(columnName); openReplaceByExternalColWizard(columnName);
} else { } else {

View File

@ -208,7 +208,7 @@ public class TemplateApplyPanel extends FramedPanel {
ToolBar toolBar = new ToolBar(); ToolBar toolBar = new ToolBar();
toolBar.add(grid); toolBar.add(grid);
toolBar.addStyleName(ThemeStyles.getStyle().borderTop()); toolBar.addStyleName(ThemeStyles.get().style().borderTop());
toolBar.getElement().getStyle().setProperty("borderBottom", "none"); toolBar.getElement().getStyle().setProperty("borderBottom", "none");
btnApply = new TextButton("Apply"); btnApply = new TextButton("Apply");

View File

@ -196,7 +196,7 @@ public class TemplateDeletePanel extends FramedPanel {
ToolBar toolBar = new ToolBar(); ToolBar toolBar = new ToolBar();
toolBar.add(grid); toolBar.add(grid);
toolBar.addStyleName(ThemeStyles.getStyle().borderTop()); toolBar.addStyleName(ThemeStyles.get().style().borderTop());
toolBar.getElement().getStyle().setProperty("borderBottom", "none"); toolBar.getElement().getStyle().setProperty("borderBottom", "none");
btnDelete = new TextButton("Delete"); btnDelete = new TextButton("Delete");

View File

@ -202,7 +202,7 @@ public class TemplateOpenPanel extends FramedPanel {
ToolBar toolBar = new ToolBar(); ToolBar toolBar = new ToolBar();
toolBar.add(grid); toolBar.add(grid);
toolBar.addStyleName(ThemeStyles.getStyle().borderTop()); toolBar.addStyleName(ThemeStyles.get().style().borderTop());
toolBar.getElement().getStyle().setProperty("borderBottom", "none"); toolBar.getElement().getStyle().setProperty("borderBottom", "none");
btnOpen = new TextButton("Open"); btnOpen = new TextButton("Open");

View File

@ -70,15 +70,19 @@
<!-- Specify the app entry point class. --> <!-- Specify the app entry point class. -->
<entry-point class='org.gcube.portlets.user.td.client.TabularDataPortlet' /> <entry-point class='org.gcube.portlets.user.td.client.TabularDataPortlet' />
<!-- <set-property name="log_DivLogger" value="ENABLED" /> <set-property <!-- <set-property name="log_DivLogger" value="ENABLED" /> <set-property
name="log_ConsoleLogger" value="ENABLED" /> <set-property name="log_FirebugLogger" name="log_ConsoleLogger" value="ENABLED" /> <set-property name="log_GWTLogger" value="ENABLED" />
value="ENABLED" /> <set-property name="log_GWTLogger" value="ENABLED" />
<set-property name="log_SystemLogger" value="ENABLED" /> --> <set-property name="log_SystemLogger" value="ENABLED" /> -->
<!-- Disabled <set-property name="log_FirebugLogger"
value="ENABLED" /> -->
<set-property name="log_DivLogger" value="DISABLED" /> <set-property name="log_DivLogger" value="DISABLED" />
<set-property name="log_ConsoleLogger" value="DISABLED" /> <set-property name="log_ConsoleLogger" value="DISABLED" />
<set-property name="log_FirebugLogger" value="DISABLED" />
<set-property name="log_GWTLogger" value="DISABLED" /> <set-property name="log_GWTLogger" value="DISABLED" />
<set-property name="log_SystemLogger" value="DISABLED" /> <set-property name="log_SystemLogger" value="DISABLED" />
<!-- Disabled
<set-property name="log_FirebugLogger" value="DISABLED" /> -->
<!-- Specify the paths for translatable code --> <!-- Specify the paths for translatable code -->
<source path='client' /> <source path='client' />
<source path='shared' /> <source path='shared' />