aboutsummaryrefslogtreecommitdiff
path: root/engines/hopkins/graphics.cpp
diff options
context:
space:
mode:
authorStrangerke2013-03-20 07:36:06 +0100
committerStrangerke2013-03-20 07:36:06 +0100
commit6a446ff9d170640bf698f7ef19386050ee4bd9c2 (patch)
tree80e97559391c2a5dddaf5d9c1fc4c9acf9d3558b /engines/hopkins/graphics.cpp
parent852e65bd02bc1278386d79ca68f81e3d15e9fa43 (diff)
downloadscummvm-rg350-6a446ff9d170640bf698f7ef19386050ee4bd9c2.tar.gz
scummvm-rg350-6a446ff9d170640bf698f7ef19386050ee4bd9c2.tar.bz2
scummvm-rg350-6a446ff9d170640bf698f7ef19386050ee4bd9c2.zip
HOPKINS: Remove setParent() from GraphicsManager
Diffstat (limited to 'engines/hopkins/graphics.cpp')
-rw-r--r--engines/hopkins/graphics.cpp24
1 files changed, 11 insertions, 13 deletions
diff --git a/engines/hopkins/graphics.cpp b/engines/hopkins/graphics.cpp
index 4ae251fd49..1f8ee4b044 100644
--- a/engines/hopkins/graphics.cpp
+++ b/engines/hopkins/graphics.cpp
@@ -35,7 +35,9 @@
namespace Hopkins {
-GraphicsManager::GraphicsManager() {
+GraphicsManager::GraphicsManager(HopkinsEngine *vm) {
+ _vm = vm;
+
_lockCounter = 0;
_initGraphicsFl = false;
_screenWidth = _screenHeight = 0;
@@ -75,20 +77,10 @@ GraphicsManager::GraphicsManager() {
Common::fill(&_colorTable[0], &_colorTable[PALETTE_EXT_BLOCK_SIZE], 0);
Common::fill(&_palette[0], &_palette[PALETTE_EXT_BLOCK_SIZE], 0);
Common::fill(&_oldPalette[0], &_oldPalette[PALETTE_EXT_BLOCK_SIZE], 0);
-}
-
-GraphicsManager::~GraphicsManager() {
- _vm->_globals->freeMemory(_vesaScreen);
- _vm->_globals->freeMemory(_vesaBuffer);
- _vm->_globals->freeMemory(_screenBuffer);
-}
-
-void GraphicsManager::setParent(HopkinsEngine *vm) {
- _vm = vm;
-
+
if (_vm->getIsDemo()) {
if (_vm->getPlatform() == Common::kPlatformLinux)
- // CHECKME: Should be false?
+ // CHECKME: Should be false?
MANU_SCROLL = true;
else
MANU_SCROLL = false;
@@ -99,6 +91,12 @@ void GraphicsManager::setParent(HopkinsEngine *vm) {
}
}
+GraphicsManager::~GraphicsManager() {
+ _vm->_globals->freeMemory(_vesaScreen);
+ _vm->_globals->freeMemory(_vesaBuffer);
+ _vm->_globals->freeMemory(_screenBuffer);
+}
+
void GraphicsManager::setGraphicalMode(int width, int height) {
if (!_initGraphicsFl) {
Graphics::PixelFormat pixelFormat16(2, 5, 6, 5, 0, 11, 5, 0, 0);