Merge lp:~alan-griffiths/miral/fix-1632325 into lp:miral

Proposed by Alan Griffiths
Status: Merged
Approved by: Brandon Schaefer
Approved revision: 404
Merged at revision: 404
Proposed branch: lp:~alan-griffiths/miral/fix-1632325
Merge into: lp:miral
Diff against target: 20 lines (+10/-0)
1 file modified
miral/window_specification.cpp (+10/-0)
To merge this branch: bzr merge lp:~alan-griffiths/miral/fix-1632325
Reviewer Review Type Date Requested Status
Brandon Schaefer (community) Approve
Gerry Boland (community) Approve
Review via email: mp+308127@code.launchpad.net

Commit message

Prior to Mir-0.25 mir_connection_create_spec_for_tooltip() doesn't set an edge attachment preference. So give it one.

To post a comment you must log in.
Revision history for this message
Gerry Boland (gerboland) wrote :

LGTM

review: Approve
Revision history for this message
Brandon Schaefer (brandontschaefer) wrote :

lgtm

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'miral/window_specification.cpp'
2--- miral/window_specification.cpp 2016-09-30 16:29:43 +0000
3+++ miral/window_specification.cpp 2016-10-11 14:18:52 +0000
4@@ -250,6 +250,16 @@
5 aux_rect_placement_offset = Displacement{params.aux_rect_placement_offset_x.value(), params.aux_rect_placement_offset_y.value()};
6 #endif
7
8+#if MIR_SERVER_VERSION < MIR_VERSION_NUMBER(0, 25, 0)
9+ // mir_connection_create_spec_for_tooltip() didn't set an edge_attachment preference
10+ if (aux_rect.is_set() && !params.edge_attachment.is_set())
11+ {
12+ window_placement_gravity = mir_placement_gravity_northwest;
13+ aux_rect_placement_gravity = mir_placement_gravity_northeast;
14+ placement_hints = mir_placement_hints_flip_any;
15+ }
16+#endif
17+
18 if (params.edge_attachment.is_set() && !placement_hints.is_set())
19 {
20 switch (params.edge_attachment.value())

Subscribers

People subscribed via source and target branches