fix mac RTL and app termination deadlock
This commit is contained in:
@@ -220,10 +220,8 @@ std::mutex task_mutex;
|
||||
|
||||
- (void)terminateGL
|
||||
{
|
||||
CGLLockContext([[self openGLContext] CGLContextObj]);
|
||||
App::I.terminate();
|
||||
CGLUnlockContext([[self openGLContext] CGLContextObj]);
|
||||
CVDisplayLinkRelease(dl);
|
||||
App::I.terminate();
|
||||
}
|
||||
|
||||
// This is the renderer output callback function
|
||||
|
||||
@@ -1634,7 +1634,7 @@ Here's a list of what's available in this release.
|
||||
</node>
|
||||
</border>
|
||||
<!-- toolbar -->
|
||||
<border id="toolbar" height="50" width="100%" pad="5" dir="row" color="0 0 0 0.6" mouse-capture="true">
|
||||
<border id="toolbar" height="50" width="100%" pad="5" dir="row" color="0 0 0 0.6" mouse-capture="true" rtl="ltr">
|
||||
<!--
|
||||
<button id="btn-open" width="50" height="100%" margin="0 5 0 0" text="Open"/>
|
||||
<button id="btn-save" width="50" height="100%" margin="0 5 0 0" text="Save"/>
|
||||
@@ -1736,17 +1736,17 @@ Here's a list of what's available in this release.
|
||||
</node>
|
||||
</border>
|
||||
|
||||
<scroll id="drop-left" color="0 0 0 .6" min-width="10" mouse-capture="true"/>
|
||||
<scroll id="drop-left" color="0 0 0 .6" min-width="10" mouse-capture="true" rtl="ltr"/>
|
||||
|
||||
<!--quick bar-->
|
||||
<node justify="center" align="center" dir="col">
|
||||
<node justify="center" align="center" dir="col" rtl="ltr">
|
||||
<panel-quick id="panel-quick"/>
|
||||
<node height="0" grow="1" max-height="50"/>
|
||||
</node>
|
||||
|
||||
<node id="floatings" color="0 0 0 1" width="1" grow="1" height="100%"/>
|
||||
<node id="floatings" color="0 0 0 1" width="1" grow="1" height="100%" rtl="ltr"/>
|
||||
|
||||
<scroll id="drop-right" color="0 0 0 .6" min-width="10" mouse-capture="true"/>
|
||||
<scroll id="drop-right" color="0 0 0 .6" min-width="10" mouse-capture="true" rtl="ltr"/>
|
||||
|
||||
<!-- timeline -->
|
||||
<!--
|
||||
|
||||
@@ -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();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -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);
|
||||
};
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user