summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLibravatar Brian Ashworth <RedSoxFan@users.noreply.github.com>2018-08-02 22:18:14 -0400
committerLibravatar GitHub <noreply@github.com>2018-08-02 22:18:14 -0400
commitb16043aeebd92cca12b21fa36b99799f80bdfc31 (patch)
tree745c117217c20dc05a447c5e34db1d35fec5b62b
parentconfig.in: nag user on exit (diff)
parentMerge pull request #2325 from emersion/wlr-gamma-control (diff)
downloadsway-b16043aeebd92cca12b21fa36b99799f80bdfc31.tar.gz
sway-b16043aeebd92cca12b21fa36b99799f80bdfc31.tar.zst
sway-b16043aeebd92cca12b21fa36b99799f80bdfc31.zip
Merge branch 'master' into exit-nag
-rw-r--r--include/sway/tree/container.h4
-rw-r--r--sway/input/cursor.c2
-rw-r--r--sway/server.c2
-rw-r--r--sway/tree/container.c2
4 files changed, 8 insertions, 2 deletions
diff --git a/include/sway/tree/container.h b/include/sway/tree/container.h
index 12ff8a5a..c3942e9e 100644
--- a/include/sway/tree/container.h
+++ b/include/sway/tree/container.h
@@ -234,6 +234,10 @@ struct sway_container *container_at(struct sway_container *workspace,
234 double lx, double ly, struct wlr_surface **surface, 234 double lx, double ly, struct wlr_surface **surface,
235 double *sx, double *sy); 235 double *sx, double *sy);
236 236
237struct sway_container *container_at_view(struct sway_container *view,
238 double lx, double ly, struct wlr_surface **surface,
239 double *sx, double *sy);
240
237/** 241/**
238 * Apply the function for each descendant of the container breadth first. 242 * Apply the function for each descendant of the container breadth first.
239 */ 243 */
diff --git a/sway/input/cursor.c b/sway/input/cursor.c
index 79f6ec46..c2fc4e9e 100644
--- a/sway/input/cursor.c
+++ b/sway/input/cursor.c
@@ -99,7 +99,7 @@ static struct sway_container *container_at_coords(
99 return ws; 99 return ws;
100 } 100 }
101 if (ws->sway_workspace->fullscreen) { 101 if (ws->sway_workspace->fullscreen) {
102 return container_at(ws->sway_workspace->fullscreen, lx, ly, 102 return container_at_view(ws->sway_workspace->fullscreen, lx, ly,
103 surface, sx, sy); 103 surface, sx, sy);
104 } 104 }
105 if ((*surface = layer_surface_at(output, 105 if ((*surface = layer_surface_at(output,
diff --git a/sway/server.c b/sway/server.c
index 10ca9614..e8755360 100644
--- a/sway/server.c
+++ b/sway/server.c
@@ -9,6 +9,7 @@
9#include <wlr/types/wlr_compositor.h> 9#include <wlr/types/wlr_compositor.h>
10#include <wlr/types/wlr_export_dmabuf_v1.h> 10#include <wlr/types/wlr_export_dmabuf_v1.h>
11#include <wlr/types/wlr_gamma_control.h> 11#include <wlr/types/wlr_gamma_control.h>
12#include <wlr/types/wlr_gamma_control_v1.h>
12#include <wlr/types/wlr_idle.h> 13#include <wlr/types/wlr_idle.h>
13#include <wlr/types/wlr_layer_shell.h> 14#include <wlr/types/wlr_layer_shell.h>
14#include <wlr/types/wlr_linux_dmabuf_v1.h> 15#include <wlr/types/wlr_linux_dmabuf_v1.h>
@@ -56,6 +57,7 @@ bool server_init(struct sway_server *server) {
56 wlr_data_device_manager_create(server->wl_display); 57 wlr_data_device_manager_create(server->wl_display);
57 58
58 wlr_gamma_control_manager_create(server->wl_display); 59 wlr_gamma_control_manager_create(server->wl_display);
60 wlr_gamma_control_manager_v1_create(server->wl_display);
59 wlr_primary_selection_device_manager_create(server->wl_display); 61 wlr_primary_selection_device_manager_create(server->wl_display);
60 62
61 server->new_output.notify = handle_new_output; 63 server->new_output.notify = handle_new_output;
diff --git a/sway/tree/container.c b/sway/tree/container.c
index b980c5e9..46c54e2d 100644
--- a/sway/tree/container.c
+++ b/sway/tree/container.c
@@ -535,7 +535,7 @@ struct sway_container *container_parent(struct sway_container *container,
535 return container; 535 return container;
536} 536}
537 537
538static struct sway_container *container_at_view(struct sway_container *swayc, 538struct sway_container *container_at_view(struct sway_container *swayc,
539 double lx, double ly, 539 double lx, double ly,
540 struct wlr_surface **surface, double *sx, double *sy) { 540 struct wlr_surface **surface, double *sx, double *sy) {
541 if (!sway_assert(swayc->type == C_VIEW, "Expected a view")) { 541 if (!sway_assert(swayc->type == C_VIEW, "Expected a view")) {