PixelPaint: Always change cursor when active tool is set

Previously, if you used one of the keyboard shortcuts to select a
different tool, it didn't change the cursor to the corresponding
one till you clicked somewhere / did something else to trigger an
update. This was pretty jarring since there's no indication as to
whether the tool change was successful or not.

This patch just calls `set_override_cursor()` when a valid active
tool is set to immediately update it.
This commit is contained in:
Mustafa Quraish 2021-08-27 23:24:38 -04:00 committed by Linus Groh
parent 01b38ffc9a
commit 5a8ac56fb9
Notes: sideshowbarker 2024-07-18 05:11:19 +09:00

View File

@ -318,6 +318,7 @@ void ImageEditor::set_active_tool(Tool* tool)
m_active_tool->setup(*this);
m_active_tool->on_tool_activation();
m_active_cursor = m_active_tool->cursor();
set_override_cursor(m_active_cursor);
}
}