Use software cursor with attached display

--HG--
branch : multipass-stereo
hg/feature/qt5
kaetemi 10 years ago
parent 38abf2193f
commit 93376226c4

@ -223,7 +223,7 @@ void connectionRestaureVideoMode ()
}
// And setup hardware mouse if we have to
InitMouseWithCursor (ClientCfg.HardwareCursor);
InitMouseWithCursor (ClientCfg.HardwareCursor && !StereoDisplayAttached);
SetMouseFreeLook ();
SetMouseCursor ();
SetMouseSpeed (ClientCfg.CursorSpeed);
@ -278,6 +278,8 @@ void setOutGameFullScreen()
{
setVideoMode(wantedMode);
}
InitMouseWithCursor(ClientCfg.HardwareCursor && !StereoDisplayAttached);
/*
InitMouseWithCursor (true);
Driver->showCursor(false);
@ -396,7 +398,7 @@ bool connection (const string &cookie, const string &fsaddr)
// not initialized at login and remain hardware until here ...
// Re-initialise the mouse (will be now in hardware mode, if required)
//InitMouseWithCursor (ClientCfg.HardwareCursor); // the return value of enableLowLevelMouse() has already been tested at startup
//InitMouseWithCursor (ClientCfg.HardwareCursor && !StereoDisplayAttached); // the return value of enableLowLevelMouse() has already been tested at startup
// no ui init if character selection is automatic
//SetMouseFreeLook ();
@ -556,7 +558,7 @@ bool reconnection()
{
// Re-initialise the mouse (will be now in hardware mode, if required)
SetMousePosFirstTime = true;
InitMouseWithCursor (ClientCfg.HardwareCursor); // the return value of enableLowLevelMouse() has already been tested at startup
InitMouseWithCursor (ClientCfg.HardwareCursor && !StereoDisplayAttached); // the return value of enableLowLevelMouse() has already been tested at startup
// no ui init if character selection is automatic
SetMouseFreeLook ();

@ -1261,7 +1261,7 @@ void initMainLoop()
// Re-initialise the mouse (will be now in hardware mode, if required)
SetMousePosFirstTime = true;
InitMouseWithCursor (ClientCfg.HardwareCursor); // the return value of enableLowLevelMouse() has already been tested at startup
InitMouseWithCursor (ClientCfg.HardwareCursor && !StereoDisplayAttached); // the return value of enableLowLevelMouse() has already been tested at startup
// Re-initialise the keyboard, now in low-level mode, if required
// NB nico : done at end of loading
@ -1504,6 +1504,7 @@ void initWelcomeWindow()
// ***************************************************************************
// NOTE: This feature is not really used anymore, it is a patch transition
void initHardwareCursor(bool secondCall)
{
CInterfaceManager * pIM = CInterfaceManager::getInstance();

@ -21,6 +21,7 @@
/////////////
#include "stdpch.h"
// Client
#include "global.h"
#include "actions.h"
#include "input.h"
#include "interface_v3/interface_manager.h"
@ -310,6 +311,6 @@ CNiceInputAuto::~CNiceInputAuto()
nlassert(_Count >= 0);
if (_Count == 0)
{
InitMouseWithCursor(ClientCfg.HardwareCursor);
InitMouseWithCursor(ClientCfg.HardwareCursor && !StereoDisplayAttached);
}
}

@ -867,7 +867,7 @@ bool login()
SetMouseSpeed (ClientCfg.CursorSpeed);
SetMouseAcceleration (ClientCfg.CursorAcceleration);
SetMousePosFirstTime = true;
InitMouseWithCursor (ClientCfg.HardwareCursor);
InitMouseWithCursor (ClientCfg.HardwareCursor && !StereoDisplayAttached);
// if (ClientCfg.TestBrowser)
// {

@ -73,6 +73,8 @@ void updateFromClientCfg()
if (!StereoDisplayAttached)
setVideoMode(UDriver::CMode(ClientCfg.Width, ClientCfg.Height, (uint8)ClientCfg.Depth,
ClientCfg.Windowed, ClientCfg.Frequency));
// force software cursor when attached
InitMouseWithCursor(ClientCfg.HardwareCursor && !StereoDisplayAttached);
}
// GRAPHICS - GENERAL
@ -292,7 +294,7 @@ void updateFromClientCfg()
{
if (ClientCfg.HardwareCursor != IsMouseCursorHardware())
{
InitMouseWithCursor (ClientCfg.HardwareCursor);
InitMouseWithCursor (ClientCfg.HardwareCursor && !StereoDisplayAttached);
}
}

Loading…
Cancel
Save