[Android] [PATCH] Restore loop not needed anymore and causing UI bug

Geoffrey Métais geoffrey.metais at gmail.com
Mon Feb 9 11:58:56 CET 2015


---
 vlc-android/src/org/videolan/vlc/gui/MainActivity.java | 14 --------------
 1 file changed, 14 deletions(-)

diff --git a/vlc-android/src/org/videolan/vlc/gui/MainActivity.java b/vlc-android/src/org/videolan/vlc/gui/MainActivity.java
index d7b62de..b0570df 100644
--- a/vlc-android/src/org/videolan/vlc/gui/MainActivity.java
+++ b/vlc-android/src/org/videolan/vlc/gui/MainActivity.java
@@ -318,20 +318,6 @@ public class MainActivity extends ActionBarActivity implements OnItemClickListen
         }
 
         /**
-         * Let's see if Android recreated anything for us in the bundle.
-         * Prevent duplicate creation of fragments, since mSidebarAdapter might
-         * have been purged (losing state) when this activity was killed.
-         */
-        for(int i = 0; i < SidebarAdapter.entries.size(); i++) {
-            String fragmentTag = SidebarAdapter.entries.get(i).id;
-            Fragment fragment = getSupportFragmentManager().findFragmentByTag(fragmentTag);
-            if(fragment != null) {
-                Log.d(TAG, "Restoring automatically recreated fragment \"" + fragmentTag + "\"");
-                mSidebarAdapter.restoreFragment(fragmentTag, fragment);
-            }
-        }
-
-        /**
          * Restore the last view.
          *
          * Replace:
-- 
2.1.0



More information about the Android mailing list