Hilite the hovered element in the types palette.
This commit is contained in:
@@ -726,6 +726,7 @@ void set_up_type_buttons(bool reset) {
|
|||||||
|
|
||||||
// How transparent to make non-matching elements in the palette
|
// How transparent to make non-matching elements in the palette
|
||||||
static const sf::Uint8 FILTER_ALPHA = 255 / 8;
|
static const sf::Uint8 FILTER_ALPHA = 255 / 8;
|
||||||
|
location mouse = translate_mouse_coordinates(sf::Mouse::getPosition(mainPtr()));
|
||||||
|
|
||||||
// first make terrain buttons
|
// first make terrain buttons
|
||||||
sf::Texture& editor_mixed = *ResMgr::graphics.get("edbuttons");
|
sf::Texture& editor_mixed = *ResMgr::graphics.get("edbuttons");
|
||||||
@@ -925,6 +926,9 @@ void set_up_type_buttons(bool reset) {
|
|||||||
}
|
}
|
||||||
}break;
|
}break;
|
||||||
}
|
}
|
||||||
|
if(mouse.in(draw_rect)) {
|
||||||
|
fill_rect(mainPtr(), draw_rect, hilite_colour);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if(overall_mode < MODE_MAIN_SCREEN) {
|
if(overall_mode < MODE_MAIN_SCREEN) {
|
||||||
|
Reference in New Issue
Block a user