mirror of
https://github.com/lxsang/antos-frontend.git
synced 2025-07-27 03:09:45 +02:00
add tree view
This commit is contained in:
@ -3,7 +3,7 @@
|
||||
<afx-tree-view data-id="mytree"> </afx-tree-view>
|
||||
<afx-hbox>
|
||||
<afx-button data-height="30" text="Read more" iconclass="fa fa-camera-retro fa-lg" id="button"></afx-button>
|
||||
<afx-switch data-height="30"></afx-switch>
|
||||
<afx-switch enable= true data-height="30"></afx-switch>
|
||||
<afx-calendar-view></afx-calendar-view>
|
||||
<afx-color-picker></afx-color-picker>
|
||||
<afx-list-view data-id = "mylist" dropdown = "true" width="200" data-height = "40"></afx-list-view>
|
||||
|
@ -11,8 +11,10 @@ class Files extends this.OS.GUI.BaseApplication
|
||||
m.show(e)
|
||||
@on "fileselect", (d) -> console.log d
|
||||
#load home directory
|
||||
@_api.VFS.scandir 'home:///',
|
||||
p = 'home:///'
|
||||
@_api.VFS.scandir p,
|
||||
(d) ->
|
||||
me.view.set "path", p
|
||||
me.view.set "data", d.result
|
||||
, (e, s) ->
|
||||
alert "cannot open dir"
|
||||
@ -46,9 +48,9 @@ class Files extends this.OS.GUI.BaseApplication
|
||||
{ text: "Navigation bar", dataid: "#{@name}-nav" },
|
||||
{ text: "Hidden files", dataid: "#{@name}-hidden" },
|
||||
{ text: "Type", child: [
|
||||
{ text: "Icon view", dataid: "#{@name}-icon", type: 'icon' },
|
||||
{ text: "List view", dataid: "#{@name}-list", type: 'list' },
|
||||
{ text: "Tree view", dataid: "#{@name}-tree", type: 'tree' }
|
||||
{ text: "Icon view", radio: true, dataid: "#{@name}-icon", type: 'icon' },
|
||||
{ text: "List view", radio:true, checked: true, dataid: "#{@name}-list", type: 'list' },
|
||||
{ text: "Tree view", radio:true, dataid: "#{@name}-tree", type: 'tree' }
|
||||
], onmenuselect: (e) ->
|
||||
me.view.set 'view', e.item.data.type
|
||||
},
|
||||
|
Reference in New Issue
Block a user