summaryrefslogtreecommitdiffstats
path: root/cursor/wayland-cursor.c
diff options
context:
space:
mode:
authorAnder Conselvan de Oliveira <ander.conselvan.de.oliveira@intel.com>2012-05-24 16:17:47 +0300
committerKristian Høgsberg <krh@bitplanet.net>2012-05-25 23:06:15 -0400
commitf779c57be2264065d4428155bf0066e71bbf33bb (patch)
tree9c214963d9592164df5ad218b9ae3774db6a0612 /cursor/wayland-cursor.c
parentshm: use mremap on pool resize (diff)
downloadwayland-f779c57be2264065d4428155bf0066e71bbf33bb.tar
wayland-f779c57be2264065d4428155bf0066e71bbf33bb.tar.gz
wayland-f779c57be2264065d4428155bf0066e71bbf33bb.tar.bz2
wayland-f779c57be2264065d4428155bf0066e71bbf33bb.tar.lz
wayland-f779c57be2264065d4428155bf0066e71bbf33bb.tar.xz
wayland-f779c57be2264065d4428155bf0066e71bbf33bb.tar.zst
wayland-f779c57be2264065d4428155bf0066e71bbf33bb.zip
wayland-cursor: remove enum wl_cursor_type
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.
Diffstat (limited to 'cursor/wayland-cursor.c')
-rw-r--r--cursor/wayland-cursor.c21
1 files changed, 2 insertions, 19 deletions
diff --git a/cursor/wayland-cursor.c b/cursor/wayland-cursor.c
index cad725f..bfacc71 100644
--- a/cursor/wayland-cursor.c
+++ b/cursor/wayland-cursor.c
@@ -305,23 +305,6 @@ wl_cursor_theme_destroy(struct wl_cursor_theme *theme)
free(theme);
}
-/** Get the cursor for a given type from a cursor theme
- *
- * \param theme The cursor theme
- * \patam type The desired cursor type
- * \return The theme's cursor of the given type or %NULL if there is no
- * such cursor
- */
-WL_EXPORT struct wl_cursor *
-wl_cursor_theme_get_cursor(struct wl_cursor_theme *theme,
- enum wl_cursor_type type)
-{
- if (type < theme->cursor_count)
- return theme->cursors[type];
-
- return NULL;
-}
-
/** Get the cursor for a given name from a cursor theme
*
* \param theme The cursor theme
@@ -330,8 +313,8 @@ wl_cursor_theme_get_cursor(struct wl_cursor_theme *theme,
* such cursor
*/
WL_EXPORT struct wl_cursor *
-wl_cursor_theme_get_cursor_by_name(struct wl_cursor_theme *theme,
- const char *name)
+wl_cursor_theme_get_cursor(struct wl_cursor_theme *theme,
+ const char *name)
{
unsigned int i;
struct wl_cursor *cursor;