MCPcopy Create free account
hub / github.com/PerroEngine/Perro / sort_key

Function sort_key

perro_editor/res/scripts/assets/editor_files.rs:3–6  ·  view source on GitHub ↗
(path: &str)

Source from the content-addressed store, hash-verified

1use std::path::Path;
2
3pub fn sort_key(path: &str) -> (u8, String) {
4 let folder = path.ends_with('/');
5 ((!folder) as u8, rel_label(path).to_ascii_lowercase())
6}
7
8pub fn res_browser_sort_key(path: &str) -> String {
9 let label = rel_label(path).to_ascii_lowercase();

Callers

nothing calls this directly

Calls 1

rel_labelFunction · 0.85

Tested by

no test coverage detected