aboutsummaryrefslogtreecommitdiff
path: root/rootston
diff options
context:
space:
mode:
Diffstat (limited to 'rootston')
-rw-r--r--rootston/cursor.c16
-rw-r--r--rootston/desktop.c16
2 files changed, 16 insertions, 16 deletions
diff --git a/rootston/cursor.c b/rootston/cursor.c
index 8f6091ee..5430afe5 100644
--- a/rootston/cursor.c
+++ b/rootston/cursor.c
@@ -40,17 +40,17 @@ static void seat_view_deco_motion(struct roots_seat_view *view, double deco_sx,
sy = view->grab_sy;
}
- enum wlr_deco_part parts = view_get_deco_part(view->view, sx, sy);
+ enum roots_deco_part parts = view_get_deco_part(view->view, sx, sy);
- bool is_titlebar = (parts & WLR_DECO_PART_TITLEBAR);
+ bool is_titlebar = (parts & ROOTS_DECO_PART_TITLEBAR);
uint32_t edges = 0;
- if (parts & WLR_DECO_PART_LEFT_BORDER) {
+ if (parts & ROOTS_DECO_PART_LEFT_BORDER) {
edges |= WLR_EDGE_LEFT;
- } else if (parts & WLR_DECO_PART_RIGHT_BORDER) {
+ } else if (parts & ROOTS_DECO_PART_RIGHT_BORDER) {
edges |= WLR_EDGE_RIGHT;
- } else if (parts & WLR_DECO_PART_BOTTOM_BORDER) {
+ } else if (parts & ROOTS_DECO_PART_BOTTOM_BORDER) {
edges |= WLR_EDGE_BOTTOM;
- } else if (parts & WLR_DECO_PART_TOP_BORDER) {
+ } else if (parts & ROOTS_DECO_PART_TOP_BORDER) {
edges |= WLR_EDGE_TOP;
}
@@ -90,8 +90,8 @@ static void seat_view_deco_button(struct roots_seat_view *view, double sx,
view->has_button_grab = false;
}
- enum wlr_deco_part parts = view_get_deco_part(view->view, sx, sy);
- if (state == WLR_BUTTON_RELEASED && (parts & WLR_DECO_PART_TITLEBAR)) {
+ enum roots_deco_part parts = view_get_deco_part(view->view, sx, sy);
+ if (state == WLR_BUTTON_RELEASED && (parts & ROOTS_DECO_PART_TITLEBAR)) {
struct roots_cursor *cursor = view->seat->cursor;
wlr_xcursor_manager_set_cursor_image(cursor->xcursor_manager,
cursor->default_xcursor, cursor->cursor);
diff --git a/rootston/desktop.c b/rootston/desktop.c
index 2632eebd..5fa27db2 100644
--- a/rootston/desktop.c
+++ b/rootston/desktop.c
@@ -44,9 +44,9 @@ void view_get_deco_box(const struct roots_view *view, struct wlr_box *box) {
box->height += (view->border_width * 2 + view->titlebar_height);
}
-enum wlr_deco_part view_get_deco_part(struct roots_view *view, double sx, double sy) {
+enum roots_deco_part view_get_deco_part(struct roots_view *view, double sx, double sy) {
if (!view->decorated) {
- return WLR_DECO_PART_NONE;
+ return ROOTS_DECO_PART_NONE;
}
int sw = view->wlr_surface->current->width;
@@ -55,24 +55,24 @@ enum wlr_deco_part view_get_deco_part(struct roots_view *view, double sx, double
int titlebar_h = view->titlebar_height;
if (sx > 0 && sx < sw && sy < 0 && sy > -view->titlebar_height) {
- return WLR_DECO_PART_TITLEBAR;
+ return ROOTS_DECO_PART_TITLEBAR;
}
- enum wlr_deco_part parts = 0;
+ enum roots_deco_part parts = 0;
if (sy >= -(titlebar_h + bw) &&
sy <= sh + bw) {
if (sx < 0 && sx > -bw) {
- parts |= WLR_DECO_PART_LEFT_BORDER;
+ parts |= ROOTS_DECO_PART_LEFT_BORDER;
} else if (sx > sw && sx < sw + bw) {
- parts |= WLR_DECO_PART_RIGHT_BORDER;
+ parts |= ROOTS_DECO_PART_RIGHT_BORDER;
}
}
if (sx >= -bw && sx <= sw + bw) {
if (sy > sh && sy <= sh + bw) {
- parts |= WLR_DECO_PART_BOTTOM_BORDER;
+ parts |= ROOTS_DECO_PART_BOTTOM_BORDER;
} else if (sy >= -(titlebar_h + bw) && sy < 0) {
- parts |= WLR_DECO_PART_TOP_BORDER;
+ parts |= ROOTS_DECO_PART_TOP_BORDER;
}
}