Bug 802946 - Cleanup the 'Hide Apps/Promo' mess [backout the preprocessor code] r=blassey
authorMark Finkle <mfinkle@mozilla.com>
Tue, 23 Oct 2012 01:08:30 -0400
changeset 111114 618a14edc7e0aa5f3e81719e6717f5e5ec183188
parent 111113 1f5c210cc85508df38298fd34dcde23fbe744a87
child 111115 f55e223907b04b094b1623738cfb7c39d88e4b49
push id23727
push userryanvm@gmail.com
push dateTue, 23 Oct 2012 10:47:09 +0000
treeherdermozilla-central@43c585774a13 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersblassey
bugs802946
milestone19.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 802946 - Cleanup the 'Hide Apps/Promo' mess [backout the preprocessor code] r=blassey
mobile/android/base/AboutHomeContent.java
mobile/android/base/AboutHomeContent.java.in
mobile/android/base/Makefile.in
mobile/android/base/resources/menu-large-v11/browser_app_menu.xml.in
mobile/android/base/resources/menu-v11/browser_app_menu.xml.in
mobile/android/base/resources/menu-xlarge-v11/browser_app_menu.xml.in
mobile/android/base/resources/menu/browser_app_menu.xml.in
rename from mobile/android/base/AboutHomeContent.java.in
rename to mobile/android/base/AboutHomeContent.java
--- a/mobile/android/base/AboutHomeContent.java.in
+++ b/mobile/android/base/AboutHomeContent.java
@@ -211,29 +211,16 @@ public class AboutHomeContent extends Sc
     private void updateLayout(boolean syncIsSetup) {
         boolean hasTopSites = mTopSitesAdapter.getCount() > 0;
         setTopSitesVisibility(hasTopSites);
 
         AboutHomePromoBox.Type type = mPrelimPromoBoxType;
         if (syncIsSetup && type == AboutHomePromoBox.Type.SYNC)
             type = AboutHomePromoBox.Type.APPS;
 
-// Remove the Apps promo from Beta and Release until we get go-ahead from Marketplace team.
-// Two blocks are silly, but the preprocessor does not support complex expressions and I
-// am not trying to make something elegant here. This code should disappear soon or the
-// entire feature should be removed.
-#if MOZ_UPDATE_CHANNEL == beta
-        if (type == AboutHomePromoBox.Type.APPS)
-            type = (syncIsSetup ? AboutHomePromoBox.Type.NONE : AboutHomePromoBox.Type.SYNC);
-#endif
-#if MOZ_UPDATE_CHANNEL == release
-        if (type == AboutHomePromoBox.Type.APPS)
-            type = (syncIsSetup ? AboutHomePromoBox.Type.NONE : AboutHomePromoBox.Type.SYNC);
-#endif
-
         mPromoBox.show(type);
     }
 
     private void updateLayoutForSync() {
         final GeckoApp.StartupMode startupMode = mActivity.getStartupMode();
         final boolean syncIsSetup = SyncAccounts.syncAccountsExist(mContext);
 
         post(new Runnable() {
--- a/mobile/android/base/Makefile.in
+++ b/mobile/android/base/Makefile.in
@@ -30,16 +30,17 @@ UTIL_JAVA_FILES := \
   GeckoJarReader.java \
   INIParser.java \
   INISection.java \
   util/EventDispatcher.java \
   util/FloatUtils.java \
   $(NULL)
 
 FENNEC_JAVA_FILES = \
+  AboutHomeContent.java \
   AboutHomePromoBox.java \
   AboutHomeSection.java \
   ActivityHandlerHelper.java \
   AndroidImport.java \
   AndroidImportPreference.java \
   AnimatorProxy.java \
   AlertNotification.java \
   AnimatedHeightLayout.java \
@@ -181,17 +182,16 @@ FENNEC_JAVA_FILES = \
   $(NULL)
 
 ifdef MOZ_WEBSMS_BACKEND
 FENNEC_JAVA_FILES += GeckoSmsManager.java
 endif
 
 FENNEC_PP_JAVA_FILES = \
   App.java \
-  AboutHomeContent.java \
   MarketplaceApp.java \
   WebApp.java \
   WebApps.java \
   GeckoActivity.java \
   GeckoAppWidgetProvider.java \
   LauncherShortcuts.java \
   NotificationHandler.java \
   Restarter.java \
--- a/mobile/android/base/resources/menu-large-v11/browser_app_menu.xml.in
+++ b/mobile/android/base/resources/menu-large-v11/browser_app_menu.xml.in
@@ -48,24 +48,19 @@
             <item android:id="@+id/downloads"
                   android:icon="@drawable/ic_menu_downloads"
                   android:title="@string/downloads"/>
 
             <item android:id="@+id/addons"
                   android:icon="@drawable/ic_menu_addons"
                   android:title="@string/addons"/>
 
-#if MOZ_UPDATE_CHANNEL != beta
-#if MOZ_UPDATE_CHANNEL != release
             <item android:id="@+id/apps"
                   android:icon="@drawable/ic_menu_apps"
                   android:title="@string/apps"/>
-#endif
-#endif
-
         </menu>
 
     </item>
 
     <item android:id="@+id/char_encoding"
           android:visible="false"
           android:title="@string/char_encoding"/>
 
--- a/mobile/android/base/resources/menu-v11/browser_app_menu.xml.in
+++ b/mobile/android/base/resources/menu-v11/browser_app_menu.xml.in
@@ -49,24 +49,19 @@
             <item android:id="@+id/downloads"
                   android:icon="@drawable/ic_menu_downloads"
                   android:title="@string/downloads"/>
 
             <item android:id="@+id/addons"
                   android:icon="@drawable/ic_menu_addons"
                   android:title="@string/addons"/>
 
-#if MOZ_UPDATE_CHANNEL != beta
-#if MOZ_UPDATE_CHANNEL != release
             <item android:id="@+id/apps"
                   android:icon="@drawable/ic_menu_apps"
                   android:title="@string/apps"/>
-#endif
-#endif
-
         </menu>
 
     </item>
 
     <item android:id="@+id/char_encoding"
           android:visible="false"
           android:title="@string/char_encoding"/>
 
--- a/mobile/android/base/resources/menu-xlarge-v11/browser_app_menu.xml.in
+++ b/mobile/android/base/resources/menu-xlarge-v11/browser_app_menu.xml.in
@@ -49,24 +49,19 @@
             <item android:id="@+id/downloads"
                   android:icon="@drawable/ic_menu_downloads"
                   android:title="@string/downloads"/>
 
             <item android:id="@+id/addons"
                   android:icon="@drawable/ic_menu_addons"
                   android:title="@string/addons"/>
 
-#if MOZ_UPDATE_CHANNEL != beta
-#if MOZ_UPDATE_CHANNEL != release
             <item android:id="@+id/apps"
                   android:icon="@drawable/ic_menu_apps"
                   android:title="@string/apps"/>
-#endif
-#endif
-
         </menu>
 
     </item>
 
     <item android:id="@+id/char_encoding"
           android:visible="false"
           android:title="@string/char_encoding"/>
 
--- a/mobile/android/base/resources/menu/browser_app_menu.xml.in
+++ b/mobile/android/base/resources/menu/browser_app_menu.xml.in
@@ -37,22 +37,18 @@
           android:title="@string/new_pb_tab"/>
 
     <item android:id="@+id/addons"
           android:title="@string/addons"/>
 
     <item android:id="@+id/downloads"
           android:title="@string/downloads"/>
 
-#if MOZ_UPDATE_CHANNEL != beta
-#if MOZ_UPDATE_CHANNEL != release
     <item android:id="@+id/apps"
           android:title="@string/apps"/>
-#endif
-#endif
 
     <item android:id="@+id/char_encoding"
           android:visible="false"
           android:title="@string/char_encoding"/>
 
     <item android:id="@+id/settings"
           android:title="@string/settings" />