File: pgcompat.c

package info (click to toggle)
pygame 2.1.2%2Bdfsg-5
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 32,416 kB
  • sloc: ansic: 66,042; python: 46,176; javascript: 9,214; objc: 273; sh: 78; makefile: 56; cpp: 25
file content (45 lines) | stat: -rw-r--r-- 1,015 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
#include <SDL.h>

#if !(SDL_VERSION_ATLEAST(2, 0, 5))
/* These functions require SDL 2.0.5 or greater.

  https://wiki.libsdl.org/SDL_SetWindowResizable
*/
void
SDL_SetWindowResizable(SDL_Window *window, SDL_bool resizable)
{
}
int
SDL_GetWindowOpacity(SDL_Window *window, float *opacity)
{
    SDL_SetError("SDL 2.0.5 or greater required");
    return -1;
}
int
SDL_SetWindowOpacity(SDL_Window *window, float opacity)
{
    SDL_SetError("SDL 2.0.5 or greater required");
    return -1;
}

int
SDL_SetWindowModalFor(SDL_Window *modal_window, SDL_Window *parent_window)
{
    SDL_SetError("SDL 2.0.5 or greater required");
    return -1;
}
int
SDL_SetWindowInputFocus(SDL_Window *window)
{
    SDL_SetError("SDL 2.0.5 or greater required");
    return -1;
}
SDL_Surface *
SDL_CreateRGBSurfaceWithFormat(Uint32 flags, int width, int height, int depth,
                               Uint32 format)
{
    SDL_SetError("SDL 2.0.5 or greater required");
    return NULL;
}

#endif /*if !(SDL_VERSION_ATLEAST(2, 0, 5))*/