All the File Browsing Related Functions and Structs are inside the FileBrowser.go file.
The Idea is to Implement a tree of sorts (At least for now) and then displaying the children of the current Node and traversing them.
This commit is contained in:
parent
c0f3b6e920
commit
0c107c3a72
11
fileBrowser.go
Normal file
11
fileBrowser.go
Normal file
@ -0,0 +1,11 @@
|
||||
package main
|
||||
|
||||
type FileNode struct{
|
||||
children [] FileNode
|
||||
path string
|
||||
parent *FileNode
|
||||
}
|
||||
|
||||
func (f *FileNode) addChildren(path string){
|
||||
f.children = append(f.children, FileNode{children: make([]FileNode, 0), path: path, parent: f})
|
||||
}
|
Loading…
Reference in New Issue
Block a user