Bug 942231 - Define constant with default value for 'can load' hint (r=margaret)
☠☠ backed out by d6798ed0b4ea ☠ ☠
authorLucas Rocha <lucasr@mozilla.com>
Thu, 12 Dec 2013 10:55:36 +0000
changeset 159973 7744ed51864c82fe82c060dc4df835565f488c88
parent 159972 c521a1683852a308dadfba1c41407b0b5c2872a7
child 159974 64376a7a08df4620b21c8b08cda8462ab4bbb14c
push id3931
push userlrocha@mozilla.com
push dateThu, 12 Dec 2013 10:55:57 +0000
treeherderfx-team@64376a7a08df [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersmargaret
bugs942231
milestone29.0a1
Bug 942231 - Define constant with default value for 'can load' hint (r=margaret)
mobile/android/base/home/HomeFragment.java
--- a/mobile/android/base/home/HomeFragment.java
+++ b/mobile/android/base/home/HomeFragment.java
@@ -39,33 +39,36 @@ import android.widget.Toast;
  */
 abstract class HomeFragment extends Fragment {
     // Log Tag.
     private static final String LOGTAG="GeckoHomeFragment";
 
     // Share MIME type.
     private static final String SHARE_MIME_TYPE = "text/plain";
 
+    // Default value for "can load" hint
+    static final boolean DEFAULT_CAN_LOAD_HINT = false;
+
     // Whether the fragment can load its content or not
     // This is used to defer data loading until the editing
     // mode animation ends.
     private boolean mCanLoadHint;
 
     // Whether the fragment has loaded its content
     private boolean mIsLoaded;
 
     @Override
     public void onCreate(Bundle savedInstanceState) {
         super.onCreate(savedInstanceState);
 
         final Bundle args = getArguments();
         if (args != null) {
-            mCanLoadHint = args.getBoolean(HomePager.CAN_LOAD_ARG, false);
+            mCanLoadHint = args.getBoolean(HomePager.CAN_LOAD_ARG, DEFAULT_CAN_LOAD_HINT);
         } else {
-            mCanLoadHint = false;
+            mCanLoadHint = DEFAULT_CAN_LOAD_HINT;
         }
 
         mIsLoaded = false;
     }
 
     @Override
     public void onCreateContextMenu(ContextMenu menu, View view, ContextMenuInfo menuInfo) {
         if (menuInfo == null || !(menuInfo instanceof HomeContextMenuInfo)) {