Skip to content

Commit

Permalink
Maybe disable Firefox Session Restore (fixes #488)
Browse files Browse the repository at this point in the history
  • Loading branch information
filips123 committed Sep 7, 2024
1 parent a902d5a commit a296eda
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
2 changes: 2 additions & 0 deletions native/userchrome/profile/chrome/pwa/boot.jsm
Original file line number Diff line number Diff line change
Expand Up @@ -119,6 +119,8 @@ function launchSite (siteConfig, urlList, isStartup) {

// Properly disable Firefox Session Restore and Private Window Separation
Services.prefs.getDefaultBranch(null).setBoolPref('browser.sessionstore.resume_from_crash', false);
Services.prefs.getDefaultBranch(null).setIntPref('browser.sessionstore.max_resumed_crashes', 0);
Services.prefs.getDefaultBranch(null).setIntPref('browser.sessionstore.idleDelay', -1);
Services.prefs.getDefaultBranch(null).setBoolPref('browser.privateWindowSeparation.enabled', false);
Services.prefs.getDefaultBranch(null).setBoolPref('browser.privacySegmentation.createdShortcut', true);

Expand Down
2 changes: 2 additions & 0 deletions native/userchrome/profile/chrome/pwa/content/browser.jsm
Original file line number Diff line number Diff line change
Expand Up @@ -1886,6 +1886,8 @@ class PwaBrowser {
xPref.set('browser.tabs.extraDragSpace', false, true);
xPref.set('browser.tabs.warnOnClose', false, true);
xPref.set('browser.sessionstore.resume_from_crash', false, true);
xPref.set('browser.sessionstore.max_resumed_crashes', 0, true);
xPref.set('browser.sessionstore.idleDelay', -1, true);
xPref.set('browser.shell.checkDefaultBrowser', false, true);
xPref.set('browser.startup.upgradeDialog.enabled', false, true);
xPref.set('browser.aboutwelcome.enabled', false, true);
Expand Down

0 comments on commit a296eda

Please sign in to comment.