Skip to content

Commit

Permalink
Merge pull request #999 from dafioram/header_reduce
Browse files Browse the repository at this point in the history
TITANIC: Reduce header includes
  • Loading branch information
dreammaster committed Aug 25, 2017
2 parents bb3fb4a + d01354a commit 9b07378
Show file tree
Hide file tree
Showing 106 changed files with 347 additions and 191 deletions.
1 change: 1 addition & 0 deletions engines/titanic/carry/carry.cpp
Expand Up @@ -21,6 +21,7 @@
*/

#include "titanic/carry/carry.h"
#include "titanic/debugger.h"
#include "titanic/messages/messages.h"
#include "titanic/npcs/character.h"
#include "titanic/npcs/succubus.h"
Expand Down
4 changes: 4 additions & 0 deletions engines/titanic/continue_save_dialog.cpp
Expand Up @@ -21,7 +21,11 @@
*/

#include "titanic/continue_save_dialog.h"
#include "titanic/support/movie_manager.h"
#include "titanic/titanic.h"
#include "common/error.h"
#include "common/str-array.h"
#include "graphics/screen.h"

namespace Titanic {

Expand Down
5 changes: 4 additions & 1 deletion engines/titanic/core/game_object.cpp
Expand Up @@ -24,13 +24,16 @@
#include "titanic/core/mail_man.h"
#include "titanic/core/resource_key.h"
#include "titanic/core/room_item.h"
#include "titanic/core/project_item.h"
#include "titanic/debugger.h"
#include "titanic/events.h"
#include "titanic/game_manager.h"
#include "titanic/npcs/true_talk_npc.h"
#include "titanic/pet_control/pet_control.h"
#include "titanic/star_control/star_control.h"
#include "titanic/support/files_manager.h"
#include "titanic/support/screen_manager.h"
#include "titanic/support/video_surface.h"
#include "titanic/game_manager.h"
#include "titanic/titanic.h"

namespace Titanic {
Expand Down
13 changes: 7 additions & 6 deletions engines/titanic/core/project_item.cpp
Expand Up @@ -20,17 +20,18 @@
*
*/

#include "common/file.h"
#include "common/savefile.h"
#include "graphics/scaler.h"
#include "graphics/thumbnail.h"
#include "titanic/game_manager.h"
#include "titanic/titanic.h"
#include "titanic/core/dont_save_file_item.h"
#include "titanic/core/node_item.h"
#include "titanic/core/project_item.h"
#include "titanic/core/view_item.h"
#include "titanic/events.h"
#include "titanic/game_manager.h"
#include "titanic/pet_control/pet_control.h"
#include "titanic/titanic.h"
#include "common/file.h"
#include "common/savefile.h"
#include "graphics/scaler.h"
#include "graphics/thumbnail.h"

namespace Titanic {

Expand Down
7 changes: 4 additions & 3 deletions engines/titanic/core/resource_key.cpp
Expand Up @@ -20,10 +20,11 @@
*
*/

#include "common/file.h"
#include "titanic/titanic.h"
#include "titanic/support/simple_file.h"
#include "titanic/core/resource_key.h"
#include "titanic/support/files_manager.h"
#include "titanic/support/simple_file.h"
#include "titanic/titanic.h"
#include "common/file.h"

namespace Titanic {

Expand Down
7 changes: 4 additions & 3 deletions engines/titanic/core/view_item.cpp
Expand Up @@ -20,13 +20,14 @@
*
*/

#include "titanic/game_manager.h"
#include "titanic/support/screen_manager.h"
#include "titanic/core/view_item.h"
#include "titanic/core/project_item.h"
#include "titanic/core/room_item.h"
#include "titanic/core/view_item.h"
#include "titanic/events.h"
#include "titanic/game_manager.h"
#include "titanic/messages/messages.h"
#include "titanic/pet_control/pet_control.h"
#include "titanic/support/screen_manager.h"
#include "titanic/titanic.h"

namespace Titanic {
Expand Down
8 changes: 7 additions & 1 deletion engines/titanic/debugger.cpp
Expand Up @@ -21,11 +21,17 @@
*/

#include "titanic/debugger.h"
#include "titanic/titanic.h"
#include "titanic/core/node_item.h"
#include "titanic/core/room_item.h"
#include "titanic/core/tree_item.h"
#include "titanic/core/view_item.h"
#include "titanic/game_manager.h"
#include "titanic/game/movie_tester.h"
#include "titanic/main_game_window.h"
#include "titanic/pet_control/pet_control.h"
#include "titanic/support/movie.h"
#include "titanic/titanic.h"
#include "common/str-array.h"

namespace Titanic {

Expand Down
19 changes: 15 additions & 4 deletions engines/titanic/debugger.h
Expand Up @@ -23,16 +23,27 @@
#ifndef TITANIC_DEBUGGER_H
#define TITANIC_DEBUGGER_H

#include "common/scummsys.h"
#include "gui/debugger.h"
#include "titanic/core/room_item.h"
#include "titanic/core/node_item.h"
#include "titanic/core/view_item.h"
#include "common/scummsys.h"

namespace Titanic {

#define DEBUG_BASIC 1
#define DEBUG_INTERMEDIATE 2
#define DEBUG_DETAILED 3

class CNodeItem;
class CRoomItem;
class CViewItem;
class TitanicEngine;

enum TitanicDebugChannels {
kDebugCore = 1 << 0,
kDebugScripts = 1 << 1,
kDebugGraphics = 1 << 2,
kDebugStarfield = 1 << 3
};

class Debugger : public GUI::Debugger {
private:
/**
Expand Down
4 changes: 2 additions & 2 deletions engines/titanic/detection.cpp
Expand Up @@ -20,10 +20,10 @@
*
*/

#include "titanic/titanic.h"
#include "titanic/core/project_item.h"
#include "titanic/events.h"
#include "titanic/support/simple_file.h"

#include "titanic/titanic.h"
#include "base/plugins.h"
#include "common/savefile.h"
#include "common/str-array.h"
Expand Down
13 changes: 8 additions & 5 deletions engines/titanic/events.cpp
Expand Up @@ -20,14 +20,17 @@
*
*/

#include "common/scummsys.h"
#include "common/events.h"
#include "common/system.h"
#include "engines/util.h"
#include "titanic/events.h"
#include "titanic/titanic.h"
#include "titanic/debugger.h"
#include "titanic/game_manager.h"
#include "titanic/main_game_window.h"
#include "titanic/star_control/star_control.h"
#include "titanic/titanic.h"
#include "common/events.h"
#include "common/scummsys.h"
#include "common/system.h"
#include "engines/util.h"
#include "graphics/screen.h"

namespace Titanic {

Expand Down
1 change: 1 addition & 0 deletions engines/titanic/game/missiveomat.cpp
Expand Up @@ -22,6 +22,7 @@

#include "titanic/game/missiveomat.h"
#include "titanic/core/room_item.h"
#include "titanic/support/files_manager.h"
#include "titanic/titanic.h"

namespace Titanic {
Expand Down
1 change: 1 addition & 0 deletions engines/titanic/game/music_console_button.cpp
Expand Up @@ -22,6 +22,7 @@

#include "titanic/game/music_console_button.h"
#include "titanic/core/room_item.h"
#include "titanic/sound/music_room.h"
#include "titanic/sound/music_room_handler.h"
#include "titanic/titanic.h"

Expand Down
1 change: 1 addition & 0 deletions engines/titanic/game/parrot/parrot_lobby_link_updater.cpp
Expand Up @@ -21,6 +21,7 @@
*/

#include "titanic/game/parrot/parrot_lobby_link_updater.h"
#include "titanic/support/files_manager.h"
#include "titanic/titanic.h"

namespace Titanic {
Expand Down
1 change: 1 addition & 0 deletions engines/titanic/game/sgt/bedhead.cpp
Expand Up @@ -21,6 +21,7 @@
*/

#include "titanic/game/sgt/bedhead.h"
#include "titanic/support/files_manager.h"
#include "titanic/titanic.h"

namespace Titanic {
Expand Down
6 changes: 3 additions & 3 deletions engines/titanic/game/television.cpp
Expand Up @@ -21,11 +21,11 @@
*/

#include "titanic/game/television.h"
#include "titanic/game/get_lift_eye2.h"
#include "titanic/core/project_item.h"
#include "titanic/carry/magazine.h"
#include "titanic/core/project_item.h"
#include "titanic/debugger.h"
#include "titanic/game/get_lift_eye2.h"
#include "titanic/pet_control/pet_control.h"
#include "titanic/titanic.h"

namespace Titanic {

Expand Down
4 changes: 2 additions & 2 deletions engines/titanic/game/transport/lift.cpp
Expand Up @@ -21,9 +21,9 @@
*/

#include "titanic/game/transport/lift.h"
#include "titanic/pet_control/pet_control.h"
#include "titanic/debugger.h"
#include "titanic/moves/multi_move.h"
#include "titanic/titanic.h"
#include "titanic/pet_control/pet_control.h"

namespace Titanic {

Expand Down
2 changes: 1 addition & 1 deletion engines/titanic/game/transport/lift_indicator.cpp
Expand Up @@ -22,8 +22,8 @@

#include "titanic/game/transport/lift_indicator.h"
#include "titanic/game/transport/lift.h"
#include "titanic/debugger.h"
#include "titanic/pet_control/pet_control.h"
#include "titanic/titanic.h"

namespace Titanic {

Expand Down
9 changes: 6 additions & 3 deletions engines/titanic/game_manager.cpp
Expand Up @@ -20,13 +20,16 @@
*
*/

#include "titanic/titanic.h"
#include "titanic/game_manager.h"
#include "titanic/game_view.h"
#include "titanic/support/screen_manager.h"
#include "titanic/core/project_item.h"
#include "titanic/events.h"
#include "titanic/game_view.h"
#include "titanic/messages/messages.h"
#include "titanic/pet_control/pet_control.h"
#include "titanic/sound/background_sound_maker.h"
#include "titanic/support/files_manager.h"
#include "titanic/support/screen_manager.h"
#include "titanic/titanic.h"

namespace Titanic {

Expand Down
18 changes: 12 additions & 6 deletions engines/titanic/game_manager.h
Expand Up @@ -27,18 +27,24 @@
#include "titanic/game_state.h"
#include "titanic/input_handler.h"
#include "titanic/input_translator.h"
#include "titanic/support/simple_file.h"
#include "titanic/support/time_event_info.h"
#include "titanic/support/video_surface.h"
#include "titanic/true_talk/true_talk_manager.h"
#include "titanic/sound/background_sound_maker.h"
#include "titanic/support/time_event_info.h" // class CTimeEventInfo
#include "titanic/true_talk/true_talk_manager.h" // class CTrueTalkManager
#include "titanic/sound/music_room.h"
#include "titanic/sound/sound.h"

namespace Titanic {

class CProjectItem;
class CBackgroundSoundMaker;
class CGameView;
class CMovie;
class CMovieClip;
class CProjectItem;
class CRoomItem;
class CScreenManager;
class CTreeItem;
class CViewItem;
class CVideoSurface;
class SimpleFile;

class CGameManager {
private:
Expand Down
4 changes: 3 additions & 1 deletion engines/titanic/game_state.cpp
Expand Up @@ -21,9 +21,11 @@
*/

#include "titanic/game_state.h"
#include "titanic/titanic.h"
#include "titanic/game_view.h"
#include "titanic/events.h"
#include "titanic/game_manager.h"
#include "titanic/support/screen_manager.h"
#include "titanic/titanic.h"

namespace Titanic {

Expand Down
6 changes: 4 additions & 2 deletions engines/titanic/game_view.h
Expand Up @@ -24,13 +24,15 @@
#define TITANIC_GAME_VIEW_H

#include "common/scummsys.h"
#include "titanic/core/view_item.h"
#include "titanic/support/video_surface.h"

namespace Titanic {

class CMainGameWindow;
class CGameManager;
class CResourceKey;
class CViewItem;
class CVideoSurface;
class Rect;

class CGameView {
protected:
Expand Down
1 change: 1 addition & 0 deletions engines/titanic/gfx/text_control.cpp
Expand Up @@ -21,6 +21,7 @@
*/

#include "titanic/gfx/text_control.h"
#include "titanic/support/strings.h"
#include "titanic/titanic.h"

namespace Titanic {
Expand Down
8 changes: 6 additions & 2 deletions engines/titanic/gfx/text_control.h
Expand Up @@ -24,18 +24,22 @@
#define TITANIC_TEXT_CONTROL_H

#include "common/keyboard.h"
#include "titanic/support/simple_file.h"
#include "titanic/support/screen_manager.h"
#include "titanic/support/text_cursor.h"
#include "titanic/support/strings.h"

namespace Titanic {

class CScreenManager;
class CTextCursor;
class SimpleFile;

class CTextControl {
struct ArrayEntry {
CString _line;
CString _rgb;
CString _string3;
};

private:
Common::Array<ArrayEntry> _array;
CString _lines;
Expand Down
5 changes: 4 additions & 1 deletion engines/titanic/input_handler.cpp
Expand Up @@ -21,11 +21,14 @@
*/

#include "titanic/input_handler.h"
#include "titanic/events.h"
#include "titanic/game_manager.h"
#include "titanic/titanic.h"
#include "titanic/core/project_item.h"
#include "titanic/messages/mouse_messages.h"
#include "titanic/pet_control/pet_control.h"
#include "titanic/support/files_manager.h"
#include "titanic/support/screen_manager.h"
#include "titanic/titanic.h"

namespace Titanic {

Expand Down

0 comments on commit 9b07378

Please sign in to comment.