mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 531703 - Minimize disk space usage on Windows CE. r+a=vladimir
This commit is contained in:
parent
dd2838505e
commit
0cfb131c4b
@ -311,8 +311,13 @@ pref("browser.microsummary.updateGenerators", true);
|
||||
pref("browser.search.suggest.enabled", true);
|
||||
|
||||
pref("browser.sessionhistory.max_entries", 50);
|
||||
#ifndef WINCE
|
||||
pref("browser.history_expire_days", 180);
|
||||
pref("browser.history_expire_days_min", 90);
|
||||
#else
|
||||
pref("browser.history_expire_days", 90);
|
||||
pref("browser.history_expire_days_min", 45);
|
||||
#endif
|
||||
pref("browser.history_expire_sites", 40000);
|
||||
|
||||
// handle links targeting new windows
|
||||
|
@ -316,6 +316,18 @@ BrowserGlue.prototype = {
|
||||
// profile shutdown handler (contains profile cleanup routines)
|
||||
_onProfileShutdown: function()
|
||||
{
|
||||
#ifdef WINCE
|
||||
// If there's a pending update, clear cache to free up disk space.
|
||||
try {
|
||||
let um = Cc["@mozilla.org/updates/update-manager;1"].
|
||||
getService(Ci.nsIUpdateManager);
|
||||
if (um.activeUpdate && um.activeUpdate.state == "pending") {
|
||||
let cacheService = Cc["@mozilla.org/network/cache-service;1"].
|
||||
getService(Ci.nsICacheService);
|
||||
cacheService.evictEntries(Ci.nsICache.STORE_ANYWHERE);
|
||||
}
|
||||
} catch (e) { }
|
||||
#endif
|
||||
this._shutdownPlaces();
|
||||
this._idleService.removeIdleObserver(this, BOOKMARKS_BACKUP_IDLE_TIME);
|
||||
this._isIdleObserver = false;
|
||||
|
@ -59,7 +59,11 @@ pref("general.warnOnAboutConfig", true);
|
||||
pref("browser.bookmarks.max_backups", 5);
|
||||
|
||||
pref("browser.cache.disk.enable", true);
|
||||
#ifndef WINCE
|
||||
pref("browser.cache.disk.capacity", 51200);
|
||||
#else
|
||||
pref("browser.cache.disk.capacity", 20000);
|
||||
#endif
|
||||
pref("browser.cache.memory.enable", true);
|
||||
//pref("browser.cache.memory.capacity", -1);
|
||||
// -1 = determine dynamically, 0 = none, n = memory capacity in kilobytes
|
||||
@ -68,6 +72,7 @@ pref("browser.cache.disk_cache_ssl", false);
|
||||
pref("browser.cache.check_doc_frequency", 3);
|
||||
|
||||
pref("browser.cache.offline.enable", true);
|
||||
#ifndef WINCE
|
||||
// offline cache capacity in kilobytes
|
||||
pref("browser.cache.offline.capacity", 512000);
|
||||
|
||||
@ -78,6 +83,12 @@ pref("offline-apps.quota.max", 204800);
|
||||
// the user should be warned if offline app disk usage exceeds this amount
|
||||
// (in kilobytes)
|
||||
pref("offline-apps.quota.warn", 51200);
|
||||
#else
|
||||
// Limited disk space on WinCE, tighten limits.
|
||||
pref("browser.cache.offline.capacity", 15000);
|
||||
pref("offline-apps.quota.max", 7000);
|
||||
pref("offline-apps.quota.warn", 4000);
|
||||
#endif
|
||||
|
||||
// Fastback caching - if this pref is negative, then we calculate the number
|
||||
// of content viewers to cache based on the amount of available memory.
|
||||
|
Loading…
Reference in New Issue
Block a user