Revision ebead1b5 src/gr/grnet/pithos/web/client/FileUploadDialog.java
b/src/gr/grnet/pithos/web/client/FileUploadDialog.java | ||
---|---|---|
45 | 45 |
import com.google.gwt.user.client.Command; |
46 | 46 |
import com.google.gwt.user.client.Cookies; |
47 | 47 |
import com.google.gwt.user.client.Event.NativePreviewEvent; |
48 |
import com.google.gwt.user.client.Window;
|
|
48 |
import com.google.gwt.user.client.ui.Anchor;
|
|
49 | 49 |
import com.google.gwt.user.client.ui.Button; |
50 | 50 |
import com.google.gwt.user.client.ui.DialogBox; |
51 | 51 |
import com.google.gwt.user.client.ui.FileUpload; |
... | ... | |
54 | 54 |
import com.google.gwt.user.client.ui.FormPanel.SubmitCompleteHandler; |
55 | 55 |
import com.google.gwt.user.client.ui.FormPanel.SubmitEvent; |
56 | 56 |
import com.google.gwt.user.client.ui.FormPanel.SubmitHandler; |
57 |
import com.google.gwt.user.client.ui.Anchor; |
|
58 | 57 |
import com.google.gwt.user.client.ui.Grid; |
59 | 58 |
import com.google.gwt.user.client.ui.HasHorizontalAlignment; |
60 | 59 |
import com.google.gwt.user.client.ui.Hidden; |
... | ... | |
143 | 142 |
// form. |
144 | 143 |
submit = new Button("Upload", new ClickHandler() { |
145 | 144 |
@Override |
146 |
public void onClick(@SuppressWarnings("unused") ClickEvent event) {
|
|
145 |
public void onClick(ClickEvent event) { |
|
147 | 146 |
prepareAndSubmit(); |
148 | 147 |
} |
149 | 148 |
}); |
... | ... | |
154 | 153 |
form.addSubmitHandler(new SubmitHandler() { |
155 | 154 |
|
156 | 155 |
@Override |
157 |
public void onSubmit(@SuppressWarnings("unused") SubmitEvent event) {
|
|
156 |
public void onSubmit(SubmitEvent event) { |
|
158 | 157 |
auth.setValue(app.getToken()); //This is done here because the app object is not available in the constructor |
159 | 158 |
Cookies.setCookie("X-Auth-Token", app.getToken(), null, "", "/", false); |
160 | 159 |
} |
Also available in: Unified diff