MCPcopy Create free account
hub / github.com/RavEngine/RavEngine / Android_CreateCursor

Function Android_CreateCursor

deps/SDL2/src/video/android/SDL_androidmouse.c:88–105  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

86}
87
88static SDL_Cursor *
89Android_CreateCursor(SDL_Surface * surface, int hot_x, int hot_y)
90{
91 int custom_cursor;
92 SDL_Surface *converted;
93
94 converted = SDL_ConvertSurfaceFormat(surface, SDL_PIXELFORMAT_ARGB8888, 0);
95 if (!converted) {
96 return NULL;
97 }
98 custom_cursor = Android_JNI_CreateCustomCursor(converted, hot_x, hot_y);
99 SDL_FreeSurface(converted);
100 if (!custom_cursor) {
101 SDL_Unsupported();
102 return NULL;
103 }
104 return Android_WrapCursor(custom_cursor, 0);
105}
106
107static SDL_Cursor *
108Android_CreateSystemCursor(SDL_SystemCursor id)

Callers 1

Calls 4

SDL_ConvertSurfaceFormatFunction · 0.85
SDL_FreeSurfaceFunction · 0.85
Android_WrapCursorFunction · 0.85

Tested by

no test coverage detected