Skip to content
This repository was archived by the owner on Sep 6, 2021. It is now read-only.

Commit 84a7324

Browse files
committed
Merge pull request #2592 from jbalsas/followup-2085
Create files on collapsed empty folders (#2085)
2 parents 637f7e8 + 35668e7 commit 84a7324

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

src/project/ProjectManager.js

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -652,6 +652,13 @@ define(function (require, exports, module) {
652652

653653
treeNode.removeClass("jstree-leaf jstree-closed jstree-open")
654654
.addClass(classToAdd);
655+
656+
// This is a workaround for a part of issue #2085, where the file creation process
657+
// depends on the open_node.jstree event being triggered, which doesn't happen on
658+
// empty folders
659+
if (!wasNodeOpen) {
660+
treeNode.trigger("open_node.jstree");
661+
}
655662
}
656663
},
657664
function (error) {

0 commit comments

Comments
 (0)