Fixed: Incorrect assumption that mouse button is released when window is allocated

This commit is contained in:
Zach Reedy authored and Sam Lantinga committed 2022-03-14 08:38:25 -07:00
1 parent 7495b98141
commit 363c36781d
2 files changed
+2 -2

No files matched your search

+1 -1
View File
@@ -374,7 +374,7 @@ WIN_CheckAsyncMouseRelease(SDL_WindowData *data)
if (!(keyState & 0x8000)) {
WIN_CheckWParamMouseButton(SDL_FALSE, mouseFlags, swapButtons, data, SDL_BUTTON_X2, 0);
}
data->mouse_button_flags = 0;
data->mouse_button_flags = (WPARAM)-1;
}
static void
+1 -1
View File
@@ -188,7 +188,7 @@ SetupWindowData(_THIS, SDL_Window * window, HWND hwnd, HWND parent, SDL_bool cre
data->hinstance = (HINSTANCE) GetWindowLongPtr(hwnd, GWLP_HINSTANCE);
data->created = created;
data->high_surrogate = 0;
data->mouse_button_flags = 0;
data->mouse_button_flags = (WPARAM)-1;
data->last_pointer_update = (LPARAM)-1;
data->videodata = videodata;
data->initializing = SDL_TRUE;