diff --git a/src/server/Makefile b/src/server/Makefile
index 1df20398e..884e95360 100644
--- a/src/server/Makefile
+++ b/src/server/Makefile
@@ -10,7 +10,10 @@ gwt:
gwt/Translate-compile
gf-gwt.jar:
+ mkdir -p gwt/bin/se/chalmers/cs/gf/gwt/client
+ javac -classpath $(GWT_CLASSPATH) -sourcepath gwt/src -d gwt/bin gwt/src/se/chalmers/cs/gf/gwt/client/*.java
jar -cf $@ -C gwt/src se
+ jar -uf $@ -C gwt/bin se
cp $@ ../../lib/java
food.pgf:
diff --git a/src/server/gwt/.classpath b/src/server/gwt/.classpath
new file mode 100644
index 000000000..9885b1f85
--- /dev/null
+++ b/src/server/gwt/.classpath
@@ -0,0 +1,8 @@
+
+
+
+
+
+
+
+
diff --git a/src/server/gwt/.project b/src/server/gwt/.project
new file mode 100644
index 000000000..dc1b7042a
--- /dev/null
+++ b/src/server/gwt/.project
@@ -0,0 +1,15 @@
+
+
+ GF-GWT
+ GF-GWT project
+
+
+
+ org.eclipse.jdt.core.javabuilder
+
+
+
+
+ org.eclipse.jdt.core.javanature
+
+
diff --git a/src/server/gwt/TranslateApp.launch b/src/server/gwt/TranslateApp.launch
new file mode 100644
index 000000000..400ecca5c
--- /dev/null
+++ b/src/server/gwt/TranslateApp.launch
@@ -0,0 +1,16 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/server/gwt/src/se/chalmers/cs/gf/gwt/client/Arg.java b/src/server/gwt/src/se/chalmers/cs/gf/gwt/client/Arg.java
new file mode 100644
index 000000000..0e5a9c2ef
--- /dev/null
+++ b/src/server/gwt/src/se/chalmers/cs/gf/gwt/client/Arg.java
@@ -0,0 +1,13 @@
+package se.chalmers.cs.gf.gwt.client;
+
+public class Arg {
+ public final String name;
+ public final String value;
+ public Arg (String name, String value) {
+ this.name = name;
+ this.value = value;
+ }
+ public Arg (String name, int value) {
+ this(name, Integer.toString(value));
+ }
+}
\ No newline at end of file
diff --git a/src/server/gwt/src/se/chalmers/cs/gf/gwt/client/CompletionOracle.java b/src/server/gwt/src/se/chalmers/cs/gf/gwt/client/CompletionOracle.java
index 1073eed67..fbeceb483 100644
--- a/src/server/gwt/src/se/chalmers/cs/gf/gwt/client/CompletionOracle.java
+++ b/src/server/gwt/src/se/chalmers/cs/gf/gwt/client/CompletionOracle.java
@@ -2,83 +2,81 @@ package se.chalmers.cs.gf.gwt.client;
import com.google.gwt.user.client.ui.SuggestOracle;
-import com.google.gwt.core.client.GWT;
-
import java.util.*;
public class CompletionOracle extends SuggestOracle {
- private PGF pgf;
+ private PGF pgf;
- private ErrorHandler errorHandler;
+ private ErrorHandler errorHandler;
- private List inputLangs = null;
+ private List inputLangs = null;
- private PGFRequest pgfRequest = null;
+ private JSONRequest JSONRequest = null;
- public CompletionOracle (PGF pgf) {
- this(pgf, null);
- }
-
- public CompletionOracle (PGF pgf, ErrorHandler errorHandler) {
- this.pgf = pgf;
- this.errorHandler = errorHandler;
- }
-
- public void setInputLangs(List inputLangs) {
- this.inputLangs = inputLangs;
- }
-
- public List getInputLangs() {
- return inputLangs;
- }
-
- public void setErrorHandler(ErrorHandler errorHandler) {
- this.errorHandler = errorHandler;
- }
-
- public static interface ErrorHandler {
- public void onError(Throwable e);
- }
-
- public static class CompletionSuggestion implements SuggestOracle.Suggestion {
- private String string;
- public CompletionSuggestion(String string) {
- this.string = string;
+ public CompletionOracle (PGF pgf) {
+ this(pgf, null);
}
- public String getDisplayString() {
- return string;
+ public CompletionOracle (PGF pgf, ErrorHandler errorHandler) {
+ this.pgf = pgf;
+ this.errorHandler = errorHandler;
}
- public String getReplacementString() {
- return string;
+ public void setInputLangs(List inputLangs) {
+ this.inputLangs = inputLangs;
}
- }
- public void requestSuggestions(final SuggestOracle.Request request, final SuggestOracle.Callback callback) {
+ public List getInputLangs() {
+ return inputLangs;
+ }
- // only allow a single completion request at a time
- if (pgfRequest != null)
- pgfRequest.cancel();
+ public void setErrorHandler(ErrorHandler errorHandler) {
+ this.errorHandler = errorHandler;
+ }
- pgfRequest = pgf.complete(request.getQuery(), getInputLangs(), null, request.getLimit(),
- new PGF.CompleteCallback() {
+ public static interface ErrorHandler {
+ public void onError(Throwable e);
+ }
+
+ public static class CompletionSuggestion implements SuggestOracle.Suggestion {
+ private String string;
+ public CompletionSuggestion(String string) {
+ this.string = string;
+ }
+
+ public String getDisplayString() {
+ return string;
+ }
+
+ public String getReplacementString() {
+ return string;
+ }
+ }
+
+ public void requestSuggestions(final SuggestOracle.Request request, final SuggestOracle.Callback callback) {
+
+ // only allow a single completion request at a time
+ if (JSONRequest != null)
+ JSONRequest.cancel();
+
+ JSONRequest = pgf.complete(request.getQuery(), getInputLangs(), null, request.getLimit(),
+ new PGF.CompleteCallback() {
public void onResult(PGF.Completions completions) {
- Collection suggestions = new ArrayList();
- for (int i = 0; i < completions.length(); i++) {
- String text = completions.get(i).getText();
- suggestions.add(new CompletionSuggestion(text));
- }
- callback.onSuggestionsReady(request, new SuggestOracle.Response(suggestions));
+ Collection suggestions = new ArrayList();
+ for (int i = 0; i < completions.length(); i++) {
+ String text = completions.get(i).getText();
+ suggestions.add(new CompletionSuggestion(text));
+ }
+ callback.onSuggestionsReady(request, new SuggestOracle.Response(suggestions));
}
public void onError(Throwable e) {
- errorHandler.onError(e);
+ errorHandler.onError(e);
}
- });
- }
+ });
+ }
}
diff --git a/src/server/gwt/src/se/chalmers/cs/gf/gwt/client/IterableJsArray.java b/src/server/gwt/src/se/chalmers/cs/gf/gwt/client/IterableJsArray.java
new file mode 100644
index 000000000..59f6df2da
--- /dev/null
+++ b/src/server/gwt/src/se/chalmers/cs/gf/gwt/client/IterableJsArray.java
@@ -0,0 +1,35 @@
+package se.chalmers.cs.gf.gwt.client;
+
+import java.util.Iterator;
+import java.util.NoSuchElementException;
+
+import com.google.gwt.core.client.JavaScriptObject;
+import com.google.gwt.core.client.JsArray;
+
+public class IterableJsArray extends JsArray {
+
+ protected IterableJsArray() {}
+
+ public final Iterable iterable() {
+ return new Iterable() {
+ public Iterator iterator() {
+ return new Iterator() {
+ private int i = 0;
+ public boolean hasNext() {
+ return i < length();
+ }
+ public T next() {
+ if (!hasNext()) {
+ throw new NoSuchElementException();
+ }
+ return get(i++);
+ }
+ public void remove() {
+ throw new UnsupportedOperationException();
+ }
+ };
+ }
+ };
+ }
+
+}
diff --git a/src/server/gwt/src/se/chalmers/cs/gf/gwt/client/JSONCallback.java b/src/server/gwt/src/se/chalmers/cs/gf/gwt/client/JSONCallback.java
new file mode 100644
index 000000000..a9c1aaeb4
--- /dev/null
+++ b/src/server/gwt/src/se/chalmers/cs/gf/gwt/client/JSONCallback.java
@@ -0,0 +1,8 @@
+package se.chalmers.cs.gf.gwt.client;
+
+import com.google.gwt.core.client.JavaScriptObject;
+
+public interface JSONCallback {
+ public void onResult (T result) ;
+ public void onError (Throwable e) ;
+}
diff --git a/src/server/gwt/src/se/chalmers/cs/gf/gwt/client/JSONRequest.java b/src/server/gwt/src/se/chalmers/cs/gf/gwt/client/JSONRequest.java
new file mode 100644
index 000000000..393443b7e
--- /dev/null
+++ b/src/server/gwt/src/se/chalmers/cs/gf/gwt/client/JSONRequest.java
@@ -0,0 +1,19 @@
+package se.chalmers.cs.gf.gwt.client;
+
+import com.google.gwt.http.client.*;
+
+public class JSONRequest {
+
+ private Request httpRequest;
+
+ JSONRequest (Request httpRequest) {
+ this.httpRequest = httpRequest;
+ }
+
+ public void cancel() {
+ if (httpRequest != null) {
+ httpRequest.cancel();
+ }
+ }
+
+}
\ No newline at end of file
diff --git a/src/server/gwt/src/se/chalmers/cs/gf/gwt/client/JSONRequestBuilder.java b/src/server/gwt/src/se/chalmers/cs/gf/gwt/client/JSONRequestBuilder.java
new file mode 100644
index 000000000..8af6f0494
--- /dev/null
+++ b/src/server/gwt/src/se/chalmers/cs/gf/gwt/client/JSONRequestBuilder.java
@@ -0,0 +1,65 @@
+package se.chalmers.cs.gf.gwt.client;
+
+import com.google.gwt.core.client.JavaScriptObject;
+import com.google.gwt.http.client.Request;
+import com.google.gwt.http.client.RequestBuilder;
+import com.google.gwt.http.client.RequestCallback;
+import com.google.gwt.http.client.RequestException;
+import com.google.gwt.http.client.Response;
+import com.google.gwt.http.client.URL;
+
+import java.util.List;
+
+public class JSONRequestBuilder {
+
+ public static JSONRequest sendRequest (String base, List vars, final JSONCallback callback) {
+ String url = base + "?" + buildQueryString(vars);
+ RequestBuilder builder = new RequestBuilder(RequestBuilder.GET, url);
+ builder.setTimeoutMillis(30000);
+ builder.setHeader("Accept","text/plain, text/html;q=0.5, */*;q=0.1");
+ Request request = null;
+
+ try {
+ request = builder.sendRequest(null, new RequestCallback() {
+ public void onError(Request request, Throwable e) {
+ callback.onError(e);
+ }
+
+ public void onResponseReceived(Request request, Response response) {
+ if (200 == response.getStatusCode()) {
+ callback.onResult((T)eval(response.getText()).cast());
+ } else {
+ RequestException e = new RequestException("Response not OK: " + response.getStatusCode() + ". " + response.getText());
+ callback.onError(e);
+ }
+ }
+ });
+ } catch (RequestException e) {
+ callback.onError(e);
+ }
+
+ return new JSONRequest(request);
+ }
+
+ private static native JavaScriptObject eval(String json) /*-{
+ return eval('(' + json + ')');
+ }-*/;
+
+ private static String buildQueryString(List args) {
+ StringBuffer sb = new StringBuffer();
+ if (args != null) {
+ for (Arg arg : args) {
+ if (arg.value != null) {
+ if (sb.length() > 0) {
+ sb.append("&");
+ }
+ sb.append(URL.encodeComponent(arg.name));
+ sb.append("=");
+ sb.append(URL.encodeComponent(arg.value));
+ }
+ }
+ }
+ return sb.toString();
+ }
+
+}
diff --git a/src/server/gwt/src/se/chalmers/cs/gf/gwt/client/PGF.java b/src/server/gwt/src/se/chalmers/cs/gf/gwt/client/PGF.java
index a47977747..24e8fafc5 100644
--- a/src/server/gwt/src/se/chalmers/cs/gf/gwt/client/PGF.java
+++ b/src/server/gwt/src/se/chalmers/cs/gf/gwt/client/PGF.java
@@ -1,248 +1,149 @@
package se.chalmers.cs.gf.gwt.client;
-import com.google.gwt.http.client.*;
-import com.google.gwt.core.client.GWT;
-import com.google.gwt.core.client.JsArray;
import com.google.gwt.core.client.JavaScriptObject;
-import com.google.gwt.json.client.JSONValue;
-import com.google.gwt.json.client.JSONObject;
-import com.google.gwt.json.client.JSONParser;
-
-import java.util.Set;
-import java.util.Iterator;
import java.util.List;
-import java.util.NoSuchElementException;
import java.util.ArrayList;
public class PGF {
- private String baseURL;
- private String pgfName;
+ private String baseURL;
+ private String pgfName;
- public PGF (String baseURL, String pgfName) {
- this.baseURL = baseURL;
- this.pgfName = pgfName;
- }
+ public PGF (String baseURL, String pgfName) {
+ this.baseURL = baseURL;
+ this.pgfName = pgfName;
+ }
- public static interface GFCallback {
- public void onResult (T result) ;
- public void onError (Throwable e) ;
- }
+ /* Grammar */
- public static class IterableJsArray extends JsArray {
- protected IterableJsArray() {}
+ public JSONRequest grammar (final GrammarCallback callback) {
+ return sendRequest("grammar", null, callback);
+ }
- public final Iterable iterable() {
- return new Iterable() {
- public Iterator iterator() {
- return new Iterator() {
- private int i = 0;
- public boolean hasNext() {
- return i < length();
+ public interface GrammarCallback extends JSONCallback { }
+
+ public static class Grammar extends JavaScriptObject {
+ protected Grammar() { }
+
+ public final native String getName() /*-{ return this.name; }-*/;
+
+ public final native String getUserLanguage() /*-{ return this.userLanguage; }-*/;
+
+ public final native IterableJsArray getLanguages() /*-{ return this.languages; }-*/;
+
+ public final Language getLanguage(String name) {
+ int c = getLanguages().length();
+ for (int i = 0; i < c; i++) {
+ Language l = getLanguages().get(i);
+ if (l.getName().equals(name))
+ return l;
}
- public T next() {
- if (!hasNext()) {
- throw new NoSuchElementException();
- }
- return get(i++);
- }
- public void remove() {
- throw new UnsupportedOperationException();
- }
- };
+ return null;
}
- };
}
- }
- /* Grammar */
+ public static class Language extends JavaScriptObject {
+ protected Language() { }
- public PGFRequest grammar (final GrammarCallback callback) {
- return sendRequest("grammar", null, callback);
- }
-
- public interface GrammarCallback extends GFCallback { }
-
- public static class Grammar extends JavaScriptObject {
- protected Grammar() { }
-
- public final native String getName() /*-{ return this.name; }-*/;
-
- public final native String getUserLanguage() /*-{ return this.userLanguage; }-*/;
-
- public final native IterableJsArray getLanguages() /*-{ return this.languages; }-*/;
-
- public final Language getLanguage(String name) {
- int c = getLanguages().length();
- for (int i = 0; i < c; i++) {
- Language l = getLanguages().get(i);
- if (l.getName().equals(name))
- return l;
- }
- return null;
+ public final native String getName() /*-{ return this.name; }-*/;
+ public final native String getLanguageCode() /*-{ return this.languageCode; }-*/;
+ public final native boolean canParse() /*-{ return this.canParse; }-*/;
}
- }
- public static class Language extends JavaScriptObject {
- protected Language() { }
+ /* Translation */
- public final native String getName() /*-{ return this.name; }-*/;
- public final native String getLanguageCode() /*-{ return this.languageCode; }-*/;
- public final native boolean canParse() /*-{ return this.canParse; }-*/;
- }
-
- /* Translation */
-
- public PGFRequest translate (String input, List fromLangs, String cat, List toLangs,
- final TranslateCallback callback) {
- List args = new ArrayList();
- args.add(new Arg("input", input));
- if (fromLangs != null) {
- for (String from : fromLangs) {
- args.add(new Arg("from", from));
- }
- }
- args.add(new Arg("cat", cat));
- if (toLangs != null) {
- for (String to : toLangs) {
- args.add(new Arg("to", to));
- }
- }
- return sendRequest("translate", args, callback);
- }
-
- public interface TranslateCallback extends GFCallback { }
-
- public static class Translations extends IterableJsArray {
- protected Translations() { }
- }
-
- public static class Translation extends JavaScriptObject {
- protected Translation() { }
-
- public final native String getFrom() /*-{ return this.from; }-*/;
- public final native String getTo() /*-{ return this.to; }-*/;
- public final native String getText() /*-{ return this.text; }-*/;
- }
-
- /* Completion */
-
- public PGFRequest complete (String input, List fromLangs, String cat, int limit, final CompleteCallback callback) {
- List args = new ArrayList();
- args.add(new Arg("input", input));
- if (fromLangs != null) {
- for (String from : fromLangs) {
- args.add(new Arg("from", from));
- }
- }
- args.add(new Arg("cat", cat));
- args.add(new Arg("limit", limit));
- return sendRequest("complete", args, callback);
- }
-
- public interface CompleteCallback extends GFCallback { }
-
- public static class Completions extends IterableJsArray {
- protected Completions() { }
- }
-
- public static class Completion extends JavaScriptObject {
- protected Completion() { }
-
- public final native String getFrom() /*-{ return this.from; }-*/;
- public final native String getText() /*-{ return this.text; }-*/;
- }
-
- /* Parsing */
-
- public PGFRequest parse (String input, List fromLangs, String cat, final ParseCallback callback) {
- List args = new ArrayList();
- args.add(new Arg("input", input));
- if (fromLangs != null) {
- for (String from : fromLangs) {
- args.add(new Arg("from", from));
- }
- }
- args.add(new Arg("cat", cat));
- return sendRequest("parse", args, callback);
- }
-
- public interface ParseCallback extends GFCallback { }
-
- public static class ParseResults extends IterableJsArray {
- protected ParseResults() { }
- }
-
- public static class ParseResult extends JavaScriptObject {
- protected ParseResult() { }
-
- public final native String getFrom() /*-{ return this.from; }-*/;
- public final native String getTree() /*-{ return this.tree; }-*/;
- }
-
- /* Utilities */
-
- private PGFRequest sendRequest (String resource, List vars, final GFCallback callback) {
- String url = baseURL + "/" + pgfName + "/" + resource + "?" + buildQueryString(vars);
- RequestBuilder builder = new RequestBuilder(RequestBuilder.GET, url);
- builder.setTimeoutMillis(30000);
- builder.setHeader("Accept","text/plain, text/html;q=0.5, */*;q=0.1");
- Request request = null;
-
- try {
- request = builder.sendRequest(null, new RequestCallback() {
- public void onError(Request request, Throwable e) {
- callback.onError(e);
- }
-
- public void onResponseReceived(Request request, Response response) {
- if (200 == response.getStatusCode()) {
- callback.onResult((T)eval(response.getText()).cast());
- } else {
- RequestException e = new RequestException("Response not OK: " + response.getStatusCode() + ". " + response.getText());
- callback.onError(e);
+ public JSONRequest translate (String input, List fromLangs, String cat, List toLangs,
+ final TranslateCallback callback) {
+ List args = new ArrayList();
+ args.add(new Arg("input", input));
+ if (fromLangs != null) {
+ for (String from : fromLangs) {
+ args.add(new Arg("from", from));
}
- }
- });
- } catch (RequestException e) {
- callback.onError(e);
- }
-
- return new PGFRequest(request);
- }
-
- private static native JavaScriptObject eval(String json) /*-{
- return eval('(' + json + ')');
- }-*/;
-
- private static class Arg {
- public final String name;
- public final String value;
- public Arg (String name, String value) {
- this.name = name;
- this.value = value;
- }
- public Arg (String name, int value) {
- this(name, Integer.toString(value));
- }
- }
-
- private static String buildQueryString(List args) {
- StringBuffer sb = new StringBuffer();
- if (args != null) {
- for (Arg arg : args) {
- if (arg.value != null) {
- if (sb.length() > 0) {
- sb.append("&");
- }
- sb.append(URL.encodeComponent(arg.name));
- sb.append("=");
- sb.append(URL.encodeComponent(arg.value));
}
- }
+ args.add(new Arg("cat", cat));
+ if (toLangs != null) {
+ for (String to : toLangs) {
+ args.add(new Arg("to", to));
+ }
+ }
+ return sendRequest("translate", args, callback);
+ }
+
+ public interface TranslateCallback extends JSONCallback { }
+
+ public static class Translations extends IterableJsArray {
+ protected Translations() { }
+ }
+
+ public static class Translation extends JavaScriptObject {
+ protected Translation() { }
+
+ public final native String getFrom() /*-{ return this.from; }-*/;
+ public final native String getTo() /*-{ return this.to; }-*/;
+ public final native String getText() /*-{ return this.text; }-*/;
+ }
+
+ /* Completion */
+
+ public JSONRequest complete (String input, List fromLangs, String cat, int limit, final CompleteCallback callback) {
+ List args = new ArrayList();
+ args.add(new Arg("input", input));
+ if (fromLangs != null) {
+ for (String from : fromLangs) {
+ args.add(new Arg("from", from));
+ }
+ }
+ args.add(new Arg("cat", cat));
+ args.add(new Arg("limit", limit));
+ return sendRequest("complete", args, callback);
+ }
+
+ public interface CompleteCallback extends JSONCallback { }
+
+ public static class Completions extends IterableJsArray {
+ protected Completions() { }
+ }
+
+ public static class Completion extends JavaScriptObject {
+ protected Completion() { }
+
+ public final native String getFrom() /*-{ return this.from; }-*/;
+ public final native String getText() /*-{ return this.text; }-*/;
+ }
+
+ /* Parsing */
+
+ public JSONRequest parse (String input, List fromLangs, String cat, final ParseCallback callback) {
+ List args = new ArrayList();
+ args.add(new Arg("input", input));
+ if (fromLangs != null) {
+ for (String from : fromLangs) {
+ args.add(new Arg("from", from));
+ }
+ }
+ args.add(new Arg("cat", cat));
+ return sendRequest("parse", args, callback);
+ }
+
+ public interface ParseCallback extends JSONCallback { }
+
+ public static class ParseResults extends IterableJsArray {
+ protected ParseResults() { }
+ }
+
+ public static class ParseResult extends JavaScriptObject {
+ protected ParseResult() { }
+
+ public final native String getFrom() /*-{ return this.from; }-*/;
+ public final native String getTree() /*-{ return this.tree; }-*/;
+ }
+
+ /* Common */
+
+ public JSONRequest sendRequest(String resource, List args, final JSONCallback callback) {
+ return JSONRequestBuilder.sendRequest(baseURL + "/" + pgfName + "/" + resource, args, callback);
}
- return sb.toString();
- }
}
\ No newline at end of file
diff --git a/src/server/gwt/src/se/chalmers/cs/gf/gwt/client/PGFRequest.java b/src/server/gwt/src/se/chalmers/cs/gf/gwt/client/PGFRequest.java
deleted file mode 100644
index b46ad9382..000000000
--- a/src/server/gwt/src/se/chalmers/cs/gf/gwt/client/PGFRequest.java
+++ /dev/null
@@ -1,19 +0,0 @@
-package se.chalmers.cs.gf.gwt.client;
-
-import com.google.gwt.http.client.*;
-
-public class PGFRequest {
-
- private Request httpRequest;
-
- PGFRequest (Request httpRequest) {
- this.httpRequest = httpRequest;
- }
-
- public void cancel() {
- if (httpRequest != null) {
- httpRequest.cancel();
- }
- }
-
-}
\ No newline at end of file
diff --git a/src/server/gwt/src/se/chalmers/cs/gf/gwt/client/TranslateApp.java b/src/server/gwt/src/se/chalmers/cs/gf/gwt/client/TranslateApp.java
index 54a65fa20..406ebba4b 100644
--- a/src/server/gwt/src/se/chalmers/cs/gf/gwt/client/TranslateApp.java
+++ b/src/server/gwt/src/se/chalmers/cs/gf/gwt/client/TranslateApp.java
@@ -4,13 +4,8 @@ import com.google.gwt.core.client.EntryPoint;
import com.google.gwt.user.client.ui.Button;
import com.google.gwt.user.client.ui.ChangeListener;
import com.google.gwt.user.client.ui.ClickListener;
-import com.google.gwt.user.client.ui.DockPanel;
-import com.google.gwt.user.client.ui.DialogBox;
-import com.google.gwt.user.client.ui.Grid;
-import com.google.gwt.user.client.ui.Image;
import com.google.gwt.user.client.ui.HorizontalPanel;
import com.google.gwt.user.client.ui.Label;
-import com.google.gwt.user.client.ui.ListBox;
import com.google.gwt.user.client.ui.PopupPanel;
import com.google.gwt.user.client.ui.RootPanel;
import com.google.gwt.user.client.ui.SuggestBox;
@@ -20,13 +15,6 @@ import com.google.gwt.user.client.ui.KeyboardListenerAdapter;
import com.google.gwt.core.client.GWT;
-import com.google.gwt.user.client.Window;
-
-import com.google.gwt.i18n.client.LocaleInfo;
-
-import java.util.ArrayList;
-import java.util.List;
-import java.util.Set;
public class TranslateApp implements EntryPoint {