diff options
author | cyBerta <cyberta@riseup.net> | 2023-07-31 17:50:04 +0200 |
---|---|---|
committer | cyBerta <cyberta@riseup.net> | 2023-07-31 17:50:04 +0200 |
commit | 4d9018316fa5a9af714de44224a440e0fa78be57 (patch) | |
tree | eeb74fa7d36c52353a2dd053ca847f8303d0fd01 /app/src/main/java/se/leap/bitmaskclient/base/views | |
parent | addf8d89962bf3de6d70330f9264d0e4d866613e (diff) |
add cancel button, call provider stetup command in ConfigureProviderFragment and listen to the result, implementing happy path
Diffstat (limited to 'app/src/main/java/se/leap/bitmaskclient/base/views')
-rw-r--r-- | app/src/main/java/se/leap/bitmaskclient/base/views/ProgressSpinner.java | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/app/src/main/java/se/leap/bitmaskclient/base/views/ProgressSpinner.java b/app/src/main/java/se/leap/bitmaskclient/base/views/ProgressSpinner.java index b0b81624..380ddf23 100644 --- a/app/src/main/java/se/leap/bitmaskclient/base/views/ProgressSpinner.java +++ b/app/src/main/java/se/leap/bitmaskclient/base/views/ProgressSpinner.java @@ -48,6 +48,16 @@ public class ProgressSpinner extends RelativeLayout { } public void update(int progress) { - textView.setText(textView.getContext().getString(R.string.percentage, progress)); + String text = ""; + if (progress > 0) { + if ((progress / 10) == 0) { + text = text + " "; + } + if ((progress / 100) == 0) { + text = text + " "; + } + text = text + progress + "%"; + } + textView.setText(text); } } |