Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
DINGUX: fix compilation for the opengl branch
Moved events related code to backends/events/dinguxsdl/* and move graphics related code to backends/graphics/dinguxsdl/* Subclass OSystem_POSIX instead of OSystem_SDL svn-id: r53730
- Loading branch information
Showing
11 changed files
with
240 additions
and
108 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
/* ScummVM - Graphic Adventure Engine | ||
* | ||
* ScummVM is the legal property of its developers, whose names | ||
* are too numerous to list here. Please refer to the COPYRIGHT | ||
* file distributed with this source distribution. | ||
* | ||
* This program is free software; you can redistribute it and/or | ||
* modify it under the terms of the GNU General Public License | ||
* as published by the Free Software Foundation; either version 2 | ||
* of the License, or (at your option) any later version. | ||
* This program is distributed in the hope that it will be useful, | ||
* but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
* GNU General Public License for more details. | ||
* You should have received a copy of the GNU General Public License | ||
* along with this program; if not, write to the Free Software | ||
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. | ||
* | ||
* $URL$ | ||
* $Id$ | ||
* | ||
*/ | ||
|
||
#ifndef BACKENDS_EVENTS_SDL_DINGUX_H | ||
#define BACKENDS_EVENTS_SDL_DINGUX_H | ||
#if defined(DINGUX) | ||
|
||
#include "backends/platform/dingux/dingux.h" | ||
#include "backends/events/dinguxsdl/dinguxsdl-events.h" | ||
|
||
class DINGUXSdlEventSource : public SdlEventSource { | ||
public: | ||
DINGUXSdlEventSource(); | ||
void setCurrentGraphMan(DINGUXSdlGraphicsManager *_graphicManager); | ||
|
||
protected: | ||
DINGUXSdlGraphicsManager *_grpMan; | ||
|
||
bool remapKey(SDL_Event &ev, Common::Event &event); | ||
void fillMouseEvent(Common::Event &event, int x, int y); | ||
void warpMouse(int x, int y); | ||
}; | ||
|
||
#endif /* DINGUX */ | ||
#endif /* BACKENDS_EVENTS_SDL_DINGUX_H */ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,69 @@ | ||
/* ScummVM - Graphic Adventure Engine | ||
* | ||
* ScummVM is the legal property of its developers, whose names | ||
* are too numerous to list here. Please refer to the COPYRIGHT | ||
* file distributed with this source distribution. | ||
* | ||
* This program is free software; you can redistribute it and/or | ||
* modify it under the terms of the GNU General Public License | ||
* as published by the Free Software Foundation; either version 2 | ||
* of the License, or (at your option) any later version. | ||
* This program is distributed in the hope that it will be useful, | ||
* but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
* GNU General Public License for more details. | ||
* You should have received a copy of the GNU General Public License | ||
* along with this program; if not, write to the Free Software | ||
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. | ||
* | ||
* $URL$ | ||
* $Id$ | ||
* | ||
*/ | ||
|
||
#ifndef BACKENDS_GRAPHICS_SDL_DINGUX_H | ||
#define BACKENDS_GRAPHICS_SDL_DINGUX_H | ||
#if defined (DINGUX) | ||
|
||
#include "backends/graphics/sdl/sdl-graphics.h" | ||
|
||
#include "graphics/scaler/aspect.h" // for aspect2Real | ||
#include "graphics/scaler/downscaler.h" | ||
|
||
enum { | ||
GFX_HALF = 12 | ||
}; | ||
|
||
class DINGUXSdlGraphicsManager : public SdlGraphicsManager { | ||
public: | ||
DINGUXSdlGraphicsManager(SdlEventSource *boss); | ||
|
||
bool hasFeature(OSystem::Feature f); | ||
void setFeatureState(OSystem::Feature f, bool enable); | ||
bool getFeatureState(OSystem::Feature f); | ||
int getDefaultGraphicsMode() const; | ||
|
||
void initSize(uint w, uint h); | ||
const OSystem::GraphicsMode *getSupportedGraphicsModes() const; | ||
bool setGraphicsMode(const char *name); | ||
bool setGraphicsMode(int mode); | ||
void setGraphicsModeIntern(); | ||
void internUpdateScreen(); | ||
void showOverlay(); | ||
void hideOverlay(); | ||
bool loadGFXMode(); | ||
void drawMouse(); | ||
void undrawMouse(); | ||
|
||
SdlGraphicsManager::MousePos *getMouseCurState(); | ||
SdlGraphicsManager::VideoState *getVideoMode(); | ||
bool isOverlayVisible(); | ||
|
||
protected: | ||
SdlEventSource *_evSrc; | ||
}; | ||
|
||
#endif /* DINGUX */ | ||
#endif /* BACKENDS_GRAPHICS_SDL_DINGUX_H */ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.