| 953 | } |
| 954 | |
| 955 | void SDLWindow::CheckForWindowResize() |
| 956 | { |
| 957 | return; |
| 958 | // Cache client size |
| 959 | _clientSize = GetClientSize(); |
| 960 | int32 width = (int32)(_clientSize.X); |
| 961 | int32 height = (int32)(_clientSize.Y); |
| 962 | |
| 963 | // Check for windows maximized size and see if it needs to adjust position if needed |
| 964 | if (_maximized) |
| 965 | { |
| 966 | // Pick the current monitor data for sizing |
| 967 | SDL_Rect rect; |
| 968 | auto displayId = SDL_GetDisplayForWindow(_window); |
| 969 | SDL_GetDisplayUsableBounds(displayId, &rect); |
| 970 | |
| 971 | if (width > rect.w && height > rect.h) |
| 972 | { |
| 973 | width = rect.w; |
| 974 | height = rect.h; |
| 975 | SDL_SetWindowSize(_window, width, height); |
| 976 | } |
| 977 | } |
| 978 | |
| 979 | // Check if window size has been changed |
| 980 | if (width > 0 && height > 0 && (_swapChain == nullptr || width != _swapChain->GetWidth() || height != _swapChain->GetHeight())) |
| 981 | OnResize(width, height); |
| 982 | } |
| 983 | |
| 984 | void SDLWindow::UpdateCursor() |
| 985 | { |
nothing calls this directly
no test coverage detected