Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 5962963

Browse files
committed
Moved all externally visible operation implementations out of name spaces to satisfy both Travis and Visual Studio.
1 parent 84eaf04 commit 5962963

5 files changed

Lines changed: 922 additions & 918 deletions

File tree

plugins/embark-assistant/finder_ui.cpp

Lines changed: 23 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -1112,32 +1112,34 @@ namespace embark_assist {
11121112

11131113
ViewscreenFindUi::ViewscreenFindUi() {
11141114
}
1115+
}
1116+
}
11151117

1116-
//===============================================================================
1117-
1118-
void init(DFHack::Plugin *plugin_self, embark_assist::defs::find_callbacks find_callback, uint16_t max_inorganic) {
1119-
if (!state) { // First call. Have to do the setup
1120-
ui_setup(find_callback, max_inorganic);
1121-
}
1122-
Screen::show(new ViewscreenFindUi(), plugin_self);
1123-
}
1118+
//===============================================================================
1119+
// Exported operations
1120+
//===============================================================================
11241121

1125-
//===============================================================================
1122+
void embark_assist::finder_ui::init(DFHack::Plugin *plugin_self, embark_assist::defs::find_callbacks find_callback, uint16_t max_inorganic) {
1123+
if (!embark_assist::finder_ui::state) { // First call. Have to do the setup
1124+
embark_assist::finder_ui::ui_setup(find_callback, max_inorganic);
1125+
}
1126+
Screen::show(new ViewscreenFindUi(), plugin_self);
1127+
}
11261128

1127-
void activate() {
1128-
}
1129+
//===============================================================================
11291130

1130-
//===============================================================================
1131+
void embark_assist::finder_ui::activate() {
1132+
}
11311133

1132-
void shutdown() {
1133-
if (embark_assist::finder_ui::state) {
1134-
for (uint16_t i = 0; i < state->ui.size(); i++) {
1135-
delete state->ui[i];
1136-
}
1134+
//===============================================================================
11371135

1138-
delete state;
1139-
state = nullptr;
1140-
}
1136+
void embark_assist::finder_ui::shutdown() {
1137+
if (embark_assist::finder_ui::state) {
1138+
for (uint16_t i = 0; i < embark_assist::finder_ui::state->ui.size(); i++) {
1139+
delete embark_assist::finder_ui::state->ui[i];
11411140
}
1141+
1142+
delete embark_assist::finder_ui::state;
1143+
embark_assist::finder_ui::state = nullptr;
11421144
}
1143-
}
1145+
}

plugins/embark-assistant/help_ui.cpp

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -302,13 +302,13 @@ namespace embark_assist{
302302

303303
ViewscreenHelpUi::ViewscreenHelpUi() {
304304
}
305+
}
306+
}
305307

306-
//===============================================================================
307-
// Exported operations
308-
//===============================================================================
308+
//===============================================================================
309+
// Exported operations
310+
//===============================================================================
309311

310-
void init(DFHack::Plugin *plugin_self) {
311-
Screen::show(new ViewscreenHelpUi(), plugin_self);
312-
}
313-
}
314-
}
312+
void embark_assist::help_ui::init(DFHack::Plugin *plugin_self) {
313+
Screen::show(new embark_assist::help_ui::ViewscreenHelpUi(), plugin_self);
314+
}

0 commit comments

Comments
 (0)