| 50 | } |
| 51 | |
| 52 | void CWindow::SetPositionSize(int x, int y, int width, int height) |
| 53 | { |
| 54 | #if SDL_VERSION_ATLEAST(2, 0, 5) |
| 55 | int borderH; |
| 56 | SDL_GetWindowBordersSize(m_window, &borderH, nullptr, nullptr, nullptr); |
| 57 | #else |
| 58 | int borderH = 0; |
| 59 | #endif |
| 60 | SDL_RestoreWindow(m_window); |
| 61 | SDL_SetWindowPosition(m_window, x, std::max(y, borderH)); |
| 62 | SDL_SetWindowSize(m_window, width, height); |
| 63 | } |
| 64 | |
| 65 | void CWindow::GetPositionSize(int *x, int *y, int *width, int *height) |
| 66 | { |
no test coverage detected