mirror of
https://github.com/wesnoth/wesnoth
synced 2025-05-11 20:39:06 +00:00
Render the palette scroll buttons inactive when appropriate.
This commit is contained in:
parent
0cc310f0ea
commit
89b8ce67be
@ -255,6 +255,12 @@ void editor_palette<Item>::draw(bool)
|
|||||||
if(ending > num_items() ){
|
if(ending > num_items() ){
|
||||||
ending = num_items();
|
ending = num_items();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
gui::button* upscroll_button = gui_.find_button("upscroll-button-editor");
|
||||||
|
upscroll_button->enable(starting != 0);
|
||||||
|
gui::button* downscroll_button = gui_.find_button("downscroll-button-editor");
|
||||||
|
downscroll_button->enable(ending != num_items());
|
||||||
|
|
||||||
for(unsigned int counter = starting; counter < ending; counter++){
|
for(unsigned int counter = starting; counter < ending; counter++){
|
||||||
|
|
||||||
const int counter_from_zero = counter - starting;
|
const int counter_from_zero = counter - starting;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user