sailfishos/sailfish-browser — pull request #242 by rainemak (2014-11-16 15:29:14+00:00)
Title: Cleanup startup sequence

DeclarativeWebPage is changed so that it triggers initial load
when the view is ready given that an initial url is given.

There is no need anymore to activate pages from QML. Instead there is
reload(force) that can be used to reload the current active tab.
Reloading from user interface in considered forceful. Switching a tab
does not cause reload if the page is already alive. Reload internally
resurrects a web page and loads of the initial url.

Initial url is resolved similarly as it was previously. The moment
when loading can be started requires that MozContext is ready,
tab model is loaded, and WebView itself reaches completed state.
WebView changes to completed once MozContext is ready, TabModel is
loaded, QML component is completed, and all initialization steps
have been done (differs from Component::onCompleted). Initialization
includes possible cleaning of the privacy related data.

Affected use cases:
- Starting browser with an url
- Starting browser with an url without tabs from the previous
browsing session
- Url starting downloading so that no tabs available or with tabs
- Cleaning privacy data from settings and browser running or
browser started after cleanup. When the browser launched after
privacy data cleanup and launched with an incoming url or
from the application grid
- Requesting a new window from html (see testwindowopen.html test)

There are still some glitches and some of them are not feasible to fix yet.