Closed Bug 755771 Opened 12 years ago Closed 12 years ago

"Back" button does not navigate back, but return to homescreen.

Categories

(Firefox for Android Graveyard :: General, defect)

ARM
Android
defect
Not set
normal

Tracking

(firefox14 verified, firefox15 verified, blocking-fennec1.0 +)

VERIFIED FIXED
Firefox 15
Tracking Status
firefox14 --- verified
firefox15 --- verified
blocking-fennec1.0 --- +

People

(Reporter: jan.manthay, Assigned: bnicholson)

Details

Attachments

(3 files)

Attached file Logfile
I see this problem already for a long time, even with Aurora 13.
This does NOT happen every time, but mostly after a longer while of browsing. And then until rebooting system, or install a new Aurora version. Clear memory and restart Aurora does NOT help.

What happens exactly:
I open Aurora and browse a few sites. After a while I push the Android "Back" button, to get to the previos page. Instead of this, the homescreen opens.

Log is attached, I often see the line:
E/GeckoTab(24632): Requested title update on empty history stack
red in Alogcat.

Sony Xperia Mini, Android 2.3.4
Latest Aurora.
Status: UNCONFIRMED → RESOLVED
Closed: 12 years ago
Resolution: --- → DUPLICATE
I do not think this is a duplicate of bug https://bugzilla.mozilla.org/show_bug.cgi?id=755757

Bug 755757 reffers only to the first page of a session, ond so is invalid.

This bug here appears in the middle of a session, where the back button normal brings you to the last page.
Status: RESOLVED → REOPENED
Ever confirmed: true
Resolution: DUPLICATE → ---
The log has this shortly before the error:

I/GeckoTabs(24632): Got message: SessionHistory:Purge

According to http://mxr.mozilla.org/mozilla-central/source/docshell/shistory/public/nsISHistoryListener.idl#111 this is triggered whenever some entries are removed from the session history; in Fennec this makes us throw out the tab's entire history. We should probably do a better job of keeping the two in sync, by using the aNumEntries parameter passed in to OnHistoryPurge and only removing that many events.
nom'ing since this if it happens frequently it will get annoying for users.
blocking-fennec1.0: --- → ?
(In reply to Kartikaya Gupta (:kats) from comment #4)
> nom'ing since this if it happens frequently it will get annoying for users.

Apparently I can't english properly. "since" <--> "this"
Jan - Did you happen to go into Settings and try "Clear History" ?

If we clear history, and you attempt to go "back", there is no history anymore and we go to the home screen (or other Tab if one is available and this tab is not "external").

Brian - Can you try to reproduce this issue?
blocking-fennec1.0: ? → +
Assignee: nobody → bnicholson
(In reply to Mark Finkle (:mfinkle) from comment #6)
> Jan - Did you happen to go into Settings and try "Clear History" ?

No.
This is right inside a normal session: I open a page, klick a few links, read, press back: = Homescreen.

But if a link opens a new tab, the "back" button closes this tab, as designed. But the next klick does not navigate to the last page, but = Homescreen.
(In reply to Mark Finkle (:mfinkle) from comment #6)
> Jan - Did you happen to go into Settings and try "Clear History" ?
> 
> If we clear history, and you attempt to go "back", there is no history
> anymore and we go to the home screen (or other Tab if one is available and
> this tab is not "external").
> 
> Brian - Can you try to reproduce this issue?

STR:

1) Go to http://people.mozilla.com/~bnicholson/test/history.html
2) Wait until page says done
3) Navigate to some page
4) Push back
This HistoryEntry stuff is ancient, and we don't use it anymore. This patch replaces it with a simple counter.
Attachment #624563 - Flags: review?(mark.finkle)
We should only clear the number of entries purged as Kats described in comment 3.
Attachment #624565 - Flags: review?(mark.finkle)
Comment on attachment 624563 [details] [diff] [review]
Part 1: remove HistoryEntry

># HG changeset patch
Always nice to remove some cruft.

>     private void updateHistoryEntry(final String uri, final String title) {

Can you rename this to: updateHistory ? There are two uses in Tab.java iirc
Attachment #624563 - Flags: review?(mark.finkle) → review+
Attachment #624565 - Flags: review?(mark.finkle) → review+
Comment on attachment 624565 [details] [diff] [review]
Part 2: send purge count

[Approval Request Comment]
Bug caused by (feature/regressing bug #): 
User impact if declined: back button will break large sessions
Testing completed (on m-c, etc.): just landed on inbound
Risk to taking this patch (and alternatives if risky): low risk
String or UUID changes made by this patch: none
Attachment #624565 - Flags: approval-mozilla-aurora?
Comment on attachment 624563 [details] [diff] [review]
Part 1: remove HistoryEntry

[Approval Request Comment]
Bug caused by (feature/regressing bug #): 
User impact if declined: back button will break large sessions
Testing completed (on m-c, etc.): just landed on inbound
Risk to taking this patch (and alternatives if risky): low risk
String or UUID changes made by this patch: none
Attachment #624563 - Flags: approval-mozilla-aurora?
http://hg.mozilla.org/mozilla-central/rev/3eb58d060ac8
http://hg.mozilla.org/mozilla-central/rev/2c3647738e81
Status: REOPENED → RESOLVED
Closed: 12 years ago12 years ago
Flags: in-testsuite-
Resolution: --- → FIXED
Attachment #624563 - Flags: approval-mozilla-aurora? → approval-mozilla-aurora+
Attachment #624565 - Flags: approval-mozilla-aurora? → approval-mozilla-aurora+
Verified fix on:
Nightly 15.0a1 (2012-05-21)
Device: HTC Desire
OS: Android 2.2.2

Tested using the steps from Comment 8. Leaving open for Aurora uplift verification.
Status: RESOLVED → VERIFIED
Verified fixed using STR from comment #8: 
Aurora 14.0a2 (2012-05-25)
Beta 14.0b3 build 2

Samsung Galaxy SII (2.3.4)
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

Creator:
Created:
Updated:
Size: