From f4b3bca9a219dab0cdb37b59d347f8113e7eb0b5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tomasz=20P=C3=B3=C5=82grabia?= Date: Mon, 19 Sep 2016 21:27:39 +0200 Subject: [PATCH] Cannot be cancelled. --- .../main/java/pl/tpolgrabia/urbanexplorer/MainActivity.java | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/app/src/main/java/pl/tpolgrabia/urbanexplorer/MainActivity.java b/app/src/main/java/pl/tpolgrabia/urbanexplorer/MainActivity.java index cfafa38..bdeb93a 100644 --- a/app/src/main/java/pl/tpolgrabia/urbanexplorer/MainActivity.java +++ b/app/src/main/java/pl/tpolgrabia/urbanexplorer/MainActivity.java @@ -47,7 +47,6 @@ public class MainActivity extends ActionBarActivity { private static final Logger lg = LoggerFactory.getLogger(MainActivity.class); private static final int LOCATION_SETTINGS_REQUEST_ID = 1; - private static final String CLASS_TAG = MainActivity.class.getSimpleName(); private static final String PHOTO_BACKSTACK = "PHOTO_BACKSTACK"; private static final int HOME_FRAGMENT_ID = 0; private static final int WIKI_FRAGMENT_ID = 1; @@ -57,7 +56,6 @@ public class MainActivity extends ActionBarActivity { private static final int SETTINGS_ID_INTENT_REQUEST_ID = 2; private static final String PHOTO_INFO = "PHOTO_INFO"; private static final String FIRST_TIME_LAUNCH = "FIRST_TIME_LAUNCH_KEY"; - private static final String MAIN_BACKSTACK = "MAIN_BACKSTACK_KEY"; private static final String SAVED_CONFIG_KEY = "SAVED_CONFIG_KEY"; public static DisplayImageOptions options; private GestureDetectorCompat gestureDetector; @@ -103,6 +101,7 @@ public class MainActivity extends ActionBarActivity { currentFragmentId = 0; progressDlg = new ProgressDialog(this); + progressDlg.setCancelable(false); // UNIVERSAL IMAGE LOADER SETUP DisplayImageOptions defaultOptions = ImageLoaderUtils.createDefaultOptions(); @@ -164,7 +163,7 @@ public class MainActivity extends ActionBarActivity { return true; case R.id.refresh: progressDlg.setMessage("Refreshing results"); - progressDlg.show(); + showProgress(); refreshFragment(); return true; default: