added slate-border selection style to attack dialog
also, minor warning fix and documentation
This commit is contained in:
parent
abeb1ccf43
commit
cfb19e2583
6 changed files with 11 additions and 8 deletions
|
@ -17,7 +17,7 @@
|
|||
class display;
|
||||
class gamestatus;
|
||||
class replay;
|
||||
class combatant;
|
||||
struct combatant;
|
||||
|
||||
#include "global.hpp"
|
||||
|
||||
|
|
|
@ -405,9 +405,9 @@ struct save_info_less_time {
|
|||
}
|
||||
};
|
||||
|
||||
std::vector<save_info> get_saves_list()
|
||||
std::vector<save_info> get_saves_list(const std::string *dir)
|
||||
{
|
||||
const std::string& saves_dir = get_saves_dir();
|
||||
const std::string& saves_dir = (dir) ? *dir : get_saves_dir();
|
||||
|
||||
std::vector<std::string> saves;
|
||||
get_files_in_dir(saves_dir,&saves);
|
||||
|
|
|
@ -155,7 +155,7 @@ struct save_info {
|
|||
};
|
||||
|
||||
//function to get a list of available saves.
|
||||
std::vector<save_info> get_saves_list();
|
||||
std::vector<save_info> get_saves_list(const std::string *dir = NULL);
|
||||
|
||||
//enum WRITE_GAME_MODE { WRITE_SNAPSHOT_ONLY, WRITE_FULL_GAME };
|
||||
|
||||
|
|
|
@ -1242,7 +1242,7 @@ bool mouse_handler::attack_enemy(unit_map::iterator attacker, unit_map::iterator
|
|||
preview_panes.push_back(&attacker_preview);
|
||||
preview_panes.push_back(&defender_preview);
|
||||
|
||||
res = gui::show_dialog(*gui_,NULL,_("Attack Enemy"),
|
||||
res = gui::show_dialog2(*gui_,NULL,_("Attack Enemy"),
|
||||
_("Choose weapon:")+std::string("\n"),
|
||||
gui::OK_CANCEL,&items,&preview_panes,"",NULL,-1,NULL,NULL,-1,-1,
|
||||
NULL,&buttons);
|
||||
|
|
|
@ -27,7 +27,7 @@ SDL_Rect screen_area();
|
|||
|
||||
bool non_interactive();
|
||||
|
||||
|
||||
//which areas of the screen will be updated when the buffer is flipped?
|
||||
void update_rect(size_t x, size_t y, size_t w, size_t h);
|
||||
void update_rect(const SDL_Rect& rect);
|
||||
void update_whole_screen();
|
||||
|
|
|
@ -49,7 +49,10 @@ menu::style::~style()
|
|||
{}
|
||||
menu::imgsel_style::imgsel_style(const std::string &img_base) : img_base_(img_base),
|
||||
initialized_(false), load_failed_(false)
|
||||
{}
|
||||
{
|
||||
cell_padding_ = 0; //FIXME: why was it needed in the parent class?
|
||||
}
|
||||
|
||||
menu::imgsel_style::~imgsel_style()
|
||||
{}
|
||||
|
||||
|
@ -83,7 +86,7 @@ bool menu::imgsel_style::load_images()
|
|||
thickness_ = minimum(
|
||||
img_map_["border-top"]->h,
|
||||
img_map_["border-left"]->w);
|
||||
cell_padding_ = maximum(cell_padding_, thickness_);
|
||||
//cell_padding_ = maximum(cell_padding_, thickness_);
|
||||
|
||||
selected_rgb_ = 0x000000;
|
||||
selected_alpha_ = 0.9;
|
||||
|
|
Loading…
Add table
Reference in a new issue