Merge lp:~philip.scott/audience/broken-window-fix into lp:~audience-members/audience/trunk

Proposed by Felipe Escoto
Status: Merged
Approved by: Danielle Foré
Approved revision: 621
Merged at revision: 625
Proposed branch: lp:~philip.scott/audience/broken-window-fix
Merge into: lp:~audience-members/audience/trunk
Diff against target: 51 lines (+18/-16)
1 file modified
src/Window.vala (+18/-16)
To merge this branch: bzr merge lp:~philip.scott/audience/broken-window-fix
Reviewer Review Type Date Requested Status
Audience Members Pending
Review via email: mp+302324@code.launchpad.net

Commit message

Don't go to fullscreen when maximized to prevent gala bug

Description of the change

Workaround to gala's bug

To post a comment you must log in.

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'src/Window.vala'
2--- src/Window.vala 2016-07-30 17:06:42 +0000
3+++ src/Window.vala 2016-08-08 17:58:47 +0000
4@@ -93,6 +93,24 @@
5 }
6 return false;
7 });
8+
9+ window_state_event.connect ((e) => {
10+ if (Gdk.WindowState.FULLSCREEN in e.changed_mask) {
11+ player_page.fullscreened = Gdk.WindowState.FULLSCREEN in e.new_window_state;
12+ header.visible = !player_page.fullscreened;
13+ }
14+
15+ /*/ FIXME: Remove comments once gala bug is fixed: https://bugs.launchpad.net/gala/+bug/1602722
16+ if (Gdk.WindowState.MAXIMIZED in e.changed_mask) {
17+ bool currently_maximixed = Gdk.WindowState.MAXIMIZED in e.new_window_state;
18+
19+ if (main_stack.get_visible_child () == player_page && currently_maximixed) {
20+ fullscreen ();
21+ }
22+ }*/
23+
24+ return false;
25+ });
26 }
27
28 /** Returns true if the code parameter matches the keycode of the keyval parameter for
29@@ -203,22 +221,6 @@
30 return false;
31 }
32
33- public override bool window_state_event (Gdk.EventWindowState e) {
34- if (Gdk.WindowState.FULLSCREEN in e.changed_mask) {
35- player_page.fullscreened = Gdk.WindowState.FULLSCREEN in e.new_window_state;
36- header.visible = !player_page.fullscreened;
37- }
38-
39- if (Gdk.WindowState.MAXIMIZED in e.changed_mask) {
40- bool currently_maximixed = Gdk.WindowState.MAXIMIZED in e.new_window_state;
41- if (main_stack.get_visible_child () == player_page && currently_maximixed) {
42- fullscreen ();
43- }
44- }
45-
46- return false;
47- }
48-
49 public void open_files (File[] files, bool clear_playlist = false, bool force_play = true) {
50 if (clear_playlist) {
51 player_page.get_playlist_widget ().clear_items ();

Subscribers

People subscribed via source and target branches