IDEA-224868 forbid using of OSProcessHandler before CONFIGURATION_STORE_INITIALIZED - move init of TouchBarsManager after service registration

GitOrigin-RevId: 64196687f986fa569cb7b6e944f4da9c500576f8
This commit is contained in:
Vladimir Krivosheev
2019-10-16 15:34:28 +00:00
committed by intellij-monorepo-bot
parent 7405e817ab
commit f91c116e4c
@@ -159,14 +159,21 @@ private fun startApp(app: ApplicationImpl,
MacOSApplicationProvider.initApplication()
}
// ensure that TouchBarsManager is loaded before WelcomeFrame/project
// do not wait completion - it is thread safe and not required for application start
NonUrgentExecutor.getInstance().execute {
registerFuture.thenRunAsync(Runnable {
// ensure that TouchBarsManager is loaded before WelcomeFrame/project
// do not wait completion - it is thread safe and not required for application start
runActivity("mac touchbar") {
if (app.isDisposeInProgress) {
return@Runnable
}
Foundation.init()
if (!app.isDisposeInProgress) {
return@Runnable
}
TouchBarsManager.initialize()
}
}
}, NonUrgentExecutor.getInstance())
}
WeakFocusStackManager.getInstance()