* src/client/conversation-viewer/conversation-message.vala (ConversationMessage): Add a simple action group namespaced as "msg" for actions under the message's scope, add actions to it for the context menu. Track the currently selected DOM element under the context menu so we can update action enabled state, etc., based on it. Construct the context menu as needed, update signal & event handlers as needed. * src/client/conversation-viewer/conversation-email.vala (ConversationEmail): Add new save-image signal, chain emission from added ConversationMessage instance's save-image signal to this. * src/client/application/geary-controller.vala (GearyController): Chase on_save_buffer_to_file signal moving to ConversationEmail and being renamed to save_image. * src/client/conversation-viewer/conversation-viewer.vala: Remove uneeded signal. * ui/conversation-message-menus.ui: New UI file for ConversationMessage context menu. * ui/CMakeLists.txt: Incude ConversationMessage UI in the resources. * po/POTFILES.in: Add new UI file.
48 lines
1.7 KiB
XML
48 lines
1.7 KiB
XML
<?xml version="1.0" encoding="UTF-8"?>
|
|
|
|
<interface>
|
|
<menu id="context_menu">
|
|
<section id="context_menu_link">
|
|
<item>
|
|
<attribute name="label" translatable="yes">_Open Link</attribute>
|
|
<attribute name="action">msg.open_link</attribute>
|
|
</item>
|
|
<item>
|
|
<attribute name="label" translatable="yes">Copy Link _Address</attribute>
|
|
<attribute name="action">msg.copy_link</attribute>
|
|
</item>
|
|
</section>
|
|
<section id="context_menu_email">
|
|
<item>
|
|
<attribute name="label" translatable="yes">Send New _Message...</attribute>
|
|
<attribute name="action">msg.open_link</attribute>
|
|
</item>
|
|
<item>
|
|
<attribute name="label" translatable="yes">Copy Email _Address</attribute>
|
|
<attribute name="action">msg.copy_email</attribute>
|
|
</item>
|
|
</section>
|
|
<section id="context_menu_image">
|
|
<item>
|
|
<attribute name="label" translatable="yes">Save _Image As...</attribute>
|
|
<attribute name="action">msg.save_image</attribute>
|
|
</item>
|
|
</section>
|
|
<section id="context_menu_main">
|
|
<item>
|
|
<attribute name="label" translatable="yes">_Select All</attribute>
|
|
<attribute name="action">msg.select_all</attribute>
|
|
</item>
|
|
<item>
|
|
<attribute name="label" translatable="yes">_Copy</attribute>
|
|
<attribute name="action">msg.copy_selection</attribute>
|
|
</item>
|
|
</section>
|
|
<section id="context_menu_inspector">
|
|
<item>
|
|
<attribute name="label" translatable="yes">_Inspect...</attribute>
|
|
<attribute name="action">msg.open_inspector</attribute>
|
|
</item>
|
|
</section>
|
|
</menu>
|
|
</interface>
|