Implement tindependant::set_visible_area.
This commit is contained in:
parent
332e2c9e2c
commit
fdee062a3b
2 changed files with 16 additions and 6 deletions
|
@ -299,11 +299,25 @@ void tindependant::set_origin(const tpoint& origin)
|
|||
for(size_t i = 0; i < get_item_count(); ++i) {
|
||||
|
||||
tgrid& grid = get_item(i);
|
||||
|
||||
grid.set_origin(origin);
|
||||
}
|
||||
}
|
||||
|
||||
void tindependant::set_visible_area(const SDL_Rect& area)
|
||||
{
|
||||
/*
|
||||
* Set the visible area for every item.
|
||||
*
|
||||
* @todo evaluate whether setting it only for the visible item is better
|
||||
* and what the consequences are.
|
||||
*/
|
||||
for(size_t i = 0; i < get_item_count(); ++i) {
|
||||
|
||||
tgrid& grid = get_item(i);
|
||||
grid.set_visible_area(area);
|
||||
}
|
||||
}
|
||||
|
||||
} // namespace placement
|
||||
|
||||
/***** ***** ***** ***** Select action ***** ***** ***** *****/
|
||||
|
|
|
@ -365,11 +365,7 @@ struct tindependant
|
|||
void set_origin(const tpoint& origin);
|
||||
|
||||
/** See thorizontal_list::set_visible_area(). */
|
||||
void set_visible_area(const SDL_Rect& /*area*/)
|
||||
{
|
||||
/* DO NOTHING */
|
||||
/** @todo Evaluate what we need to do here. */
|
||||
}
|
||||
void set_visible_area(const SDL_Rect& area);
|
||||
|
||||
/** See thorizontal_list::find_widget(). */
|
||||
twidget* find_widget(const tpoint&, const bool)
|
||||
|
|
Loading…
Add table
Reference in a new issue