Skip to content

Commit

Permalink
Removed ClipCursor which prevented cursor from leaving client window.
Browse files Browse the repository at this point in the history
Disabled cursor being re-centered during progress screen.
  • Loading branch information
Deledrius committed Jul 11, 2011
1 parent 935cb5a commit ead1eb5
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 8 deletions.
3 changes: 2 additions & 1 deletion Sources/Plasma/Apps/plClient/plClient.cpp
Expand Up @@ -1286,6 +1286,8 @@ void plClient::IIncProgress (hsScalar byHowMuch, const char * text)
//============================================================================
void plClient::IStartProgress( const char *title, hsScalar len )
{
plInputManager::SetRecenterMouse(false);

if (fProgressBar)
{
fProgressBar->SetLength(fProgressBar->GetMax()+len);
Expand Down Expand Up @@ -2191,7 +2193,6 @@ void plClient::ResetDisplayDevice(int Width, int Height, int ColorDepth, hsBool
else
{
SetWindowPos( fWindowHndl, HWND_TOP, 0, 0, Width, Height, flags );
::ClipCursor(nil);
}

WindowActivate(true);
Expand Down
2 changes: 0 additions & 2 deletions Sources/Plasma/PubUtilLib/plInputCore/plInputDevice.cpp
Expand Up @@ -795,15 +795,13 @@ void plMouseDevice::HandleWindowActivate(bool bActive, HWND hWnd)
// rect.bottom /= plInputManager::GetInstance()->GetMouseScale();

::MapWindowPoints( hWnd, NULL, (POINT *)&rect, 2 );
::ClipCursor(&rect);
::ShowCursor( FALSE );
SetCapture(hWnd);

}
else
{
ReleaseCapture();
::ClipCursor(nil);
::ShowCursor( TRUE );
}
}
5 changes: 0 additions & 5 deletions Sources/Plasma/PubUtilLib/plInputCore/plInputManager.cpp
Expand Up @@ -547,7 +547,6 @@ void plDInputMgr::AddDevice(IDirectInputDevice8* device)

void plDInputMgr::ConfigureDevice()
{
::ClipCursor(nil);
::ShowCursor( TRUE );
ReleaseCapture();

Expand All @@ -571,10 +570,6 @@ void plDInputMgr::ConfigureDevice()
for (int i = 0; i < fDI->fSticks.Count(); i++)
fDI->fSticks[i]->fDevice->SetActionMap( fDI->fActionFormat, NULL, DIDSAM_FORCESAVE );

RECT rect;
::GetClientRect(fhWnd,&rect);
::ClientToScreen(fhWnd,(LPPOINT)&rect);
::ClipCursor(&rect);
::ShowCursor( FALSE );
SetCapture(fhWnd);

Expand Down

0 comments on commit ead1eb5

Please sign in to comment.