gecko-dev/mobile/android/components
Jan Henning 36d681723d Bug 1337940 - Part 1 - Capture session store tab data on history listener notifications. r=ahunt
So far we've simply used DOMTitleChanged as a proxy for navigation, since it's the earliest opportunity at which we have all necessary data for a new history entry (session history itself as well as tab URL and *title*) available.

However it turns out that this is not 100 % reliable, since some pages might e.g. implement their navigation in JS using the history API, which won't necessarily trigger any DOMTitleChanged events. In those case we'd fail to update the tab's session history in the session store unless the user eventually navigated to someplace else that actually triggers a title change event again - if the browser was closed before that, we'd fail to properly restore the user's state.

To fix this, we take a similar approach as the desktop session store and collect a tab's history data again when receiving any history change notification for that tab.

Because the OnHistory... notifications are mostly cancellable, the session history hasn't been actually updated yet at the point the history listener is being called. We therefore can't synchronously call onTabLoad() from within our history change notification handler and have to schedule an async timeout instead so as to give the session history a chance to complete updating its state.

MozReview-Commit-ID: LgHer940QwT

--HG--
extra : rebase_source : f5ec320bd21dac91bf1baa162aaabae3ced911e3
2017-02-11 21:07:29 +01:00
..
build merge mozilla-inbound to mozilla-central a=merge 2016-07-22 11:58:02 +02:00
extensions Bug 1339394 - Don't serialize transparent color to transparent keyword when not necessary. r=heycam,jaws 2017-02-16 10:26:13 +11:00
AboutRedirector.js Bug 1329182 - remove trailing newURI null parameters in the rest of the tree, r=jaws. 2017-01-09 20:27:26 +01:00
AddonUpdateService.js Bug 1328680 - Convert GeckoService event to bundle event; r=sebastian 2017-01-10 23:01:27 -05:00
BlocklistPrompt.js
BrowserCLH.js Bug 1329182 - remove trailing newURI null parameters in the rest of the tree, r=jaws. 2017-01-09 20:27:26 +01:00
ColorPicker.js
ContentDispatchChooser.js Bug 1333581 - Convert IntentHelper events to bundle events; r=sebastian 2017-01-25 18:57:31 -05:00
ContentPermissionPrompt.js Bug 1334156 - script-generated patch to replace .ownerDocument.defaultView with .ownerGlobal, r=jaws. 2017-01-27 10:51:03 +01:00
DirectoryProvider.js Bug 1272439 - Make distribution.searchplugins.defaultLocale work on Fennec. r=margaret 2016-05-31 13:04:35 -05:00
FilePicker.js Backed out changeset 952f0a7824ad (bug 1335539) 2017-02-21 10:30:06 +01:00
FxAccountsPush.js Bug 1333590 - 3. Change remaining Messaging calls to EventDispatcher calls; r=sebastian 2017-02-01 17:35:44 -05:00
HelperAppDialog.js Bug 1332562 - OMA Downloads should go to the system Download directory. r=snorp 2017-02-23 12:27:43 -06:00
ImageBlockingPolicy.js Bug 1225225 - Incorrect pref type and name used ImageBlockingPolicy r=mfinkle 2015-11-16 15:37:34 -05:00
LoginManagerPrompter.js Bug 1334156 - script-generated patch to replace .ownerDocument.defaultView with .ownerGlobal, r=jaws. 2017-01-27 10:51:03 +01:00
MobileComponents.manifest Bug 1305352 - (Part 2) Implement PresentationRequestUIGlue on Fennec. r=schien,snorp 2016-08-30 18:16:31 +08:00
moz.build Bug 1305352 - (Part 2) Implement PresentationRequestUIGlue on Fennec. r=schien,snorp 2016-08-30 18:16:31 +08:00
NSSDialogService.js bug 857627 - 2/4: remove nsIX509Cert.nickname r=Cykesiopka,jcj 2016-11-18 13:12:29 -08:00
PersistentNotificationHandler.js Bug 1282222 - Make the PersistentNotificationHandler handle 'persistent-notification-close' ;r=kitcambridge 2016-06-25 23:58:03 +08:00
PresentationDevicePrompt.js Bug 1288297 - Construct PresentationRequest with multiple URLs, r=smaug 2016-09-05 01:17:00 +02:00
PresentationRequestUIGlue.js Bug 1305352 - (Part 2) Implement PresentationRequestUIGlue on Fennec. r=schien,snorp 2016-08-30 18:16:31 +08:00
PromptService.js Bug 1309049 - move embedding/ files out of that directory, r=jst,mossop 2017-01-12 13:47:27 -08:00
SessionStore.idl Bug 1148797 - Don't offer "Undo close tab" for empty tabs with no session history. r=ahunt 2017-01-30 22:40:58 +01:00
SessionStore.js Bug 1337940 - Part 1 - Capture session store tab data on history listener notifications. r=ahunt 2017-02-11 21:07:29 +01:00
SiteSpecificUserAgent.js
Snippets.js Bug 1321226 - Remove legacy generator from mobile/. r=sebastian 2016-12-15 16:54:46 +09:00
TabSource.js Bug 1329268 - 2. Convert Tabs events to bundle events; r=sebastian 2017-01-17 20:06:07 -05:00
XPIDialogService.js