aboutsummaryrefslogtreecommitdiffstats
path: root/sway/input/cursor.c
diff options
context:
space:
mode:
authorLibravatar Ryan Dwyer <ryandwyer1@gmail.com>2018-09-24 20:54:57 +1000
committerLibravatar Ryan Dwyer <ryandwyer1@gmail.com>2018-09-27 22:51:37 +1000
commit7b138e5ef0f679c9bb0078019d7c9c63fef36273 (patch)
tree2cdbeb394889065e0606a1fcbe38c1e99e25d260 /sway/input/cursor.c
parentMerge pull request #2717 from ianyfan/tablet-config (diff)
downloadsway-7b138e5ef0f679c9bb0078019d7c9c63fef36273.tar.gz
sway-7b138e5ef0f679c9bb0078019d7c9c63fef36273.tar.zst
sway-7b138e5ef0f679c9bb0078019d7c9c63fef36273.zip
Add CSD to border modes
This replaces view.using_csd with a new border mode: B_CSD. This also removes sway_xdg_shell{_v6}_view.deco_mode and view->has_client_side_decorations as we can now get these from the border. You can use `border toggle` to cycle through the modes including CSD, or use `border csd` to set it directly. The client must support the xdg-decoration protocol, and the only client I know of that does is the example in wlroots. If the client switches from SSD to CSD without us expecting it (via the server-decoration protocol), we stash the previous border type into view.saved_border so we can restore it if the client returns to SSD. I haven't found a way to test this though.
Diffstat (limited to 'sway/input/cursor.c')
-rw-r--r--sway/input/cursor.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/sway/input/cursor.c b/sway/input/cursor.c
index aa0e07f5..eab102fd 100644
--- a/sway/input/cursor.c
+++ b/sway/input/cursor.c
@@ -175,7 +175,8 @@ static enum wlr_edges find_edge(struct sway_container *cont,
175 return WLR_EDGE_NONE; 175 return WLR_EDGE_NONE;
176 } 176 }
177 struct sway_view *view = cont->view; 177 struct sway_view *view = cont->view;
178 if (view->border == B_NONE || !view->border_thickness || view->using_csd) { 178 if (view->border == B_NONE || !view->border_thickness ||
179 view->border == B_CSD) {
179 return WLR_EDGE_NONE; 180 return WLR_EDGE_NONE;
180 } 181 }
181 182