processing-android icon indicating copy to clipboard operation
processing-android copied to clipboard

Progress bar in SDK updater is indeterminate

Open codeanticode opened this issue 8 years ago • 3 comments

Right now, the progress bar in the SDK updater is set to indeterminate mode, because the getFraction() method in the ConsoleProgressIndicator object used in the query and download tasks returns 0.

This code from the Android Plugin for IntelliJ IDEA can help understanding more advanced users of the progress indicator and the download functionality:

My impression is that the current progress has to be set somehow using progress.setFraction(), so it can then can be retrieved with progress.getFraction().

codeanticode avatar Jul 27 '17 13:07 codeanticode

@codeanticode , The link that "This code" refers to has been removed(404 Error). Can you check it ?

DeerajTheepshi avatar Mar 21 '19 10:03 DeerajTheepshi

@DeerajTheepshi thanks for flagging this, will take a look shortly

codeanticode avatar Mar 21 '19 12:03 codeanticode

@codeanticode and @kfrajer , The getFraction function works . I'm not sure why this issue was raised , but it seems to be working fine. The setFraction method is taken care by the android libraries. So it does not pose a problem. The only issue is that the same consoleProgress object is used for 3 different process :

  • Loading the repo
  • Preparing the installer files and the install process itself
  • Completion of the install process

As a result of which, the progressBar would load from 0 ,three times. We could notify the user about these three stages via the status text on the updater.

DeerajTheepshi avatar Jun 22 '19 06:06 DeerajTheepshi