Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
B
baas-ide
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
JIRA
JIRA
Merge Requests
1
Merge Requests
1
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
guxukai
baas-ide
Commits
2b4e2019
Commit
2b4e2019
authored
Feb 02, 2018
by
yann300
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix file-explorer "nodeClick"
parent
2f56b8f3
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
6 deletions
+4
-6
file-explorer.js
src/app/files/file-explorer.js
+4
-6
No files found.
src/app/files/file-explorer.js
View file @
2b4e2019
...
...
@@ -131,15 +131,13 @@ function fileExplorer (appAPI, files) {
self
.
treeView
.
event
.
register
(
'nodeClick'
,
function
(
path
,
childrenContainer
)
{
if
(
!
childrenContainer
)
return
if
(
childrenContainer
.
style
.
display
===
'none'
)
{
childrenContainer
.
innerHTML
=
''
return
}
if
(
childrenContainer
.
style
.
display
===
'none'
)
return
files
.
resolveDirectory
(
path
,
(
error
,
fileTree
)
=>
{
if
(
error
)
console
.
error
(
error
)
if
(
!
fileTree
)
return
var
newTree
=
normalize
(
path
,
fileTree
)
self
.
treeView
.
updateNodeFromJSON
(
path
,
newTree
,
fals
e
)
self
.
treeView
.
updateNodeFromJSON
(
path
,
newTree
,
tru
e
)
})
})
...
...
@@ -275,7 +273,7 @@ function fileExplorer (appAPI, files) {
if
(
error
)
console
.
error
(
error
)
if
(
!
fileTree
)
return
fileTree
=
normalize
(
folderpath
,
fileTree
)
self
.
treeView
.
updateNodeFromJSON
(
folderpath
,
fileTree
,
fals
e
)
self
.
treeView
.
updateNodeFromJSON
(
folderpath
,
fileTree
,
tru
e
)
self
.
focusElement
=
self
.
treeView
.
labelAt
(
self
.
focusPath
)
// TODO: here we update the selected file (it applicable)
// cause we are refreshing the interface of the whole directory when there's a new file.
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment