PETKA: added QObjectCase

This commit is contained in:
Andrei Prykhodko 2019-05-31 09:13:14 +03:00 committed by Eugene Sandulenko
parent dbff81f8d5
commit 9c0909b9b8
5 changed files with 72 additions and 1 deletions

View File

@ -8,6 +8,7 @@ MODULE_OBJS = \
q_message_object.o \
q_object.o \
q_object_bg.o \
q_object_case.o \
q_object_cursor.o \
q_system.o

View File

@ -0,0 +1,29 @@
/* 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.
*
*/
#include "petka/q_object_case.h"
namespace Petka {
} // End of namespace Petka

View File

@ -0,0 +1,36 @@
/* 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.
*
*/
#ifndef PETKA_Q_OBJECT_CASE_H
#define PETKA_Q_OBJECT_CASE_H
#include "petka/q_object.h"
namespace Petka {
class QObjectCase : public QObject {
};
} // End of namespace Petka
#endif

View File

@ -24,13 +24,14 @@
#include "common/substream.h"
#include "petka/petka.h"
#include "petka/q_object_case.h"
#include "petka/q_object_cursor.h"
#include "petka/q_system.h"
namespace Petka {
QSystem::QSystem(PetkaEngine &vm)
: _vm(vm), _cursor(nullptr) {}
: _vm(vm), _cursor(nullptr), _case(nullptr) {}
QSystem::~QSystem() {
@ -81,7 +82,9 @@ bool QSystem::init() {
addMessageForAllObjects(kTotalInit);
_cursor.reset(new QObjectCursor());
_case.reset(new QObjectCase());
_allObjects.push_back(_cursor.get());
_allObjects.push_back(_case.get());
return true;
}

View File

@ -29,6 +29,7 @@
namespace Petka {
class PetkaEngine;
class QObjectCase;
class QObjectCursor;
class QSystem {
@ -49,6 +50,7 @@ private:
Common::Array<QMessageObject *> _allObjects;
Common::Array<QMessage> _messages;
Common::ScopedPtr<QObjectCursor> _cursor;
Common::ScopedPtr<QObjectCase> _case;
};
} // End of namespace Petka