intellij-elm icon indicating copy to clipboard operation
intellij-elm copied to clipboard

Only show Elm tool window for Elm projects

Open ajalt opened this issue 4 years ago • 2 comments

As mentioned in https://github.com/klazuka/intellij-elm/pull/716#pullrequestreview-487338467, it would be nice to only show the Elm tool window if Elm is configured in the project.

The Maven and Gradle plugins have this behavior, so it seems like it should be possible.

The gradle plugin uses the AbstractExternalSystemToolWindowFactory rather than manually configuring the tool window. That factory is designed to implement common functionality for tools windows for build systems, so it seems to be the solution.

It seems like the "external system" for gradle is being configured by the GradleProjectResolver, although I'm sure how it works. As usual, there doesn't seem to be any much on those APIs.

ajalt avatar Sep 14 '20 00:09 ajalt

Although it would be nice to be able to hide the tool window, I doubt it's worth the work of trying to figure out that system.

ajalt avatar Sep 14 '20 00:09 ajalt

Another option is just to consolidate everything into a single tool-window (at the bottom) rather than greedily showing 2!

klazuka avatar Sep 14 '20 00:09 klazuka