sdlSetWindowMaximumSize function

bool sdlSetWindowMaximumSize(
  1. Pointer<SdlWindow> window,
  2. int maxW,
  3. int maxH
)

Set the maximum size of a window's client area.

\param window the window to change. \param max_w the maximum width of the window, or 0 for no limit. \param max_h the maximum height of the window, or 0 for no limit. \returns true on success or false on failure; call SDL_GetError() for more information.

\threadsafety This function should only be called on the main thread.

\since This function is available since SDL 3.1.3.

\sa SDL_GetWindowMaximumSize \sa SDL_SetWindowMinimumSize

extern SDL_DECLSPEC bool SDLCALL SDL_SetWindowMaximumSize(SDL_Window *window, int max_w, int max_h)

Implementation

bool sdlSetWindowMaximumSize(Pointer<SdlWindow> window, int maxW, int maxH) {
  final sdlSetWindowMaximumSizeLookupFunction = libSdl3.lookupFunction<
      Uint8 Function(Pointer<SdlWindow> window, Int32 maxW, Int32 maxH),
      int Function(Pointer<SdlWindow> window, int maxW,
          int maxH)>('SDL_SetWindowMaximumSize');
  return sdlSetWindowMaximumSizeLookupFunction(window, maxW, maxH) == 1;
}