openmedialibrary/static/js/mainPanel.js

34 lines
961 B
JavaScript
Raw Normal View History

2014-05-04 17:26:43 +00:00
'use strict';
oml.ui.mainPanel = function() {
var ui = oml.user.ui,
that = Ox.SplitPanel({
elements: [
{
collapsible: true,
collapsed: !ui.showSidebar,
element: oml.$ui.leftPanel = oml.ui.leftPanel(),
resizable: true,
resize: [192, 256, 320, 384],
size: ui.sidebarSize,
tooltip: Ox._('sidebar') + ' <span class="OxBright">'
2014-10-31 18:37:32 +00:00
+ Ox.SYMBOLS.shift + 'S</span>'
2014-05-04 17:26:43 +00:00
},
{
element: oml.$ui.rightPanel = oml.ui.rightPanel()
}
],
orientation: 'horizontal'
})
.bindEvent({
oml_showsidebar: function(data) {
2014-09-25 11:39:05 +00:00
data.value == that.options('elements')[0].collapsed && that.toggleElement(0);
2014-05-04 17:26:43 +00:00
}
});
return that;
2014-09-25 11:39:05 +00:00
};