summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorglx <glx@openttd.org>2009-03-30 01:15:51 +0000
committerglx <glx@openttd.org>2009-03-30 01:15:51 +0000
commit66cd5dbc7c9b64554e1e32b35f2a1b0173608553 (patch)
tree79af97c8ca9aefa51045fac59bfc275f99cf351d
parent75c99d8b9b7db2cc723e2bfb98ed8a81cc5e3f6f (diff)
downloadopenttd-66cd5dbc7c9b64554e1e32b35f2a1b0173608553.tar.xz
(svn r15894) -Codechange: remove console widget array (it was empty anyway) and window desc
-rw-r--r--src/console_gui.cpp18
1 files changed, 2 insertions, 16 deletions
diff --git a/src/console_gui.cpp b/src/console_gui.cpp
index e69b17d3e..0656a49eb 100644
--- a/src/console_gui.cpp
+++ b/src/console_gui.cpp
@@ -147,12 +147,9 @@ struct IConsoleWindow : Window
{
static int scroll;
- IConsoleWindow(const WindowDesc *desc) : Window(desc)
+ IConsoleWindow() : Window(0, 0, _screen.width, _screen.height / 3, WC_CONSOLE, NULL)
{
_iconsole_mode = ICONSOLE_OPENED;
-
- this->height = _screen.height / 3;
- this->width = _screen.width;
}
~IConsoleWindow()
@@ -314,17 +311,6 @@ struct IConsoleWindow : Window
int IConsoleWindow::scroll = 0;
-static const Widget _iconsole_window_widgets[] = {
- {WIDGETS_END}
-};
-
-static const WindowDesc _iconsole_window_desc(
- 0, 0, 2, 2, 2, 2,
- WC_CONSOLE, WC_NONE,
- WDF_STD_TOOLTIPS | WDF_DEF_WIDGET | WDF_UNCLICK_BUTTONS,
- _iconsole_window_widgets
-);
-
void IConsoleGUIInit()
{
_iconsole_historypos = ICON_HISTORY_SIZE - 1;
@@ -376,7 +362,7 @@ void IConsoleSwitch()
{
switch (_iconsole_mode) {
case ICONSOLE_CLOSED:
- new IConsoleWindow(&_iconsole_window_desc);
+ new IConsoleWindow();
break;
case ICONSOLE_OPENED: case ICONSOLE_FULL: