mirror of
https://github.com/RGBCube/serenity
synced 2025-07-27 00:37:45 +00:00
GameOfLife: Clear the selected pattern when the game starts running
This commit is contained in:
parent
4b48757586
commit
6eaae726fa
1 changed files with 6 additions and 0 deletions
|
@ -78,6 +78,12 @@ void BoardWidget::set_running(bool running)
|
|||
if (running == m_running)
|
||||
return;
|
||||
|
||||
if (m_selected_pattern) {
|
||||
m_selected_pattern = nullptr;
|
||||
if (on_pattern_selection_state_change)
|
||||
on_pattern_selection_state_change();
|
||||
}
|
||||
|
||||
m_running = running;
|
||||
|
||||
if (m_running) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue