Bug 1058100 - Load Sync snippets on first run. r=margaret
authorChenxia Liu <liuche@mozilla.com>
Mon, 25 Aug 2014 15:31:49 -0700
changeset 201557 b1cfad9bc2dbc22eef183bdf51c890e56b7fdda9
parent 201556 36bc6b13ac2c8344f7f8d97513d4fcb8460aa004
child 201558 d9ea224d0ebca9aec66d428d62454490db6623fb
push id27374
push userryanvm@gmail.com
push dateTue, 26 Aug 2014 18:16:27 +0000
treeherdermozilla-central@c850f3af9f2c [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersmargaret
bugs1058100
milestone34.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 1058100 - Load Sync snippets on first run. r=margaret
mobile/android/components/Snippets.js
--- a/mobile/android/components/Snippets.js
+++ b/mobile/android/components/Snippets.js
@@ -405,19 +405,22 @@ function Snippets() {}
 
 Snippets.prototype = {
   QueryInterface: XPCOMUtils.generateQI([Ci.nsIObserver, Ci.nsITimerCallback]),
   classID: Components.ID("{a78d7e59-b558-4321-a3d6-dffe2f1e76dd}"),
 
   observe: function(subject, topic, data) {
     switch(topic) {
       case "browser-delayed-startup-finished":
+        // Add snippets to be cycled through.
         if (Services.prefs.getBoolPref("browser.snippets.firstrunHomepage.enabled")) {
           loadHomePanelsBanner();
-        } else if (Services.prefs.getBoolPref("browser.snippets.syncPromo.enabled")) {
+        }
+
+        if (Services.prefs.getBoolPref("browser.snippets.syncPromo.enabled")) {
           loadSyncPromoBanner();
         }
 
         if (Services.prefs.getBoolPref("browser.snippets.enabled")) {
           loadSnippetsFromCache();
         }
         break;
     }