mirror of
https://port.numenaute.org/aleajactaest/khanat-code-old.git
synced 2024-11-26 08:46:19 +00:00
Use software cursor with attached display
This commit is contained in:
parent
f731d220d7
commit
cfd8f79b3d
5 changed files with 13 additions and 7 deletions
|
@ -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…
Reference in a new issue