File tree Expand file tree Collapse file tree 1 file changed +4
-4
lines changed
tools/SDKUpdater/src/processing/mode/android/tools Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -415,9 +415,7 @@ public String getColumnName(int column) {
415
415
actionButton .addActionListener (new ActionListener () {
416
416
public void actionPerformed (ActionEvent e ) {
417
417
if (downloadTaskRunning ) { // i.e button state is Cancel
418
- downloadTask .cancel (true );
419
- status .setText ("Download cancelled" );
420
- actionButton .setText ("Update" );
418
+ cancelTasks ();
421
419
} else { // i.e button state is Update
422
420
downloadTask = new DownloadTask ();
423
421
progressBar .setIndeterminate (true );
@@ -499,9 +497,11 @@ public void windowClosing(WindowEvent e) {
499
497
public void cancelTasks () {
500
498
queryTask .cancel (true );
501
499
if (downloadTaskRunning ) {
500
+ downloadTask .cancel (true );
501
+ status .setText ("Download cancelled" );
502
502
JOptionPane .showMessageDialog (null ,
503
503
"Download cancelled" , "Warning" , JOptionPane .WARNING_MESSAGE );
504
- downloadTask . cancel ( true );
504
+ actionButton . setText ( "Update" );
505
505
}
506
506
}
507
507
You can’t perform that action at this time.
0 commit comments