Commit e43268b1 authored by Kate Botsman's avatar Kate Botsman Committed by intellij-monorepo-bot
Browse files

GTW-8455 Fix frame is shown too early when creating a new project

In the commit below project session creation was moved from `InitProjectActivity` to `ProjectServiceContainerInitializedListener` in order to have the valid project session as early as possible (before any components or services are loaded)
https://jetbrains.team/p/ij/repositories/ultimate/revision/8918289b326ae6f5657ed5d8ad1976edb7dfd67d

However, in case of new project creation, `ProjectServiceContainerInitializedListener`s are executed before the project is actually opened.
In monolith (standalone IDE) it's not noticeable because the frame is created much later. But in split (RD) we create the frame at the same time, we receive new project info from backend.

I partially revert changes - `ProjectAttachActivity` becomes `InitProjectActivity` again, so we can be sure that frontend receives project information only when the project is actually opened.

(cherry picked from commit be21c03ced8bf0287ec7439ce2c50a2a8e2cdd8b)

GitOrigin-RevId: bfcb159a119c6614dc4bd4ca49a00331a135bd46
parent 36b1c3fb
Branches unavailable Tags unavailable
No related merge requests found
Showing with 2 additions and 5 deletions
+2 -5
......@@ -212,6 +212,7 @@ open class StartupManagerImpl(private val project: Project, private val coroutin
&& pluginId.idString != "com.intellij.kmm"
&& pluginId.idString != "com.intellij.clion.plugin"
&& pluginId.idString != "com.jetbrains.codeWithMe"
&& pluginId.idString != "intellij.rider.plugins.cwm"
&& pluginId.idString != "org.jetbrains.plugins.clion.radler") {
LOG.error("Only bundled plugin can define ${extensionPoint.name}: ${adapter.pluginDescriptor}")
continue
......
......@@ -1260,11 +1260,7 @@ internal suspend inline fun projectInitListeners(crossinline executor: suspend (
.getExtensionPoint<ProjectServiceContainerInitializedListener>("com.intellij.projectServiceContainerInitializedListener")
for (adapter in ep.sortedAdapters) {
val pluginDescriptor = adapter.pluginDescriptor
if (!isCorePlugin(pluginDescriptor) &&
!(pluginDescriptor.pluginId.idString == "com.jetbrains.codeWithMe"
&& adapter.assignableToClassName == "com.jetbrains.rdserver.unattendedHost.UnattendedHostManager\$ProjectAttachActivity")
&& !(pluginDescriptor.pluginId.idString == "intellij.rider.plugins.cwm"
&& adapter.assignableToClassName == "com.jetbrains.rdserver.unattendedHost.UnattendedHostManager\$ProjectAttachActivity")) {
if (!isCorePlugin(pluginDescriptor)) {
LOG.error(PluginException("Plugin $pluginDescriptor is not approved to add ${ep.name}", pluginDescriptor.pluginId))
continue
}
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment