mirror of
https://foundry.openuru.org/gitblit/r/CWE-ou-minkata.git
synced 2025-07-17 18:59:09 +00:00
Fix no cursor on window frame and title bar.
Remove mouse capture and handle visibility via WM_SETCURSOR messages
instead of window activation events. See
aed7e97d0d
for original implementation
This commit is contained in:
@ -750,27 +750,3 @@ bool plMouseDevice::MsgReceive(plMessage* msg)
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
|
||||
void plMouseDevice::HandleWindowActivate(bool bActive, HWND hWnd)
|
||||
{
|
||||
if ( bActive )
|
||||
{
|
||||
RECT rect;
|
||||
::GetClientRect(hWnd,&rect);
|
||||
|
||||
// rect.right /= plInputManager::GetInstance()->GetMouseScale();
|
||||
// rect.bottom /= plInputManager::GetInstance()->GetMouseScale();
|
||||
|
||||
::MapWindowPoints( hWnd, NULL, (POINT *)&rect, 2 );
|
||||
::ShowCursor( FALSE );
|
||||
SetCapture(hWnd);
|
||||
|
||||
}
|
||||
else
|
||||
{
|
||||
ReleaseCapture();
|
||||
::ShowCursor( TRUE );
|
||||
}
|
||||
}
|
||||
|
@ -160,7 +160,6 @@ public:
|
||||
~plMouseDevice();
|
||||
|
||||
const char* GetInputName() { return "mouse"; }
|
||||
void HandleWindowActivate(bool bActive, hsWindowHndl hWnd);
|
||||
|
||||
bool HasControlFlag(int f) const { return fControlFlags.IsBitSet(f); }
|
||||
void SetControlFlag(int f)
|
||||
|
@ -584,8 +584,6 @@ void plDInputMgr::AddDevice(IDirectInputDevice8* device)
|
||||
void plDInputMgr::ConfigureDevice()
|
||||
{
|
||||
::ShowCursor( TRUE );
|
||||
ReleaseCapture();
|
||||
|
||||
|
||||
DICOLORSET dics;
|
||||
ZeroMemory(&dics, sizeof(DICOLORSET));
|
||||
@ -607,8 +605,6 @@ void plDInputMgr::ConfigureDevice()
|
||||
fDI->fSticks[i]->fDevice->SetActionMap( fDI->fActionFormat, NULL, DIDSAM_FORCESAVE );
|
||||
|
||||
::ShowCursor( FALSE );
|
||||
SetCapture(fhWnd);
|
||||
|
||||
}
|
||||
|
||||
bool plDInputMgr::MsgReceive(plMessage* msg)
|
||||
|
Reference in New Issue
Block a user