Refactoring: Rename network_message_box

This commit is contained in:
simon.kagstrom 2010-02-28 08:02:45 +00:00
parent 75385f566b
commit 7ef8109788
5 changed files with 9 additions and 9 deletions

View File

@ -81,7 +81,7 @@ Gui::Gui()
this->background = NULL;
this->main_menu_bg = NULL;
this->infobox = NULL;
this->textbox = NULL;
this->network_message_box = NULL;
this->status_bar_bg = NULL;
this->keyboard = NULL;
this->default_font = NULL;
@ -159,7 +159,7 @@ Gui::~Gui()
SDL_FreeSurface(this->dialogue_bg);
SDL_FreeSurface(this->disc_info);
SDL_FreeSurface(this->network_info);
SDL_FreeSurface(this->textbox);
SDL_FreeSurface(this->network_message_box);
SDL_FreeSurface(this->selected_key);
SDL_FreeSurface(this->highlighted_key);
SDL_FreeSurface(this->status_bar_bg);
@ -184,7 +184,7 @@ bool Gui::setTheme(const char *path)
this->status_bar_bg = this->loadThemeImage(path, "status_bar.png");
this->infobox = this->loadThemeImage(path, "infobox.png");
this->keyboard = this->loadThemeImage(path, "keyboard.png");
this->textbox = this->loadThemeImage(path, "textbox.png");
this->network_message_box = this->loadThemeImage(path, "network_message_box.png");
this->dialogue_bg = this->loadThemeImage(path, "dialogue_box.png");
this->disc_info = this->loadThemeImage(path, "disc_info.png");
this->network_info = this->loadThemeImage(path, "network_info.png");
@ -219,7 +219,7 @@ bool Gui::setTheme(const char *path)
SDL_FreeSurface(this->infobox);
SDL_FreeSurface(this->dialogue_bg);
SDL_FreeSurface(this->disc_info);
SDL_FreeSurface(this->textbox);
SDL_FreeSurface(this->network_message_box);
SDL_FreeSurface(this->selected_key);
SDL_FreeSurface(this->keyboard);
SDL_FreeSurface(this->highlighted_key);

View File

@ -88,7 +88,7 @@ public:
SDL_Surface *main_menu_bg;
SDL_Surface *status_bar_bg;
SDL_Surface *infobox;
SDL_Surface *textbox;
SDL_Surface *network_message_box;
SDL_Surface *keyboard;
SDL_Surface *dialogue_bg;
SDL_Surface *disc_info;

View File

@ -21,11 +21,11 @@ void NetworkServerMessages::draw(SDL_Surface *where)
SDL_Rect dst;
int x = 350;
int y = 242;
int w = Gui::gui->textbox->w;
int h = Gui::gui->textbox->h;
int w = Gui::gui->network_message_box->w;
int h = Gui::gui->network_message_box->h;
dst = (SDL_Rect){x,y,0,0};
SDL_BlitSurface(Gui::gui->textbox, NULL, where, &dst);
SDL_BlitSurface(Gui::gui->network_message_box, NULL, where, &dst);
Menu::draw(where, x+6, y+8, w-6, h-8);
}

View File

@ -144,7 +144,7 @@ public:
SDL_BlitSurface(Gui::gui->infobox, NULL, where, &dst);
dst = (SDL_Rect){350,242,0,0};
SDL_BlitSurface(Gui::gui->textbox, NULL, where, &dst);
SDL_BlitSurface(Gui::gui->network_message_box, NULL, where, &dst);
this->menu->draw(where, 50, 70, 300, 400);
this->help->draw(where, 354, 24, 264, 210);

View File

Before

Width:  |  Height:  |  Size: 1.6 KiB

After

Width:  |  Height:  |  Size: 1.6 KiB