Bug 1155191 - Please disable readling list and reader view for 38. r=markh, a=me
authorJustin Dolske <dolske@mozilla.com>
Mon, 20 Apr 2015 15:15:45 -0700
changeset 260210 69173cc17556
parent 260205 a00d0de3202f
child 260211 8f9c08f19f6a
push id721
push userjlund@mozilla.com
push date2015-04-21 23:03 +0000
treeherdermozilla-release@d27c9211ebb3 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersmarkh, me
bugs1155191
milestone38.0
Bug 1155191 - Please disable readling list and reader view for 38. r=markh, a=me
browser/app/profile/firefox.js
browser/base/content/browser-readinglist.js
browser/base/content/test/general/browser_readerMode.js
browser/components/readinglist/test/browser/browser.ini
browser/components/readinglist/test/xpcshell/xpcshell.ini
toolkit/components/reader/AboutReader.jsm
toolkit/components/reader/moz.build
--- a/browser/app/profile/firefox.js
+++ b/browser/app/profile/firefox.js
@@ -1886,18 +1886,16 @@ pref("dom.ipc.processHangMonitor", true)
 #ifdef DEBUG
 // Don't report hangs in DEBUG builds. They're too slow and often a
 // debugger is attached.
 pref("dom.ipc.reportProcessHangs", false);
 #else
 pref("dom.ipc.reportProcessHangs", true);
 #endif
 
-// Enable ReadingList browser UI by default.
-pref("browser.readinglist.enabled", true);
+pref("reader.parse-on-load.enabled", false);
+pref("browser.readinglist.enabled", false);
 pref("browser.readinglist.sidebarEverOpened", false);
-
-// Enable the readinglist engine by default.
-pref("readinglist.scheduler.enabled", true);
+pref("readinglist.scheduler.enabled", false);
 pref("readinglist.server", "https://readinglist.services.mozilla.com/v1");
 
 // Don't limit how many nodes we care about on desktop:
 pref("reader.parse-node-limit", 0);
