mirror of
https://github.com/lxsang/antos-frontend.git
synced 2024-12-26 17:38:20 +01:00
update VFS API
This commit is contained in:
parent
86a94a817a
commit
66e96cc0db
Binary file not shown.
@ -388,6 +388,7 @@ namespace OS {
|
||||
if (v.filename[0] === "." && !this.showhidden) {
|
||||
return;
|
||||
}
|
||||
if(!v.text)
|
||||
v.text = v.filename;
|
||||
if (v.text.length > 10) {
|
||||
v.text = v.text.substring(0, 9) + "...";
|
||||
@ -412,6 +413,7 @@ namespace OS {
|
||||
if (v.filename[0] === "." && !this.showhidden) {
|
||||
return;
|
||||
}
|
||||
if(!v.text)
|
||||
v.text = v.filename;
|
||||
v.iconclass = v.iconclass ? v.iconclass : v.type;
|
||||
const row = [
|
||||
@ -467,6 +469,7 @@ namespace OS {
|
||||
if (v.filename[0] === "." && !this.showhidden) {
|
||||
return undefined;
|
||||
}
|
||||
if(!v.text)
|
||||
v.text = v.filename;
|
||||
if (v.type === "dir") {
|
||||
v.nodes = [];
|
||||
|
@ -1356,11 +1356,17 @@ namespace OS {
|
||||
constructor(path: string) {
|
||||
super(path);
|
||||
if (this.basename) {
|
||||
let v: any = OS.setting.system.packages[this.basename];
|
||||
v.type = "app";
|
||||
v.mime = "antos/app";
|
||||
v.size = 0;
|
||||
this.info = v as FileInfoType;
|
||||
let v = OS.setting.system.packages[this.basename];
|
||||
this.info = {} as FileInfoType;
|
||||
for(const p in v)
|
||||
{
|
||||
this.info[p] = v[p];
|
||||
}
|
||||
|
||||
this.info.type = "app";
|
||||
this.info.mime = "antos/app";
|
||||
this.info.size = 0;
|
||||
this.info.text = v.name;
|
||||
}
|
||||
this.ready = true;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user