client: Convert to using HdySqueezer for managing main toolbar actions
This commit is contained in:
parent
0aa8ad6a05
commit
9e641600c3
3 changed files with 21 additions and 6 deletions
|
|
@ -1527,7 +1527,8 @@ public class Application.MainWindow :
|
||||||
this.conversation_list_view.select_conversations(to_select);
|
this.conversation_list_view.select_conversations(to_select);
|
||||||
|
|
||||||
this.conversation_list_actions.selected_conversations = to_select.size;
|
this.conversation_list_actions.selected_conversations = to_select.size;
|
||||||
this.main_toolbar.conversation_actions.selected_conversations = to_select.size;
|
this.main_toolbar.full_actions.selected_conversations = to_select.size;
|
||||||
|
this.main_toolbar.compact_actions.selected_conversations = to_select.size;
|
||||||
|
|
||||||
if (this.selected_folder != null && !this.has_composer) {
|
if (this.selected_folder != null && !this.has_composer) {
|
||||||
switch(to_select.size) {
|
switch(to_select.size) {
|
||||||
|
|
@ -1780,7 +1781,8 @@ public class Application.MainWindow :
|
||||||
this.selected_folder_supports_trash
|
this.selected_folder_supports_trash
|
||||||
);
|
);
|
||||||
this.conversation_list_actions.update_trash_button(show_trash);
|
this.conversation_list_actions.update_trash_button(show_trash);
|
||||||
this.main_toolbar.conversation_actions.update_trash_button(show_trash);
|
this.main_toolbar.full_actions.update_trash_button(show_trash);
|
||||||
|
this.main_toolbar.compact_actions.update_trash_button(show_trash);
|
||||||
}
|
}
|
||||||
|
|
||||||
private async void update_context_dependent_actions(bool sensitive) {
|
private async void update_context_dependent_actions(bool sensitive) {
|
||||||
|
|
|
||||||
|
|
@ -25,7 +25,8 @@ public class Components.MainToolbar : Hdy.Leaflet {
|
||||||
|
|
||||||
public bool find_open { get; set; default = false; }
|
public bool find_open { get; set; default = false; }
|
||||||
|
|
||||||
[GtkChild] public unowned ConversationActions conversation_actions;
|
[GtkChild] public unowned ConversationActions full_actions;
|
||||||
|
[GtkChild] public unowned ConversationActions compact_actions;
|
||||||
|
|
||||||
[GtkChild] private unowned Hdy.Leaflet conversations_leaflet;
|
[GtkChild] private unowned Hdy.Leaflet conversations_leaflet;
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -168,10 +168,22 @@
|
||||||
</object>
|
</object>
|
||||||
</child>
|
</child>
|
||||||
<child>
|
<child>
|
||||||
<object class="ComponentsConversationActions" id="conversation_actions">
|
<object class="HdySqueezer">
|
||||||
<property name="visible">True</property>
|
<property name="visible">True</property>
|
||||||
<property name="show_conversation_actions">True</property>
|
<child>
|
||||||
<property name="show_response_actions">True</property>
|
<object class="ComponentsConversationActions" id="full_actions">
|
||||||
|
<property name="visible">True</property>
|
||||||
|
<property name="show_conversation_actions">True</property>
|
||||||
|
<property name="show_response_actions">True</property>
|
||||||
|
</object>
|
||||||
|
</child>
|
||||||
|
<child>
|
||||||
|
<object class="ComponentsConversationActions" id="compact_actions">
|
||||||
|
<property name="visible">True</property>
|
||||||
|
<property name="show_conversation_actions">True</property>
|
||||||
|
<property name="show_response_actions">False</property>
|
||||||
|
</object>
|
||||||
|
</child>
|
||||||
</object>
|
</object>
|
||||||
</child>
|
</child>
|
||||||
<child>
|
<child>
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue