Fix type on create cursor surface

This commit is contained in:
Alberto Fanjul 2019-01-01 19:00:38 +01:00
parent 730660e56e
commit 94b76c765e
5 changed files with 23 additions and 23 deletions

View File

@ -94,10 +94,10 @@ gitg_platform_support_http_get_finish (GAsyncResult *result,
cairo_surface_t *
gitg_platform_support_create_cursor_surface (GdkDisplay *display,
GdkCursorType cursor_type,
gint *hot_x,
gint *hot_y,
gint *width,
gint *height)
gdouble *hot_x,
gdouble *hot_y,
gdouble *width,
gdouble *height)
{
NSCursor *cursor;
NSImage *image;
@ -134,12 +134,12 @@ gitg_platform_support_create_cursor_surface (GdkDisplay *display,
if (hot_x)
{
*hot_x = (gint)(hotspot.x);
*hot_x = hotspot.x;
}
if (hot_y)
{
*hot_y = (gint)(hotspot.y);
*hot_y = hotspot.y;
}
if (width)

View File

@ -57,10 +57,10 @@ gitg_platform_support_http_get_finish (GAsyncResult *result,
cairo_surface_t *
gitg_platform_support_create_cursor_surface (GdkDisplay *display,
GdkCursorType cursor_type,
gint *hot_x,
gint *hot_y,
gint *width,
gint *height)
gdouble *hot_x,
gdouble *hot_y,
gdouble *width,
gdouble *height)
{
return NULL;
}

View File

@ -56,14 +56,14 @@ gitg_platform_support_http_get_finish (GAsyncResult *result,
cairo_surface_t *
gitg_platform_support_create_cursor_surface (GdkDisplay *display,
GdkCursorType cursor_type,
gint *hot_x,
gint *hot_y,
gint *width,
gint *height)
gdouble *hot_x,
gdouble *hot_y,
gdouble *width,
gdouble *height)
{
GdkCursor *cursor;
cairo_surface_t *surface;
gint w = 0, h = 0;
gdouble w = 0, h = 0;
cursor = gdk_cursor_new_for_display (display, cursor_type);
surface = gdk_cursor_get_surface (cursor, hot_x, hot_y);

View File

@ -36,10 +36,10 @@ GInputStream *gitg_platform_support_http_get_finish (GAsyncResult *resul
cairo_surface_t *gitg_platform_support_create_cursor_surface (GdkDisplay *display,
GdkCursorType cursor_type,
gint *hot_x,
gint *hot_y,
gint *width,
gint *height);
gdouble *hot_x,
gdouble *hot_y,
gdouble *width,
gdouble *height);
GInputStream *gitg_platform_support_new_input_stream_from_fd (gint fd,
gboolean close_fd);

View File

@ -8,10 +8,10 @@ namespace Gitg
public static Cairo.Surface create_cursor_surface(Gdk.Display? display,
Gdk.CursorType cursor_type,
out int hot_x = null,
out int hot_y = null,
out int width = null,
out int height = null);
out double hot_x = null,
out double hot_y = null,
out double width = null,
out double height = null);
public static GLib.InputStream new_input_stream_from_fd(int fd, bool close_fd);