aboutsummaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorDrew DeVault <sir@cmpwn.com>2017-09-23 17:48:13 -0400
committerDrew DeVault <sir@cmpwn.com>2017-09-23 17:48:13 -0400
commiteaf6c0ccf4a8fc78580a49335adb1783dbebd9af (patch)
treeb3cdde49226ab2cda6da66f40bb58dd42d9be9ea /include
parent5b92d4fecfbbf5da8cac442b598758c119afd8f9 (diff)
Implement pointer motion and buttons
Diffstat (limited to 'include')
-rw-r--r--include/rootston/desktop.h2
-rw-r--r--include/rootston/view.h12
2 files changed, 13 insertions, 1 deletions
diff --git a/include/rootston/desktop.h b/include/rootston/desktop.h
index 8fb55219..62050972 100644
--- a/include/rootston/desktop.h
+++ b/include/rootston/desktop.h
@@ -48,6 +48,8 @@ struct roots_desktop *desktop_create(struct roots_server *server,
void desktop_destroy(struct roots_desktop *desktop);
void view_destroy(struct roots_view *view);
+struct roots_view *view_at(struct roots_desktop *desktop, int x, int y);
+void view_activate(struct roots_view *view, bool activate);
void output_add_notify(struct wl_listener *listener, void *data);
void output_remove_notify(struct wl_listener *listener, void *data);
diff --git a/include/rootston/view.h b/include/rootston/view.h
index 9535094b..9e7c4a01 100644
--- a/include/rootston/view.h
+++ b/include/rootston/view.h
@@ -1,8 +1,9 @@
#ifndef _ROOTSTON_VIEW_H
#define _ROOTSTON_VIEW_H
#include <stdbool.h>
-#include <wlr/types/wlr_xdg_shell_v6.h>
+#include <wlr/types/wlr_box.h>
#include <wlr/types/wlr_surface.h>
+#include <wlr/types/wlr_xdg_shell_v6.h>
struct roots_wl_shell_surface {
// TODO
@@ -41,6 +42,15 @@ struct roots_view {
};
struct wlr_surface *wlr_surface;
struct wl_list link;
+ // TODO: This would probably be better as a field that's updated on a
+ // configure event from the xdg_shell
+ // If not then this should follow the typical type/impl pattern we use
+ // elsewhere
+ void (*get_input_bounds)(struct roots_view *view, struct wlr_box *box);
+ void (*activate)(struct roots_view *view, bool active);
};
+void view_get_input_bounds(struct roots_view *view, struct wlr_box *box);
+void view_activate(struct roots_view *view, bool active);
+
#endif