--- a/browser/base/content/browser-readinglist.js
+++ b/browser/base/content/browser-readinglist.js
@@ -66,17 +66,17 @@ let ReadingListUI = {
     }
   },
 
   /**
    * Whether the ReadingList feature is enabled or not.
    * @type {boolean}
    */
   get enabled() {
-    return Preferences.get("browser.readinglist.enabled", false);
+    return false;
   },
 
   /**
    * Whether the ReadingList sidebar is currently open or not.
    * @type {boolean}
    */
   get isSidebarOpen() {
     return SidebarUI.isOpen && SidebarUI.currentID == READINGLIST_COMMAND_ID;
--- a/browser/base/content/test/general/browser_readerMode.js
+++ b/browser/base/content/test/general/browser_readerMode.js
@@ -50,16 +50,18 @@ add_task(function* test_reader_button() 
   ok(readerUrl.startsWith("about:reader"), "about:reader loaded after clicking reader mode button");
   is_element_visible(readerButton, "Reader mode button is present on about:reader");
 
   is(gURLBar.value, readerUrl, "gURLBar value is about:reader URL");
   is(gURLBar.textValue, url.substring("http://".length), "gURLBar is displaying original article URL");
 
   // Readinglist button should be present, and status should be "openned", as the
   // first time in readerMode opens the Sidebar ReadingList as a feature introduction.
+/*
+  // Reading List test disabled, bug 1155191
   let listButton;
   yield promiseWaitForCondition(() =>
     listButton = gBrowser.contentDocument.getElementById("list-button"));
   is_element_visible(listButton, "List button is present on a reader-able page");
   yield promiseWaitForCondition(() => listButton.classList.contains("on"));
   ok(listButton.classList.contains("on"),
     "List button should indicate SideBar-ReadingList open.");
   ok(ReadingListUI.isSidebarOpen,
@@ -67,16 +69,17 @@ add_task(function* test_reader_button() 
 
   // Now close the Sidebar ReadingList.
   listButton.click();
   yield promiseWaitForCondition(() => !listButton.classList.contains("on"));
   ok(!listButton.classList.contains("on"),
     "List button should now indicate SideBar-ReadingList closed.");
   ok(!ReadingListUI.isSidebarOpen,
     "The ReadingListUI should now indicate SideBar-ReadingList closed.");
+*/
 
   // Switch page back out of reader mode.
   readerButton.click();
   yield promiseTabLoadEvent(tab);
   is(gBrowser.selectedBrowser.currentURI.spec, url,
     "Original page loaded after clicking active reader mode button");
 
   // Load a new tab that is NOT reader-able.
--- a/browser/components/readinglist/test/browser/browser.ini
+++ b/browser/components/readinglist/test/browser/browser.ini
@@ -1,7 +1,7 @@
 [DEFAULT]
 support-files =
   head.js
 
-[browser_ui_enable_disable.js]
-[browser_sidebar_list.js]
+;[browser_ui_enable_disable.js]
+;[browser_sidebar_list.js]
 ;[browser_sidebar_mouse_nav.js]
--- a/browser/components/readinglist/test/xpcshell/xpcshell.ini
+++ b/browser/components/readinglist/test/xpcshell/xpcshell.ini
@@ -1,9 +1,9 @@
 [DEFAULT]
 head = head.js
 firefox-appdir = browser
 
 [test_ReadingList.js]
 [test_ServerClient.js]
-[test_scheduler.js]
+#[test_scheduler.js]
 [test_SQLiteStore.js]
 [test_Sync.js]
--- a/toolkit/components/reader/AboutReader.jsm
+++ b/toolkit/components/reader/AboutReader.jsm
@@ -63,17 +63,21 @@ let AboutReader = function(mm, win, arti
 
   doc.addEventListener("visibilitychange", this, false);
 
   this._setupStyleDropdown();
   this._setupButton("close-button", this._onReaderClose.bind(this), "aboutReader.toolbar.close");
   this._setupButton("share-button", this._onShare.bind(this), "aboutReader.toolbar.share");
 
   try {
+#ifdef MOZ_FENNEC
     if (Services.prefs.getBoolPref("browser.readinglist.enabled")) {
+#else
+    if (false) {
+#endif
       this._setupButton("toggle-button", this._onReaderToggle.bind(this, "button"), "aboutReader.toolbar.addToReadingList");
       this._setupButton("list-button", this._onList.bind(this), "aboutReader.toolbar.openReadingList");
       this._setupButton("remove-button", this._onReaderToggle.bind(this, "footer"),
         "aboutReader.footer.deleteThisArticle", "aboutReader.footer.deleteThisArticle");
       this._doc.getElementById("reader-footer").setAttribute('readinglist-enabled', "true");
     }
   } catch (e) {
     // Pref doesn't exist.
--- a/toolkit/components/reader/moz.build
+++ b/toolkit/components/reader/moz.build
@@ -2,18 +2,24 @@
 # vim: set filetype=python:
 # This Source Code Form is subject to the terms of the Mozilla Public
 # License, v. 2.0. If a copy of the MPL was not distributed with this
 # file, You can obtain one at http://mozilla.org/MPL/2.0/.
 
 JAR_MANIFESTS += ['jar.mn']
 
 EXTRA_JS_MODULES += [
+  'ReaderMode.jsm'
+]
+
+EXTRA_PP_JS_MODULES += [
   'AboutReader.jsm',
-  'ReaderMode.jsm'
 ]
 
 EXTRA_JS_MODULES.reader = [
   'JSDOMParser.js',
   'Readability.js',
   'ReaderWorker.js',
   'ReaderWorker.jsm'
 ]
+
+if CONFIG['MOZ_BUILD_APP'] == 'mobile/android':
+    DEFINES['MOZ_FENNEC'] = True