summaryrefslogtreecommitdiffstats
path: root/cursor/wayland-cursor.c
Commit message (Collapse)AuthorAgeFilesLines
* Move ARRAY_LENGTH out of public headersKristian Høgsberg2012-10-191-0/+2
| | | | | | | | Exporting unprefixed symbols is a pretty bad idea so don't do that. Instea of redefining it WL_ARRAY_LENGTH, we just move the define to our private header. The scanner generates code that uses ARRAY_LENGTH, but we can just make it count the number elements and emit an integer constant instead.
* Ensure cursor_data.c is included in distribution tarballsMatt Roper2012-10-091-1/+1
| | | | Signed-off-by: Matt Roper <matthew.d.roper@intel.com>
* cursor: Add a default cursor themePhilipp Brüschweiler2012-09-101-1/+70
| | | | | | | This theme is loaded when the specified cursor theme can not be found. These cursors are extracted from the xorg sources and transformed into raw ARGB data by a small helper program (commited separately).
* cursor: fix fd leak and a segfaultPekka Paalanen2012-07-101-0/+6
| | | | | | | | | - don't leak fd in shm_pool_destroy() - return NULL from wl_cursor_theme_load() if pool fails Tha last one fixes a segfault, when shm_pool_create() has failed. Signed-off-by: Pekka Paalanen <ppaalanen@gmail.com>
* cursor: use os_create_anonymous_file()Pekka Paalanen2012-07-101-6/+3
| | | | | | | Copy the implementation of os_create_anonymous_file() here from weston, so we can use it instead of hardcoding a path to /tmp. Signed-off-by: Pekka Paalanen <ppaalanen@gmail.com>
* wayland-cursor: Add error handling for shm_pool_create()Martin Olsson2012-07-091-9/+11
|
* cursor: Add function for calculating current frame in cursor animationAnder Conselvan de Oliveira2012-06-151-7/+42
| | | | | | Given a pointer to struct wl_cursor and an elapsed time in ms., wl_cursor_frame() will return the index of the cursor image the should be displayed.
* wayland-cursor: load all cursors from a theme on wl_cursor_theme_loadAnder Conselvan de Oliveira2012-05-251-53/+34
|
* wayland-cursor: remove enum wl_cursor_typeAnder Conselvan de Oliveira2012-05-251-19/+2
| | | | | | | Defining a list of all cursors a theme, client or toolkit should have is not the purpose of libwayland-cursor. The cursor type enum existed for making lookups faster, but this kind of optmization belongs in the toolkits.
* Introduce libwayland-cursor, a cursor helper libraryAnder Conselvan de Oliveira2012-05-221-0/+356
The purpose of this library is to be the equivalent of libXcursor in the X world. This library is compatible with X cursor themes and loads them directly into an shm pool making it easy for the clients to get buffer for each cursor image. The code for handling the X cursor theme was taken from libXcursor. The files cursor/xcursor.[ch] are a stripped down version of that library containing only the interfaces necessary for implementing the wayland counterpart.