From 06b98e2c28f93f2294f3e6f88ba3812e8b8751e4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Parm=C3=A9nides=20GV?= Date: Thu, 12 Mar 2015 13:50:10 +0100 Subject: Show progress bar if connecting. --- app/src/main/java/se/leap/bitmaskclient/EipFragment.java | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'app/src/main') diff --git a/app/src/main/java/se/leap/bitmaskclient/EipFragment.java b/app/src/main/java/se/leap/bitmaskclient/EipFragment.java index 680f21e1..6dbdf961 100644 --- a/app/src/main/java/se/leap/bitmaskclient/EipFragment.java +++ b/app/src/main/java/se/leap/bitmaskclient/EipFragment.java @@ -294,16 +294,22 @@ public class EipFragment extends Fragment implements Observer { String logmessage = eip_status.getLogMessage(); String prefix = dashboard.getString(localizedResId); + showProgressBar(); status_message.setText(prefix + " " + logmessage); is_starting_to_connect = false; adjustSwitch(); } private void updatingCertificateUI() { - progress_bar.setVisibility(View.VISIBLE); + showProgressBar(); status_message.setText(getString(R.string.updating_certificate_message)); } + private void showProgressBar() { + if(progress_bar != null) + progress_bar.setVisibility(View.VISIBLE); + } + private void hideProgressBar() { if(progress_bar != null) progress_bar.setVisibility(View.GONE); -- cgit v1.2.3