Open Media Library
This commit is contained in:
commit
2ee2bc178a
228 changed files with 85988 additions and 0 deletions
29
static/js/listViewButtons.js
Normal file
29
static/js/listViewButtons.js
Normal file
|
|
@ -0,0 +1,29 @@
|
|||
'use strict';
|
||||
|
||||
oml.ui.listViewButtons = function() {
|
||||
|
||||
var ui = oml.user.ui,
|
||||
|
||||
that = Ox.ButtonGroup({
|
||||
buttons: oml.config.listViews.map(function(view) {
|
||||
return Ox.extend({
|
||||
tooltip: Ox._('View as') + ' ' + view.title
|
||||
}, view);
|
||||
}),
|
||||
selectable: true,
|
||||
style: 'squared',
|
||||
type: 'image',
|
||||
value: ui.listView
|
||||
}).css({
|
||||
float: 'left',
|
||||
margin: '4px 2px'
|
||||
})
|
||||
.bindEvent({
|
||||
change: function(data) {
|
||||
oml.UI.set({listView: data.value});
|
||||
}
|
||||
});
|
||||
|
||||
return that;
|
||||
|
||||
};
|
||||
Loading…
Add table
Add a link
Reference in a new issue