Closed Bug 904741 Opened 11 years ago Closed 11 years ago

Change session restore pref to have *two* states

Categories

(Firefox for Android Graveyard :: General, defect)

26 Branch
x86
macOS
defect
Not set
normal

Tracking

(firefox26+ verified, relnote-b2g ?, fennec26+)

VERIFIED FIXED
Firefox 26
Tracking Status
firefox26 + verified
relnote-b2g --- ?
fennec 26+ ---

People

(Reporter: ibarlow, Assigned: bnicholson)

References

Details

Attachments

(1 file)

After some discussion, it's come to light that bug 896515 isn't quite what we're after in a session restore pref. Partly because the fundamental problem we want to solve here is letting users decide what should happen when they *manually* quit and restart Firefox, and partly because it looks kind of bad to have an option that reads "In the event of a crash, do this"... As such, let's switch to a 2 stage pref like this: -------------------------------------------------------------- [Title] Tabs [Options] - Always restore - Don't restore after quitting Firefox -------------------------------------------------------------- Desired behaviour for both of these options: Always restore - Killed by OS: restore tabs - Killed by a crash: restore tabs - Killed manually: restore tabs Don't restore after quitting Firefox - Killed by OS: restore tabs - Killed by a crash: restore tabs - Killed manually: do not restore tabs -- this is the only difference in behaviour for this pref ----- Lastly, we should probably back the current pref out of Aurora, so we don't end up in a place where we launch the feature with one wording and change it a single release later.
tracking-fennec: --- → ?
Target Milestone: --- → Firefox 26
Previous implementation is on the mozilla-25 train; should this target that? Setting flags appropriately.
Target Milestone: Firefox 26 → ---
(In reply to Ian Barlow (:ibarlow) from comment #0) > Lastly, we should probably back the current pref out of Aurora, so we don't > end up in a place where we launch the feature with one wording and change it > a single release later. Filed bug 905371.
(In reply to Aaron Train [:aaronmt] from comment #1) > Previous implementation is on the mozilla-25 train; should this target that? > > Setting flags appropriately. Since bug 905371 was filed, this one can be about only changing the pref to two states in Fx26 (note that this bug unfortunately can't be uplifted to Aurora due to string changes).
tracking-fennec: ? → 26+
Assignee: nobody → bnicholson
Attachment #790876 - Flags: review?(mark.finkle)
Comment on attachment 790876 [details] [diff] [review] Change session restore pref to have two states >diff --git a/mobile/android/base/GeckoApp.java b/mobile/android/base/GeckoApp.java >+ } else if (savedInstanceState != null || PreferenceManager.getDefaultSharedPreferences(this) >+ .getString(GeckoPreferences.PREFS_RESTORE_SESSION, "quit") >+ .equals("always")) { This is a bit hairy, but it is optimized so we don't call the code unless we really need to check it
Attachment #790876 - Flags: review?(mark.finkle) → review+
Off-topic: I noticed the ThreadUtils.postToBackgroundThread usage in this area could use *any* background thread, not only the DB one.
Status: NEW → RESOLVED
Closed: 11 years ago
Resolution: --- → FIXED
Target Milestone: --- → Firefox 26
Flags: in-moztrap?(fennec)
I realize the bug has been committed, but more positive wording for "Don't restore after quitting Firefox" would be "Restore after OS restart only". It would still include crashes, but wouldn't have to be explicitly stated.
Verified fixed on: Build: Firefox for Android 26.0a2 (2013-09-18) Device: Samsung Galaxy R OS: Android 2.3
Status: RESOLVED → VERIFIED
Flags: in-moztrap?(fennec) → in-moztrap+
Product: Firefox for Android → Firefox for Android Graveyard
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: