fix mac RTL and app termination deadlock

This commit is contained in:
2019-04-07 11:27:43 +02:00
parent 3611057f18
commit ada1afbac2
4 changed files with 13 additions and 10 deletions

View File

@@ -679,6 +679,9 @@ void App::terminate()
{
LOG("App::terminate");
NodeStrokePreview::terminate_renderer();
rec_stop();
async_start();
TextureManager::invalidate();
ShaderManager::invalidate();
layout.unload();
@@ -693,7 +696,7 @@ void App::terminate()
floating_color.reset();
floating_layers.reset();
floating_picker.reset();
rec_stop();
async_end();
}
void App::update_memory_usage(size_t bytes)
@@ -787,7 +790,9 @@ void App::rec_stop()
rec_cv.notify_all();
if (rec_thread.joinable())
rec_thread.join();
async_start();
update_rec_frames();
async_end();
}
}

View File

@@ -921,7 +921,7 @@ void App::init_menu_experimental()
};
rtl_btn->find<NodeCheckBox>("experimental-rtl-check")->on_value_changed = [this, main](Node*, bool checked)
{
auto ui = main->find("ui-root");
auto ui = main->find("central-row");
ui->SetRTL(checked ? YGDirectionRTL : YGDirectionLTR);
};
}