mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 875924 - Initialize the NewTabUtils thumbnail expiration filter [r=sfoster]
This commit is contained in:
parent
5382a14a1e
commit
33acc6693c
@ -8,10 +8,6 @@
|
||||
* singleton to provide data-level functionality to the views
|
||||
*/
|
||||
let TopSites = {
|
||||
_initialized: false,
|
||||
|
||||
Site: Site,
|
||||
|
||||
prepareCache: function(aForce){
|
||||
// front to the NewTabUtils' links cache
|
||||
// -ensure NewTabUtils.links links are pre-cached
|
||||
@ -151,6 +147,7 @@ let TopSites = {
|
||||
this._sitesDirty.clear();
|
||||
this.update();
|
||||
},
|
||||
|
||||
_linkFromNode: function _linkFromNode(aNode) {
|
||||
return {
|
||||
url: aNode.getAttribute("value"),
|
||||
|
@ -16,6 +16,9 @@ XPCOMUtils.defineLazyModuleGetter(this, "Downloads",
|
||||
XPCOMUtils.defineLazyModuleGetter(this, "FormHistory",
|
||||
"resource://gre/modules/FormHistory.jsm");
|
||||
|
||||
XPCOMUtils.defineLazyModuleGetter(this, "PageThumbs",
|
||||
"resource://gre/modules/PageThumbs.jsm");
|
||||
|
||||
XPCOMUtils.defineLazyModuleGetter(this, "PluralForm",
|
||||
"resource://gre/modules/PluralForm.jsm");
|
||||
|
||||
|
@ -4,7 +4,6 @@
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||
"use strict";
|
||||
|
||||
Cu.import("resource://gre/modules/PageThumbs.jsm");
|
||||
Cu.import("resource://gre/modules/devtools/dbg-server.jsm")
|
||||
|
||||
/**
|
||||
@ -108,6 +107,7 @@ var BrowserUI = {
|
||||
PanelUI.init();
|
||||
FlyoutPanelsUI.init();
|
||||
PageThumbs.init();
|
||||
NewTabUtils.init();
|
||||
SettingsCharm.init();
|
||||
NavButtonSlider.init();
|
||||
|
||||
|
@ -21,7 +21,6 @@ function TopSitesView(aGrid, aMaxSites) {
|
||||
getService(Ci.nsINavHistoryService);
|
||||
history.addObserver(this, false);
|
||||
|
||||
PageThumbs.addExpirationFilter(this);
|
||||
Services.obs.addObserver(this, "Metro:RefreshTopsiteThumbnail", false);
|
||||
|
||||
NewTabUtils.allPages.register(this);
|
||||
@ -40,7 +39,6 @@ TopSitesView.prototype = Util.extend(Object.create(View.prototype), {
|
||||
|
||||
destruct: function destruct() {
|
||||
Services.obs.removeObserver(this, "Metro:RefreshTopsiteThumbnail");
|
||||
PageThumbs.removeExpirationFilter(this);
|
||||
NewTabUtils.allPages.unregister(this);
|
||||
if (StartUI.chromeWin) {
|
||||
StartUI.chromeWin.removeEventListener('MozAppbarDismissing', this, false);
|
||||
@ -216,10 +214,6 @@ TopSitesView.prototype = Util.extend(Object.create(View.prototype), {
|
||||
}
|
||||
},
|
||||
|
||||
filterForThumbnailExpiration: function filterForThumbnailExpiration(aCallback) {
|
||||
aCallback([item.getAttribute("value") for (item of this._set.children)]);
|
||||
},
|
||||
|
||||
isFirstRun: function isFirstRun() {
|
||||
return prefs.getBoolPref("browser.firstrun.show.localepicker");
|
||||
},
|
||||
|
Loading…
Reference in New Issue
Block a user