mirror of
https://github.com/Oibaf66/frodo-wii.git
synced 2024-11-22 11:29:24 +01:00
Add disc info box
This commit is contained in:
parent
a7aec61e02
commit
b52c401665
@ -77,7 +77,7 @@ public:
|
||||
|
||||
this->bg = NULL;
|
||||
this->infobox = NULL;
|
||||
this->textbox = NULL;
|
||||
this->disc_info = NULL;
|
||||
}
|
||||
|
||||
~DiscView()
|
||||
@ -94,7 +94,7 @@ public:
|
||||
{
|
||||
this->bg = Gui::gui->main_menu_bg;
|
||||
this->infobox = Gui::gui->infobox;
|
||||
this->textbox = Gui::gui->textbox;
|
||||
this->disc_info = Gui::gui->disc_info;
|
||||
|
||||
this->menu->setFont(Gui::gui->default_font);
|
||||
this->menu->setSelectedBackground(Gui::gui->bg_left, Gui::gui->bg_middle,
|
||||
@ -121,10 +121,7 @@ public:
|
||||
SDL_BlitSurface(this->bg, NULL, where, &dst);
|
||||
|
||||
dst = (SDL_Rect){350,13,0,0};
|
||||
SDL_BlitSurface(this->infobox, NULL, where, &dst);
|
||||
|
||||
dst = (SDL_Rect){350,242,0,0};
|
||||
SDL_BlitSurface(this->textbox, NULL, where, &dst);
|
||||
SDL_BlitSurface(this->disc_info, NULL, where, &dst);
|
||||
|
||||
this->menu->draw(where, 50, 70, 300, 400);
|
||||
}
|
||||
@ -133,5 +130,5 @@ protected:
|
||||
DiscMenu *menu;
|
||||
SDL_Surface *bg;
|
||||
SDL_Surface *infobox;
|
||||
SDL_Surface *textbox;
|
||||
SDL_Surface *disc_info;
|
||||
};
|
||||
|
3
gui.cpp
3
gui.cpp
@ -74,6 +74,7 @@ bool Gui::setTheme(const char *path)
|
||||
this->infobox = this->loadThemeImage(path, "infobox.png");
|
||||
this->textbox = this->loadThemeImage(path, "textbox.png");
|
||||
this->dialogue_bg = this->loadThemeImage(path, "dialogue_box.png");
|
||||
this->disc_info = this->loadThemeImage(path, "disc_info.png");
|
||||
|
||||
this->default_font = this->loadThemeFont(path, "font.ttf", 18);
|
||||
this->small_font = this->loadThemeFont(path, "font.ttf", 16);
|
||||
@ -82,6 +83,7 @@ bool Gui::setTheme(const char *path)
|
||||
!this->bg_submenu_left || !this->bg_submenu_right ||
|
||||
!this->bg_submenu_middle ||
|
||||
!this->dialogue_bg ||
|
||||
!this->disc_info ||
|
||||
!this->default_font ||
|
||||
!this->small_font)
|
||||
{
|
||||
@ -95,6 +97,7 @@ bool Gui::setTheme(const char *path)
|
||||
SDL_FreeSurface(this->main_menu_bg);
|
||||
SDL_FreeSurface(this->infobox);
|
||||
SDL_FreeSurface(this->dialogue_bg);
|
||||
SDL_FreeSurface(this->disc_info);
|
||||
SDL_FreeSurface(this->textbox);
|
||||
|
||||
if (this->default_font)
|
||||
|
1
gui.hh
1
gui.hh
@ -72,6 +72,7 @@ public:
|
||||
SDL_Surface *infobox;
|
||||
SDL_Surface *textbox;
|
||||
SDL_Surface *dialogue_bg;
|
||||
SDL_Surface *disc_info;
|
||||
SDL_Surface *bg_left, *bg_right, *bg_middle,
|
||||
*bg_submenu_left, *bg_submenu_right, *bg_submenu_middle;
|
||||
|
||||
|
BIN
themes/default/disc_info.png
Normal file
BIN
themes/default/disc_info.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 2.1 KiB |
Loading…
Reference in New Issue
Block a user