SVN_SILENT made messages (after extraction)
Ubuntu: Smtp settings

Implemented SmtpManager class to store smtp settings

SmtpSettings page.qml only shows relevant input fields for each MSA Connection method

Default ports are tested and removed knowlege of default ports in QML. A warning
is shown if ports are not the default for the connection method

REVIEW: 117588

Change OutgoingPage of the desktop settings dialog to use SmtpAccountManager

Also changing the UI to choose submission type via Method and Encryption combo box's

jkt: Changed to only use a single enum for submissions because that's,
unfortunately, a pretty big QML limitation. Having this enum embedded within a
QObject is the lesser of two evils, IMHO.

jkt: Some refactoring

jkt: Fix handling of state changes whenb toggling the checkboxes and its
interaction with the configuration backend

jkt: Fix label hiding and the default index of the encryption combobox when
switching methods
Ubuntu: MessageListPage sorting

This patch makes the Listview load dynamically and force the view
to respect the user sorting prefs on each load. Triggering a
timer while the listview is populating, this benefits in that
we only sort the view once per view instead of using rowsInserted or like,
and reduce unneeded calls to.

The user can also switch sort order from the toolbar and if changed
the user sort order preference will be respected when going between
mailbox's.

navigation-menu.svg is part of the Ubuntu-mobile-icons package
available from http://packages.ubuntu.com/trusty/all/ubuntu-mobile-icons
and is available under the CC-BY-SA 3.0. Copyright by 2004-2012,
Canonical Ltd.

REVIEW: 118181
GUI: propagate changes in text fileds when editing finishes

Thanks to Thomas Lübking for proposing this.

REVIEW: 118336
SVN_SILENT made messages (after extraction)
Make attempts to reconnect after a network error

After switching to offline mode due to a network error, the model tries to
reconnect repeatedly, with increasing timeouts.  This is done until either
trojita gets a working connecton, or reconnect attempts are aborted by choosing
network:offline in the menu.

BUG: 327651
REVIEW: 118079
Sortorder woes

- triggers the save timer on swapping direction
- preserves scroll offset on swapping direction
- scrolls to unseen/recent (ie. actually top/bottom) when entering a mailbox

REVIEW: 118229
CCBUG: 335086
Ubuntu: Bump UI toolkit version from v0.1 to v1.1 target Ubuntu14.10

This is to enable the app to be installed on devices which are
running Ubuntu 14.10 and above

REVIEW: 118383
Ubuntu: Implements PasswordWatcher for imap access

Now uses the passwordWatcher. When authRequest signal is
received it either auto connects or if no password saved ask
user to enter password.

REVIEW: 118130
BUG: 333965
BUG: 332987

Removed using an anonymous function to call a reloadPassword slot
Ubuntu: improve OneMessagePage and the displaying of messages

Created TrojitaWebView component, with the webviews flickable disabled.
Delegating flickable behaviour to the page flickable.

Also i have created a new header component which expands and collapses showing
all envelope details. The email addresses are formatted and clickable
emitting an emailAddressClicked signal

dropdown-menu.svg is part of the Ubuntu-mobile-icons package
available from http://packages.ubuntu.com/trusty/all/ubuntu-mobile-icons
and is available under the CC-BY-SA 3.0. Copyright by 2004-2012,
Canonical Ltd.

REVIEW: 118355
Ubuntu: Add licence header to HeaderComponent.qml

REVIEW: 118430
BUG: 335597
Do not call that function when setting up signals & slots

CCMAIL: dpniel@ubuntu.com
Reset auto-reconnect cycle when user explicitly changes network preference

Previously, a network error message box would be deleted and reinitialised
only when Trojita got a working connection to the server after a cycle
of reconnect attempts.

Now, whenever the user changes the network preferences, the
Imap::Model::NetworkWatcher apart from resetting the timeouts also emits a
signal that triggers deletion and reinitialisation of the error message
box at the GUI layer. This allows Trojita to treat a user's manual attempt
to re-connect as a new try-fail-reconnect cycle and throws a message pop-
up on a network error (even if the error string hasn't changed since last
time).

Use-Case: Error in network; Trojita shows an error message and starts a
series of auto reconnect attempts. User wishes to stop the attempts and
chooses "Offline" from the Network Access menu item. Attempts stop. After
a while, user wishes to try connecting again and chooses "Free Access".
If attempt to connect terminates in a network error, Trojita throws a
fresh new error message and starts a new auto-reconnect cycle (even if the
error string is the same as what it before the explicit switch to "offline").

REVIEW: 118434
ClearTextPassword plugin: report error on empty password

The password is empty when it's not set in the settings file.
Settings: Hide unwanted elements on the OutgoingPage

As the page is disabled before it is saved we can not use isEnabled() to determine
whether to save the SMTP password or not. isVisible works fine though and the GUI
looks cleaner that way.

REVIEW: 118509
GUI: Prevent a blank line in the Outgoing settings page

It's better to sync the port warning state with whatever is initially in the
settings.

REVIEW: 118523
Gui: Only set default port when changing submission method

Setting the default port during the initial run of the SettingsDialog is already handled
by MSA::Account and setting it during updateWidgets causes the port to be reset when opening
the SettingsDialog.

Signed-off-by: Jan Kundrát <jkt@flaska.net>

Conflicts:
	src/Gui/SettingsDialog.cpp

REVIEW: 118528
Tests: move test bodystructures to a common header file

This is done so that we can use the bodystructures in other tests too
Tests: Added unit tests for Imap::Network::MsgPartNetAccessManager
Do not use TreeItems in PartWidgetFactory

The TreeItem class is an implementation detail of the ImapModel and should not
be used outside the ImapModel.

REVIEW: 118228