Commit c83cb1b2 authored by Daniel Garcia Moreno's avatar Daniel Garcia Moreno

Merge branch 'fullscreen-button-icon' into 'master'

MediaViewer: Change full screen button icon

See merge request World/fractal!152
parents f74fbb57 5c024031
Pipeline #17994 passed with stage
in 21 minutes and 11 seconds
...@@ -276,7 +276,7 @@ ...@@ -276,7 +276,7 @@
<property name="can_focus">True</property> <property name="can_focus">True</property>
<property name="receives_default">True</property> <property name="receives_default">True</property>
<child> <child>
<object class="GtkImage"> <object class="GtkImage" id="full_screen_button_icon">
<property name="visible">True</property> <property name="visible">True</property>
<property name="can_focus">False</property> <property name="can_focus">False</property>
<property name="icon_name">view-fullscreen-symbolic</property> <property name="icon_name">view-fullscreen-symbolic</property>
......
...@@ -239,6 +239,11 @@ impl AppOp { ...@@ -239,6 +239,11 @@ impl AppOp {
media_viewer_headerbar.remove(&media_viewer_back_button); media_viewer_headerbar.remove(&media_viewer_back_button);
media_viewer_headerbar.set_show_close_button(false); media_viewer_headerbar.set_show_close_button(false);
let full_screen_button_icon = self.ui.builder
.get_object::<gtk::Image>("full_screen_button_icon")
.expect("Can't find full_screen_button_icon in ui file.");
full_screen_button_icon.set_property_icon_name(Some("view-restore-symbolic"));
headerbar_revealer.add(&media_viewer_headerbar_box); headerbar_revealer.add(&media_viewer_headerbar_box);
self.update_media_viewport(); self.update_media_viewport();
...@@ -275,6 +280,11 @@ impl AppOp { ...@@ -275,6 +280,11 @@ impl AppOp {
media_viewer_headerbar.set_child_position(&media_viewer_back_button, 0); media_viewer_headerbar.set_child_position(&media_viewer_back_button, 0);
media_viewer_headerbar.set_show_close_button(true); media_viewer_headerbar.set_show_close_button(true);
let full_screen_button_icon = self.ui.builder
.get_object::<gtk::Image>("full_screen_button_icon")
.expect("Can't find full_screen_button_icon in ui file.");
full_screen_button_icon.set_property_icon_name(Some("view-fullscreen-symbolic"));
stack_header.add_named(&media_viewer_headerbar_box, "media-viewer"); stack_header.add_named(&media_viewer_headerbar_box, "media-viewer");
stack_header.set_visible_child_name("media-viewer"); stack_header.set_visible_child_name("media-viewer");
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment