2
* @file geis_grail_window_grab.h
3
* @brief window grab handling for the GEIS grail back end
6
* Copyright 2011 Canonical Ltd.
8
* This library is free software: you can redistribute it and/or modify it
9
* under the terms of the GNU Lesser General Public License version 3
10
* as published by the Free Software Foundation.
12
* This library is distributed in the hope that it will be useful, but
13
* WITHOUT ANY WARRANTY; without even the implied warranties of
14
* MERCHANTABILITY, SATISFACTORY QUALITY, or FITNESS FOR A PARTICULAR
15
* PURPOSE. See the GNU Lesser General Public License for more details.
17
* You should have received a copy of the GNU Lesser General Public License
18
* along with this library. If not, see <http://www.gnu.org/licenses/>.
20
#ifndef GEIS_BACKEND_GRAIL_WINDOW_GRAB_H_
21
#define GEIS_BACKEND_GRAIL_WINDOW_GRAB_H_
23
#include "geis/geis.h"
28
* The opaque Grail Window Grab Store.
30
* A "window grab" in this context refers to a passive grab of all multi-touch
31
* input on a specified window. There should be only a single grab of a window
32
* with the X server, but it's possible for multiple GEIS subscriptions to exist
33
* for the same region (window), so they need to multiplexed and refcounted
34
* through a subscription-independent means.
38
typedef struct GeisGrailWindowGrabStore *GeisGrailWindowGrabStore;
41
* Constructs a new window grab store.
43
GeisGrailWindowGrabStore
44
geis_grail_window_grab_store_new(Display *display);
47
* Destroys a window grab store.
49
* @param store A window grab store.
52
geis_grail_window_grab_store_delete(GeisGrailWindowGrabStore store);
55
* Grabs a window through a window grab store.
57
* @param store A window grab store.
58
* @param window The window to grab.
60
* @returns GEIS_STATUS_SUCCESS if the multi-touch for the window was grabbed
61
* successfully, GEIS_STATUS_UNKNOWN_ERROR otherwise.
64
geis_grail_window_grab_store_grab(GeisGrailWindowGrabStore store,
68
* Ungrabs a window through a window grab store.
70
* @param store A window grab store.
71
* @param window The window to ungrab.
74
geis_grail_window_grab_store_ungrab(GeisGrailWindowGrabStore store,
77
#endif /* GEIS_BACKEND_GRAIL_WINDOW_GRAB_H_ */