Option to disable mouse cursor for touchscreen devices

This commit is contained in:
Sergii Pylypenko
2021-05-11 01:05:10 +03:00
parent 2e4592bd1c
commit f6a669745b
6 changed files with 34 additions and 3 deletions

View File

@@ -1401,7 +1401,7 @@ void ScreenSizeChanged()
void UndrawMouseCursor()
{
/* Don't undraw mouse cursor if it is handled by the video driver. */
if (VideoDriver::GetInstance()->UseSystemCursor()) return;
if (VideoDriver::GetInstance()->UseSystemCursor() || !_settings_client.gui.draw_mouse_cursor) return;
/* Don't undraw the mouse cursor if the screen is not ready */
if (_screen.dst_ptr == nullptr) return;
@@ -1417,7 +1417,7 @@ void UndrawMouseCursor()
void DrawMouseCursor()
{
/* Don't draw mouse cursor if it is handled by the video driver. */
if (VideoDriver::GetInstance()->UseSystemCursor()) return;
if (VideoDriver::GetInstance()->UseSystemCursor() || !_settings_client.gui.draw_mouse_cursor) return;
/* Don't draw the mouse cursor if the screen is not ready */
if (_screen.dst_ptr == nullptr) return;