summaryrefslogtreecommitdiff
path: root/gdk/directfb
diff options
context:
space:
mode:
authorAndré Draszik <gtk@andred.net>2009-09-13 14:11:49 +0100
committerJavier Jardón <jjardon@gnome.org>2010-02-07 20:12:43 +0100
commit12edc32d95ddbb40182c16f088156d322781ebe9 (patch)
tree5707f9e3a46b8dd965d37a298c55e7a4759d166b /gdk/directfb
parent7f8b96d9bc220218f95dc081ba16cba915dd7e00 (diff)
downloadgtk+-12edc32d95ddbb40182c16f088156d322781ebe9.tar.gz
gdk/directfb: cursor size is artificially limited
Cursor sizes in DirectFB can be large (4095x4095), limit to 128x128 though, because the x11 backend has this limit, too - for max. compatibility. Fixes https://bugzilla.gnome.org/show_bug.cgi?id=609201 Signed-off-by: Javier Jardón <jjardon@gnome.org>
Diffstat (limited to 'gdk/directfb')
-rw-r--r--gdk/directfb/gdkcursor-directfb.c12
1 files changed, 9 insertions, 3 deletions
diff --git a/gdk/directfb/gdkcursor-directfb.c b/gdk/directfb/gdkcursor-directfb.c
index 57433a43fb..f5d9a19801 100644
--- a/gdk/directfb/gdkcursor-directfb.c
+++ b/gdk/directfb/gdkcursor-directfb.c
@@ -490,8 +490,10 @@ gdk_cursor_get_display (GdkCursor *cursor)
}
guint
-gdk_display_get_default_cursor_size (GdkDisplay *display)
+gdk_display_get_default_cursor_size (GdkDisplay *display)
{
+ g_return_val_if_fail (GDK_IS_DISPLAY (display), 0);
+
return 16;
}
@@ -510,8 +512,12 @@ gdk_display_get_maximal_cursor_size (GdkDisplay *display,
guint *width,
guint *height)
{
- *width=gdk_display_get_default_cursor_size(display);
- *height=*width;
+ g_return_if_fail (GDK_IS_DISPLAY (display));
+
+ /* Cursor sizes in DirectFB can be large (4095x4095), but we limit this to
+ 128x128 for max compatibility with the x11 backend. */
+ *width = 128;
+ *height = 128;
}
/**