mirror of
https://github.com/lxsang/antos-frontend.git
synced 2025-07-27 11:19:47 +02:00
afx-list-view now can add action buttons
This commit is contained in:
@ -7,7 +7,18 @@ class AppearanceHandler extends SettingHandler
|
||||
@wpsize = @find "wpsize"
|
||||
@wprepeat = @find "wprepeat"
|
||||
@themelist = @find "theme-list"
|
||||
@wpsize.set "onlistselect", (e)->
|
||||
|
||||
@wplist.set "onlistselect", (e) ->
|
||||
$(me.wpreview).css("background-image", "url(#{me.parent._api.handler.get}/#{e.data.path})" )
|
||||
.css("background-size", "cover")
|
||||
me.parent.systemsetting.appearance.wp.url = e.data.path
|
||||
me.parent._gui.wallpaper()
|
||||
|
||||
@wplist.set "buttons", [
|
||||
{ text: "+", onbtclick: (e) -> console.log "click +" }
|
||||
]
|
||||
|
||||
@wpsize.set "onlistselect", (e) ->
|
||||
me.parent.systemsetting.appearance.wp.size = e.data.text
|
||||
me.parent._gui.wallpaper()
|
||||
|
||||
@ -17,11 +28,6 @@ class AppearanceHandler extends SettingHandler
|
||||
{ text: "contain", selected: me.parent.systemsetting.appearance.wp.size is "contain" }
|
||||
]
|
||||
@wpsize.set "items", sizes
|
||||
@wplist.set "onlistselect", (e) ->
|
||||
$(me.wpreview).css("background-image", "url(#{me.parent._api.handler.get}/#{e.data.path})" )
|
||||
.css("background-size", "cover")
|
||||
me.parent.systemsetting.appearance.wp.url = e.data.path
|
||||
me.parent._gui.wallpaper()
|
||||
|
||||
|
||||
repeats = [
|
||||
|
@ -24,6 +24,7 @@ afx-app-window[data-id = "setting-window"] afx-vbox[data-id="appearance"] div[da
|
||||
afx-app-window[data-id = "setting-window"] afx-vbox[data-id="appearance"] afx-list-view[data-id="wplist"]
|
||||
{
|
||||
border:1px solid #cbcbcb;
|
||||
padding:2px;
|
||||
}
|
||||
afx-app-window[data-id = "setting-window"] afx-vbox[data-id="appearance"] afx-resizer{
|
||||
border:0;
|
||||
|
@ -7,14 +7,15 @@
|
||||
<afx-hbox>
|
||||
<afx-list-view data-width="120" data-id="wplist"></afx-list-view>
|
||||
<afx-resizer data-width="5"></afx-resizer>
|
||||
<div data-id = "wp-preview"></div>
|
||||
</afx-hbox>
|
||||
<div data-height="5"></div>
|
||||
<afx-hbox data-height="30">
|
||||
<afx-button data-width="130" text= "__(Add)"></afx-button>
|
||||
<afx-list-view data-id = "wpsize" dropdown="true"></afx-list-view>
|
||||
<div data-width="5"></div>
|
||||
<afx-list-view data-id = "wprepeat" dropdown="true"></afx-list-view>
|
||||
<afx-vbox>
|
||||
<div data-id = "wp-preview"></div>
|
||||
<div data-height="5"></div>
|
||||
<afx-hbox data-height="25">
|
||||
<afx-list-view data-id = "wpsize" dropdown="true"></afx-list-view>
|
||||
<div data-width="5"></div>
|
||||
<afx-list-view data-id = "wprepeat" dropdown="true"></afx-list-view>
|
||||
</afx-hbox>
|
||||
</afx-vbox>
|
||||
</afx-hbox>
|
||||
<div data-height="5"></div>
|
||||
<afx-label text = "__(Theme)" iconclass = "fa fa-window-restore" class = "header" data-height="23"></afx-label>
|
||||
|
Reference in New Issue
Block a user