mirror of
https://github.com/godotengine/godot.git
synced 2024-11-27 22:53:01 +00:00
Tree: Don't draw selection background of individual cells in Row mode
This commit is contained in:
parent
3e0e84a54c
commit
6486d261aa
@ -1844,15 +1844,16 @@ int Tree::draw_item(const Point2i &p_pos, const Point2 &p_draw_ofs, const Size2
|
||||
|
||||
p_item->set_meta("__focus_rect", Rect2(r.position, r.size));
|
||||
|
||||
if (rtl) {
|
||||
r.position.x = get_size().width - r.position.x - r.size.x;
|
||||
}
|
||||
|
||||
if (p_item->cells[i].selected) {
|
||||
if (has_focus()) {
|
||||
cache.selected_focus->draw(ci, r);
|
||||
} else {
|
||||
cache.selected->draw(ci, r);
|
||||
if (select_mode != SELECT_ROW) {
|
||||
if (rtl) {
|
||||
r.position.x = get_size().width - r.position.x - r.size.x;
|
||||
}
|
||||
if (p_item->cells[i].selected) {
|
||||
if (has_focus()) {
|
||||
cache.selected_focus->draw(ci, r);
|
||||
} else {
|
||||
cache.selected->draw(ci, r);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user