Don't rely ComposerState::state notify and property bindings firing when the value hasn't actually changed to update the composer's UI. This is works around Vala Bug 631267 landing. * src/client/composer/composer-headerbar.vala (ComposerHeaderbar): Add signal and methods to be called explicity on state changes, rather than relying on being notified of ComposerWidget::state changing. * src/client/composer/composer-widget.vala (ComposerWidget): Hook up new ComposerHeaderbar signal and method. Remove notify and property bindings on ::state property, move related code to new ::update_composer_view method and call that as needed. Remove overridden ::show_all, because the UI state should now always be consistent with ::state. Clean up various methods. * src/client/composer/email-entry.vala (EmailEntry::EmailEntry): Make widget visible by default, since we are no longer calling ComposerWidget::show_all(). * src/client/application/geary-controller.vala: Don't call show all on new composers, they now manage their visibility properly. * ui/composer-headerbar.ui: Make toolbar icons visible by default. * ui/composer-widget.ui: Make toolbar icons visible by default, set Send button icon here rather than in the class.
219 lines
9.3 KiB
XML
219 lines
9.3 KiB
XML
<?xml version="1.0" encoding="UTF-8"?>
|
|
<interface>
|
|
<requires lib="gtk+" version="3.14"/>
|
|
<object class="GtkImage" id="send_image">
|
|
<property name="visible">True</property>
|
|
<property name="can_focus">False</property>
|
|
<property name="icon_name">mail-send-symbolic</property>
|
|
</object>
|
|
<template class="ComposerHeaderbar" parent="GtkHeaderBar">
|
|
<property name="visible">True</property>
|
|
<property name="can_focus">False</property>
|
|
<property name="show_close_button">False</property>
|
|
<child>
|
|
<object class="GtkBox" id="detach_start">
|
|
<property name="visible">True</property>
|
|
<property name="can_focus">False</property>
|
|
<child>
|
|
<object class="GtkButton" id="detach_start_button">
|
|
<property name="visible">True</property>
|
|
<property name="can_focus">True</property>
|
|
<property name="focus_on_click">False</property>
|
|
<property name="margin_end">6</property>
|
|
<property name="relief">GTK_RELIEF_NONE</property>
|
|
<property name="action_name">cmh.detach</property>
|
|
<property name="always_show_image">True</property>
|
|
<property name="tooltip_text" translatable="yes">Detach (Ctrl+D)</property>
|
|
<child>
|
|
<object class="GtkImage" id="detach_start_image">
|
|
<property name="icon_name">detach-symbolic</property>
|
|
<property name="pixel-size">16</property>
|
|
</object>
|
|
</child>
|
|
</object>
|
|
</child>
|
|
<child>
|
|
<object class="GtkSeparator" id="detach_start_separator">
|
|
<property name="visible">True</property>
|
|
<property name="can_focus">False</property>
|
|
<property name="orientation">vertical</property>
|
|
</object>
|
|
</child>
|
|
</object>
|
|
</child>
|
|
<child>
|
|
<object class="GtkButton" id="new_message_attach_button">
|
|
<property name="visible">True</property>
|
|
<property name="can_focus">True</property>
|
|
<property name="focus_on_click">False</property>
|
|
<property name="action_name">cmh.add-attachment</property>
|
|
<property name="always_show_image">True</property>
|
|
<property name="tooltip_text" translatable="yes">Attach File (Ctrl+T)</property>
|
|
<child>
|
|
<object class="GtkImage" id="new_message_attach_image">
|
|
<property name="visible">True</property>
|
|
<property name="icon_name">mail-attachment-symbolic</property>
|
|
<property name="pixel-size">16</property>
|
|
</object>
|
|
</child>
|
|
</object>
|
|
</child>
|
|
<child>
|
|
<object class="GtkBox" id="conversation_attach_buttons">
|
|
<property name="visible">True</property>
|
|
<property name="can_focus">False</property>
|
|
<style>
|
|
<class name="linked"/>
|
|
</style>
|
|
<child>
|
|
<object class="GtkButton" id="conversation_attach_new_button">
|
|
<property name="visible">True</property>
|
|
<property name="can_focus">True</property>
|
|
<property name="focus_on_click">False</property>
|
|
<property name="action_name">cmh.add-attachment</property>
|
|
<property name="always_show_image">True</property>
|
|
<property name="tooltip_text" translatable="yes">Attach File (Ctrl+T)</property>
|
|
<child>
|
|
<object class="GtkImage" id="conversation_attach_new_image">
|
|
<property name="visible">True</property>
|
|
<property name="icon_name">mail-attachment-symbolic</property>
|
|
<property name="pixel-size">16</property>
|
|
</object>
|
|
</child>
|
|
</object>
|
|
</child>
|
|
<child>
|
|
<object class="GtkButton" id="conversation_attach_original_button">
|
|
<property name="visible">True</property>
|
|
<property name="can_focus">True</property>
|
|
<property name="focus_on_click">False</property>
|
|
<property name="action_name">cmh.add-original-attachments</property>
|
|
<property name="always_show_image">True</property>
|
|
<property name="tooltip_text" translatable="yes">Include Original Attachments</property>
|
|
<child>
|
|
<object class="GtkImage" id="conversation_attach_original_image">
|
|
<property name="visible">True</property>
|
|
<property name="icon_name">edit-copy-symbolic</property>
|
|
<property name="pixel-size">16</property>
|
|
</object>
|
|
</child>
|
|
</object>
|
|
</child>
|
|
</object>
|
|
</child>
|
|
<child>
|
|
<object class="GtkButton" id="recipients_button">
|
|
<property name="visible">True</property>
|
|
<property name="can_focus">True</property>
|
|
<property name="relief">GTK_RELIEF_NONE</property>
|
|
<property name="focus_on_click">False</property>
|
|
<child>
|
|
<object class="GtkLabel" id="recipients_label">
|
|
<property name="visible">True</property>
|
|
<property name="ellipsize">end</property>
|
|
</object>
|
|
</child>
|
|
</object>
|
|
</child>
|
|
<child>
|
|
<object class="GtkBox" id="detach_end">
|
|
<property name="visible">True</property>
|
|
<property name="can_focus">False</property>
|
|
<child>
|
|
<object class="GtkSeparator" id="detach_end_separator">
|
|
<property name="visible">True</property>
|
|
<property name="can_focus">False</property>
|
|
<property name="orientation">vertical</property>
|
|
</object>
|
|
</child>
|
|
<child>
|
|
<object class="GtkButton" id="detach_end_button">
|
|
<property name="visible">True</property>
|
|
<property name="can_focus">True</property>
|
|
<property name="focus_on_click">False</property>
|
|
<property name="margin_start">6</property>
|
|
<property name="relief">GTK_RELIEF_NONE</property>
|
|
<property name="action_name">cmh.detach</property>
|
|
<property name="always_show_image">True</property>
|
|
<property name="tooltip_text" translatable="yes">Detach (Ctrl+D)</property>
|
|
<child>
|
|
<object class="GtkImage" id="detach_end_image">
|
|
<property name="visible">True</property>
|
|
<property name="icon_name">detach-symbolic</property>
|
|
<property name="pixel-size">16</property>
|
|
</object>
|
|
</child>
|
|
</object>
|
|
</child>
|
|
</object>
|
|
<packing>
|
|
<property name="pack_type">end</property>
|
|
</packing>
|
|
</child>
|
|
<child>
|
|
<object class="GtkButton" id="send_button">
|
|
<property name="visible">True</property>
|
|
<property name="can_focus">True</property>
|
|
<property name="focus_on_click">False</property>
|
|
<property name="action_name">cmh.send</property>
|
|
<property name="always_show_image">True</property>
|
|
<property name="image">send_image</property>
|
|
<property name="use_underline">True</property>
|
|
<property name="tooltip_text" translatable="yes">Send (Ctrl+Enter)</property>
|
|
<property name="label" translatable="yes">_Send</property>
|
|
<style>
|
|
<class name="suggested-action"/>
|
|
</style>
|
|
</object>
|
|
<packing>
|
|
<property name="pack_type">end</property>
|
|
</packing>
|
|
</child>
|
|
<child>
|
|
<object class="GtkBox" id="close_buttons">
|
|
<property name="visible">True</property>
|
|
<property name="can_focus">False</property>
|
|
<style>
|
|
<class name="linked"/>
|
|
</style>
|
|
<child>
|
|
<object class="GtkButton" id="discard_and_close_button">
|
|
<property name="visible">True</property>
|
|
<property name="can_focus">True</property>
|
|
<property name="focus_on_click">False</property>
|
|
<property name="action_name">cmh.close-and-discard</property>
|
|
<property name="always_show_image">True</property>
|
|
<property name="tooltip_text" translatable="yes">Discard and Close</property>
|
|
<child>
|
|
<object class="GtkImage" id="discard_and_close_image">
|
|
<property name="visible">True</property>
|
|
<property name="icon_name">user-trash-symbolic</property>
|
|
<property name="pixel-size">16</property>
|
|
</object>
|
|
</child>
|
|
</object>
|
|
</child>
|
|
<child>
|
|
<object class="GtkButton" id="save_and_close_button">
|
|
<property name="visible">True</property>
|
|
<property name="can_focus">True</property>
|
|
<property name="focus_on_click">False</property>
|
|
<property name="action_name">cmh.close-and-save</property>
|
|
<property name="always_show_image">True</property>
|
|
<property name="tooltip_text" translatable="yes">Save and Close</property>
|
|
<child>
|
|
<object class="GtkImage" id="save_and_close_image">
|
|
<property name="visible">True</property>
|
|
<property name="icon_name">document-save-symbolic</property>
|
|
<property name="pixel-size">16</property>
|
|
</object>
|
|
</child>
|
|
</object>
|
|
</child>
|
|
</object>
|
|
<packing>
|
|
<property name="pack_type">end</property>
|
|
</packing>
|
|
</child>
|
|
</template>
|
|
</interface>
|