* src/client/application/geary-args.vala (Args): Add a quit var and arg.
* src/client/application/geary-application.vala
(GearyApplication::local_command_line): If quit was present, send the
quit action.
* src/client/application/geary-application.vala (GearyApplication): Move
action names, entries and callbacks from GearyController to here. Add a
new mailto action that expects an argument, make compose just open a
blank composer.
* src/client/application/geary-controller.vala (GearyController): Add
::compose() and ::compose_mailto() methods to support app actions.
* src/client/application/geary-application.vala (GearyApplication): Set
the resource_base_path to comply with the expected modern app id, so
the app menu will be automatically loaded.
* ui/CMakeLists.txt: Replace app_menu.interface with gtk/menus.ui. Don't
try ot copy interface files now that there aren't any.
* gtk/menus.ui: Replaces app_menu.interface.
* src/client/application/geary-controller.vala
(GearyController::create_compose_widget_async): Load draft manager and
email entry completion model asynchronously after the UI has been made
visible.
* src/client/composer/composer-widget.vala (ComposerWidget): Rename
set_entry_completions to load_entry_completions, make loading
async. Make open_draft_manager_async and load_entry_completions public
so they can be invoked by the controller.
* src/client/composer/contact-list-store.vala (ContactListStore): Load
contacts asynchronously in smaller batches, so the UI
remains responsive.
* src/client/composer/composer-widget.vala (ComposerWidget): Closure for
conversation_viewer signal handler somehow kept a reference that wasn't
an issue if the closure didn't include the viewer instance??
* src/client/composer/composer-widget.vala (ComposerWidget): Disable
the Close and Save button when closing the draft manager, enable it and
managed its visibility when opening the manager.
* src/client/composer/composer-headerbar.vala (ComposerHeaderbar): Allow
composer access to the Save and Exit button so it can manage its
visibility.
Thanks to Jiri Cerny who also provided a similar patch.
* src/client/composer/composer-widget.vala (ComposerWidget): Simplify
code paths that lead to the draft manager being opened, so we can
ensure it is always opened when constructing a new draft.
* src/client/composer/composer-widget.vala
(ComposerWidget::add_account_emails_to_from_list): Don't use
this.account, rename param to make it obvious that is the case.
(ComposerWidget::update_from_field): Only update from addresses for new
messages, use this.account to make that obvious.
Now using these instead of the old composer's actions. This led to quite
some changes:
* Use GLib.ActionEntry instead of Gtk.ActionEntry in
composer-widget.vala
* Action names can now be specified in the UI files.
* Use templates for the ComposerHeaderBar. Remove
Pillbar as superclass, since that was no longer necessary.
* Merge ComposerToolbar into ComposerWidget.
* Since actions can now be parameterized, some methods could be
merged (e.g. font size methods).
* The menu button in the composer now automatically uses a popover.
* Some methods and classes really deserved more comments.
* necessary POTFILES.in changes
Signed-off-by: Niels De Graef <nielsdegraef@gmail.com>
* desktop/CMakeLists.txt: Translate the appdata file rather than just
installing it directly.
* desktop/geary.appdata.xml.in: Rename from 'geary.appdata.xml', make
name, summary and description translatable.
* cmake/FindIntltool.cmake: Add a CMake command for the appdata file.
* po/POTFILES.in: Include geary.appdata.xml.in.
Commit 0c31607 made it possible for Geary to send messages as both
US-ASCII and ISO-8859-1, as part of the workaround for Bug 769137.
This introduced a bug however where if a message contained 8-bit
ISO-8859-1 chars but didn't include ant UTF-8 chars, the UTF-8 message
body would be encoded as if it was ISO-8859-1, and hence the high-bit
chars would be corrupted.
The solution is to re-encode the body in whatever charset it will be sent
as, before sending it.
* src/engine/rfc822/rfc822-message.vala (Message): Break out the common
parts of generating a message body part from
Message::from_composed_email into the new ::body_data_to_part method.
Ensure that the body data is conveted into US-ASCII or ISO-8859-1
before attempting to guess what transfer encoding should be used or
setting it as the content of the new body part.
* src/engine/rfc822/rfc822-utils.vala (Geary.RFC822.Utils): Replace
get_best() with get_best_charset(), since we can't guess both charset
and transfer encoding at the same time any more. Ensure we reset the
source stream after guessing (and in get_best_encoding) so that
subsequent uses don't simply get an EOS.