aboutsummaryrefslogtreecommitdiff
path: root/rootston/wl_shell.c
diff options
context:
space:
mode:
Diffstat (limited to 'rootston/wl_shell.c')
-rw-r--r--rootston/wl_shell.c18
1 files changed, 17 insertions, 1 deletions
diff --git a/rootston/wl_shell.c b/rootston/wl_shell.c
index 0dcc0565..0929a999 100644
--- a/rootston/wl_shell.c
+++ b/rootston/wl_shell.c
@@ -16,5 +16,21 @@ void handle_wl_shell_surface(struct wl_listener *listener, void *data) {
struct wlr_wl_shell_surface *surface = data;
wlr_log(L_DEBUG, "new wl_shell surface");
- wlr_wl_shell_surface_ping(surface);
+ //wlr_wl_shell_surface_ping(surface);
+
+ struct roots_wl_shell_surface *roots_surface =
+ calloc(1, sizeof(struct roots_wl_shell_surface));
+ // TODO: all of the trimmings
+
+ struct roots_view *view = calloc(1, sizeof(struct roots_view));
+ view->type = ROOTS_WL_SHELL_VIEW;
+ view->x = view->y = 200;
+ view->wl_shell_surface = surface;
+ view->roots_wl_shell_surface = roots_surface;
+ //view->wlr_surface = surface->surface;
+ //view->get_input_bounds = get_input_bounds;
+ //view->activate = activate;
+ view->desktop = desktop;
+ roots_surface->view = view;
+ wl_list_insert(&desktop->views, &view->link);
}