mirror of https://github.com/sbt/sbt.git
Merge pull request #4436 from eatkins/unload-view
Close the current global file tree view on unload
This commit is contained in:
commit
edd0c34186
|
|
@ -883,7 +883,7 @@ object BuiltinCommands {
|
||||||
val (_, config: FileTreeViewConfig) = extracted.runTask(Keys.fileTreeViewConfig, s)
|
val (_, config: FileTreeViewConfig) = extracted.runTask(Keys.fileTreeViewConfig, s)
|
||||||
val view: FileTreeDataView[StampedFile] = config.newDataView()
|
val view: FileTreeDataView[StampedFile] = config.newDataView()
|
||||||
val newState = s.addExitHook {
|
val newState = s.addExitHook {
|
||||||
view.close()
|
s.get(BasicKeys.globalFileTreeView).foreach(_.close())
|
||||||
s.attributes.remove(BasicKeys.globalFileTreeView)
|
s.attributes.remove(BasicKeys.globalFileTreeView)
|
||||||
()
|
()
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue