HOPKINS: Use platform detection in order to properly initialize the mouse cursor

Also fix mass-renaming error in header
This commit is contained in:
Strangerke 2012-10-27 19:08:53 +02:00
parent ec0a33b949
commit 46b44b923b
5 changed files with 14 additions and 6 deletions

View file

@ -47,6 +47,10 @@ Common::Language HopkinsEngine::getLanguage() const {
return _gameDescription->desc.language; return _gameDescription->desc.language;
} }
Common::Platform HopkinsEngine::getPlatform() const {
return _gameDescription->desc.platform;
}
bool HopkinsEngine::getIsDemo() const { bool HopkinsEngine::getIsDemo() const {
return _gameDescription->desc.flags & ADGF_DEMO; return _gameDescription->desc.flags & ADGF_DEMO;
} }

View file

@ -16,7 +16,7 @@
* You should have received a copy of the GNU General Public License * You should have received a copy of the GNU General Public License
* along with this program; if not, write to the _globals.FRee Software * along with this program; if not, write to the _globals.FRee Software
* Foundation, Inc., 51 _globals.FRanklin Street, Fifth Floor, Boston, MA 02110-1301, USA. * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
* *
*/ */

View file

@ -16,7 +16,7 @@
* You should have received a copy of the GNU General Public License * You should have received a copy of the GNU General Public License
* along with this program; if not, write to the _globals.FRee Software * along with this program; if not, write to the _globals.FRee Software
* Foundation, Inc., 51 _globals.FRanklin Street, Fifth Floor, Boston, MA 02110-1301, USA. * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
* *
*/ */
@ -514,8 +514,11 @@ void HopkinsEngine::INIT_SYSTEM() {
// Set graphics mode // Set graphics mode
_graphicsManager.SET_MODE(640, 480); _graphicsManager.SET_MODE(640, 480);
_eventsManager.mouse_linux = true; if (getPlatform() == Common::kPlatformLinux)
_eventsManager.mouse_linux = true;
else
_eventsManager.mouse_linux = false;
switch (_globals.FR) { switch (_globals.FR) {
case 0: case 0:
if (!_eventsManager.mouse_linux) if (!_eventsManager.mouse_linux)
@ -524,7 +527,7 @@ void HopkinsEngine::INIT_SYSTEM() {
_fileManager.CONSTRUIT_SYSTEM("LSOUAN.SPR"); _fileManager.CONSTRUIT_SYSTEM("LSOUAN.SPR");
break; break;
case 1: case 1:
_fileManager.CONSTRUIT_SYSTEM("LSOU_globals.FR.SPR"); _fileManager.CONSTRUIT_SYSTEM("LSOUFR.SPR");
break; break;
case 2: case 2:
_fileManager.CONSTRUIT_SYSTEM("SOUES.SPR"); _fileManager.CONSTRUIT_SYSTEM("SOUES.SPR");

View file

@ -119,6 +119,7 @@ public:
uint32 getFeatures() const; uint32 getFeatures() const;
Common::Language getLanguage() const; Common::Language getLanguage() const;
Common::Platform HopkinsEngine::getPlatform() const;
uint16 getVersion() const; uint16 getVersion() const;
bool getIsDemo() const; bool getIsDemo() const;
bool shouldQuit() const; bool shouldQuit() const;

View file

@ -16,7 +16,7 @@
* You should have received a copy of the GNU General Public License * You should have received a copy of the GNU General Public License
* along with this program; if not, write to the _globals.FRee Software * along with this program; if not, write to the _globals.FRee Software
* Foundation, Inc., 51 _globals.FRanklin Street, Fifth Floor, Boston, MA 02110-1301, USA. * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
* *
*/ */