[Scummvm-git-logs] scummvm master -> eb55d4a11301da172d34d82eeac3ad89929cbc04

grisenti noreply at scummvm.org
Sun Apr 9 13:43:13 UTC 2023


This automated email contains information about 1 new commit which have been
pushed to the 'scummvm' repo located at https://github.com/scummvm/scummvm .

Summary:
eb55d4a113 HPL1: rename iMouse to Mouse


Commit: eb55d4a11301da172d34d82eeac3ad89929cbc04
    https://github.com/scummvm/scummvm/commit/eb55d4a11301da172d34d82eeac3ad89929cbc04
Author: grisenti (emanuele at grisenti.net)
Date: 2023-04-09T15:28:32+02:00

Commit Message:
HPL1: rename iMouse to Mouse

Changed paths:
    engines/hpl1/engine/input/Input.cpp
    engines/hpl1/engine/input/Input.h
    engines/hpl1/engine/input/LowLevelInput.cpp
    engines/hpl1/engine/input/LowLevelInput.h
    engines/hpl1/engine/input/Mouse.cpp
    engines/hpl1/engine/input/Mouse.h


diff --git a/engines/hpl1/engine/input/Input.cpp b/engines/hpl1/engine/input/Input.cpp
index 6cb2f2a4477..f9f330c8442 100644
--- a/engines/hpl1/engine/input/Input.cpp
+++ b/engines/hpl1/engine/input/Input.cpp
@@ -146,7 +146,7 @@ Keyboard *cInput::GetKeyboard() {
 
 //-----------------------------------------------------------------------
 
-iMouse *cInput::GetMouse() {
+Mouse *cInput::GetMouse() {
 	return mpMouse;
 }
 
diff --git a/engines/hpl1/engine/input/Input.h b/engines/hpl1/engine/input/Input.h
index 8f8b71cc6c4..648cf2f0afb 100644
--- a/engines/hpl1/engine/input/Input.h
+++ b/engines/hpl1/engine/input/Input.h
@@ -38,7 +38,7 @@
 namespace hpl {
 
 class Keyboard;
-class iMouse;
+class Mouse;
 class LowLevelInput;
 class iInputDevice;
 class iAction;
@@ -105,7 +105,7 @@ public:
 	 *
 	 * \return currently used mouse
 	 */
-	iMouse *GetMouse();
+	Mouse *GetMouse();
 
 	/**
 	 * Get action from map.
@@ -141,7 +141,7 @@ private:
 
 	LowLevelInput *mpLowLevelInput;
 
-	iMouse *mpMouse;
+	Mouse *mpMouse;
 	Keyboard *mpKeyboard;
 };
 } // namespace hpl
diff --git a/engines/hpl1/engine/input/LowLevelInput.cpp b/engines/hpl1/engine/input/LowLevelInput.cpp
index 00943f76313..fcae06b8137 100644
--- a/engines/hpl1/engine/input/LowLevelInput.cpp
+++ b/engines/hpl1/engine/input/LowLevelInput.cpp
@@ -64,8 +64,8 @@ void LowLevelInput::EndInputUpdate() {
 
 //-----------------------------------------------------------------------
 
-iMouse *LowLevelInput::CreateMouse() {
-	return hplNew(iMouse, (this, _lowLevelGraphics));
+Mouse *LowLevelInput::CreateMouse() {
+	return hplNew(Mouse, (this, _lowLevelGraphics));
 }
 
 //-----------------------------------------------------------------------
diff --git a/engines/hpl1/engine/input/LowLevelInput.h b/engines/hpl1/engine/input/LowLevelInput.h
index 70e6771da0d..fbc104a4048 100644
--- a/engines/hpl1/engine/input/LowLevelInput.h
+++ b/engines/hpl1/engine/input/LowLevelInput.h
@@ -33,13 +33,13 @@
 
 namespace hpl {
 
-class iMouse;
+class Mouse;
 class Keyboard;
 class iLowLevelGraphics;
 
 class LowLevelInput {
 	friend class Keyboard;
-	friend class iMouse;
+	friend class Mouse;
 
 public:
 	LowLevelInput(iLowLevelGraphics *graphics);
@@ -58,7 +58,7 @@ public:
 	 */
 	void EndInputUpdate();
 
-	iMouse *CreateMouse();
+	Mouse *CreateMouse();
 	Keyboard *CreateKeyboard();
 
 private:
diff --git a/engines/hpl1/engine/input/Mouse.cpp b/engines/hpl1/engine/input/Mouse.cpp
index cb891c79b2b..10fe47b3881 100644
--- a/engines/hpl1/engine/input/Mouse.cpp
+++ b/engines/hpl1/engine/input/Mouse.cpp
@@ -40,7 +40,7 @@ namespace hpl {
 
 //-----------------------------------------------------------------------
 
-iMouse::iMouse(LowLevelInput *apLowLevelInputSDL, iLowLevelGraphics *apLowLevelGraphics) : iInputDevice("Mouse", eInputDeviceType_Mouse) {
+Mouse::Mouse(LowLevelInput *apLowLevelInputSDL, iLowLevelGraphics *apLowLevelGraphics) : iInputDevice("Mouse", eInputDeviceType_Mouse) {
 	mfMaxPercent = 0.7f;
 	mfMinPercent = 0.1f;
 	mlBufferSize = 6;
@@ -88,7 +88,7 @@ static void setMouseState(const int state, Common::BitArray &states) {
 	}
 }
 
-void iMouse::processEvent(const Common::Event &ev) {
+void Mouse::processEvent(const Common::Event &ev) {
 	if (!Common::isMouseEvent(ev))
 		return;
 	if (ev.type == Common::EVENT_MOUSEMOVE) {
@@ -99,20 +99,20 @@ void iMouse::processEvent(const Common::Event &ev) {
 	_relMousePos = cVector2f(ev.relMouse.x, ev.relMouse.y);
 }
 
-void iMouse::Update() {
+void Mouse::Update() {
 	for (const Common::Event &ev : _lowLevelInputSDL->_events)
 		processEvent(ev);
 }
 
 //-----------------------------------------------------------------------
 
-bool iMouse::ButtonIsDown(eMButton mButton) {
+bool Mouse::ButtonIsDown(eMButton mButton) {
 	return _buttonState.get(mButton);
 }
 
 //-----------------------------------------------------------------------
 
-cVector2f iMouse::GetAbsPosition() {
+cVector2f Mouse::GetAbsPosition() {
 	cVector2f vPos = _absMousePos;
 
 	return vPos;
@@ -120,7 +120,7 @@ cVector2f iMouse::GetAbsPosition() {
 
 //-----------------------------------------------------------------------
 
-cVector2f iMouse::GetRelPosition() {
+cVector2f Mouse::GetRelPosition() {
 	cVector2f vPos = _relMousePos;
 	_relMousePos = cVector2f(0, 0);
 	return vPos;
@@ -128,14 +128,14 @@ cVector2f iMouse::GetRelPosition() {
 
 //-----------------------------------------------------------------------
 
-void iMouse::Reset() {
+void Mouse::Reset() {
 	error("call to unimplemented function Mouse::Reset");
 }
 
 //-----------------------------------------------------------------------
 
-void iMouse::SetSmoothProperties(float afMinPercent,
-								 float afMaxPercent, unsigned int alBufferSize) {
+void Mouse::SetSmoothProperties(float afMinPercent,
+								float afMaxPercent, unsigned int alBufferSize) {
 	mfMaxPercent = afMaxPercent;
 	mfMinPercent = afMinPercent;
 	mlBufferSize = alBufferSize;
diff --git a/engines/hpl1/engine/input/Mouse.h b/engines/hpl1/engine/input/Mouse.h
index ae6475c73c1..9af6fa8ffe2 100644
--- a/engines/hpl1/engine/input/Mouse.h
+++ b/engines/hpl1/engine/input/Mouse.h
@@ -42,10 +42,10 @@ namespace hpl {
 class LowLevelInput;
 class iLowLevelGraphics;
 
-class iMouse : public iInputDevice {
+class Mouse : public iInputDevice {
 public:
-	iMouse(LowLevelInput *apLowLevelInputSDL, iLowLevelGraphics *apLowLevelGraphics);
-	~iMouse() {}
+	Mouse(LowLevelInput *apLowLevelInputSDL, iLowLevelGraphics *apLowLevelGraphics);
+	~Mouse() {}
 
 	/**
 	 * Check if a mouse button is down




More information about the Scummvm-git-logs mailing list