mirror of
https://github.com/mkxp-z/mkxp-z.git
synced 2025-09-10 12:02:53 +02:00
Fix mouse visibility + coords with resized screen
This commit is contained in:
parent
4968069c0e
commit
141e06c7a0
2 changed files with 5 additions and 3 deletions
|
@ -105,7 +105,7 @@ bool EventThread::allocUserEvents()
|
|||
|
||||
EventThread::EventThread()
|
||||
: fullscreen(false),
|
||||
showCursor(false)
|
||||
showCursor(true)
|
||||
{}
|
||||
|
||||
void EventThread::process(RGSSThreadData &rtData)
|
||||
|
|
|
@ -1,12 +1,13 @@
|
|||
#ifdef __WIN32__
|
||||
#include <SDL.h>
|
||||
#include <SDL_syswm.h>
|
||||
#include <cmath>
|
||||
|
||||
#include <windows.h>
|
||||
|
||||
#include "sharedstate.h"
|
||||
#include "input.h"
|
||||
#include "fake-api.h"
|
||||
#include "debugwriter.h"
|
||||
|
||||
|
||||
// Essentials, without edits, needs Win32API. Two problems with that:
|
||||
|
@ -98,7 +99,8 @@ MKXP_GetCursorPos(LPPOINT lpPoint)
|
|||
BOOL __stdcall
|
||||
MKXP_ScreenToClient(HWND hWnd, LPPOINT lpPoint)
|
||||
{
|
||||
SDL_GetMouseState((int*)&lpPoint->x, (int*)&lpPoint->y);
|
||||
lpPoint->x = shState->input().mouseX();
|
||||
lpPoint->y = shState->input().mouseY();
|
||||
return true;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue