Subversion Repository Public Repository

litesoft

Diff Revisions 536 vs 537 for /trunk/GWT_Sandbox/Upload/src/org/litesoft/sandbox/csapp/client/widgets/UploadWidget.java

Diff revisions: vs.
  @@ -25,7 +25,7 @@
25 25 private final FileUpload upload = createFileUploadWidget();
26 26 private final FormPanel formPanel = createFormPanel( upload );
27 27 private final SimplePanel viewPort = createViewPort( createFormFloater( formPanel ) );
28 - private final ButtonBase illusionaryClickWidget;
28 + private final ButtonBase illusionaryClickWidget, removeButton;
29 29 private final Widget sizingWidget;
30 30
31 31 private final int secondsToWait;
  @@ -38,8 +38,9 @@
38 38 private Timer timer;
39 39 private boolean sized = false;
40 40
41 - public UploadWidget( ButtonBase illusionaryClickWidget, int secondsToWait, Callback callback )
41 + public UploadWidget( ButtonBase illusionaryClickWidget, ButtonBase removeButton, int secondsToWait, Callback callback )
42 42 {
43 + this.removeButton = removeButton;
43 44 this.secondsToWait = secondsToWait;
44 45 this.callback = callback;
45 46 externallyEnabled = illusionaryClickWidget.isEnabled();
  @@ -74,6 +75,7 @@
74 75 private void enableWidgets( boolean enable )
75 76 {
76 77 enable &= externallyEnabled;
78 + removeButton.setEnabled( enable );
77 79 illusionaryClickWidget.setEnabled( enable );
78 80 upload.setEnabled( enable );
79 81 }