MCPcopy Create free account
hub / github.com/cogentcore/core / sortBy

Method sortBy

filetree/node.go:438–441  ·  view source on GitHub ↗

sortBy determines how to sort the files in the directory -- default is alpha by name, optionally can be sorted by modification time.

(modTime bool)

Source from the content-addressed store, hash-verified

436// sortBy determines how to sort the files in the directory -- default is alpha by name,
437// optionally can be sorted by modification time.
438func (fn *Node) sortBy(modTime bool) {
439 fn.FileRoot.setDirSortBy(fn.Filepath, modTime)
440 fn.NeedsLayout()
441}
442
443// openAll opens all directories under this one
444func (fn *Node) openAll() { //types:add

Callers 1

sortBysMethod · 0.80

Calls 2

setDirSortByMethod · 0.80
NeedsLayoutMethod · 0.45

Tested by

no test coverage detected