Today I started porting an app to Android L preview in order to have it almost ready when the final product launches. One problem I found is that I can't have an indeterminate progressbar on the ActionBar. It doesn't show at all and throws this error on logcat:
E/PhoneWindow﹕ Circular progress bar not located in current window decor
I'm using this code, which works in <4.4:
requestWindowFeature(Window.FEATURE_INDETERMINATE_PROGRESS);
setProgressBarIndeterminateVisibility(true);
Is there any way to get it working again in Android L or should I use an external ProgressBar?
Android ProgressBar is a graphical view indicator that shows some progress. Android progress bar displays a bar representing the completing of the task. Progress bar in android is useful since it gives the user an idea of time to finish its task.
Android ProgressBar Indeterminate ProgressBar An indeterminate ProgressBar shows a cyclic animation without an indication of progress.
I've just found this question and checked the bug report.
It seems that the dev team had concluded that the issue won't be fixed.
That is:
intended as the progress bar features are not supported on Material action bars.
The "Material action bar" should mean 4.4 (API19) or later's action bar.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With