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
Gui: hide portWarning, passwordWarning and passwordPluginStatus when not using smtp

REVIEW: 118531
Ubuntu:Add Click pkg manifests and change cmake to build click pkgs

Adds a new option UBUNTU_CLICK_MODE for use when either running
trojita on device from QtCreator or building click packages.
This option installs trojita to a contained location

REVIEW: 118429
Ubuntu: modify TrojitaVersion to configure version in manifest.json

Adds an UBUNTU_CLICK_MODE option to TrojitaVersion.cmake which if true
will configure manifest.json on each build

REVIEW: 118429
Ubuntu: Remove QCommandLineParser options from src/Ubuntu/main.cpp

For some reason UbuntuTouch/Unity8 require --desktop_file_hint
and --stage_hint to be passed when launching an app. Which
the commandline parser was blocking these args. Since the
commandline options were only really just setting the size of
the qquickview we can safely just remove it and stick to a fixed
size window.

Removed associated context properties from main.qml

REVIEW: 118429
Ubuntu: Modify main.cpp to find main.qml in click package

With click packages the qml dir does not fall under a 'standard'
location. So it first looks for trojita.json in the root of the click
package, once that's found we can then descend to main.qml from
there.

REVIEW: 118429
Fix the Python3 code

In Python3, there's no "print" statement anymore.
Fix building with QT_NO_CAST_FROM/TO_ASCII in trojita-ubu
build: Well, there are no known warnings anymore

...and there have been none for a long time already.
MSA: Do not check default port numbers for non-network submission methods

BUG: 336119
Ubuntu indicate progress on MessageListPage

- Show task on the bottom
- Message delegate show loading and unavailable

REVIEW: 118513
BUG: 333039