2011-05-25 19:42:45 +00:00
|
|
|
// vim: et:ts=4:sw=4:sts=4:ft=js
|
|
|
|
pandora.ui.rightPanel = function() {
|
|
|
|
var that;
|
2011-06-06 15:48:11 +00:00
|
|
|
if (pandora.user.ui.section == 'site') {
|
2011-06-06 15:55:37 +00:00
|
|
|
if (pandora.user.ui.sitePage == 'home') {
|
2011-06-04 04:37:05 +00:00
|
|
|
that = pandora.ui.homePage()
|
|
|
|
.bindEvent({
|
|
|
|
resize: function(data) {
|
|
|
|
that.resize();
|
|
|
|
}
|
|
|
|
});
|
|
|
|
} else {
|
|
|
|
that = new Ox.Element()
|
|
|
|
.css({padding: '8px'});
|
2011-06-06 15:48:11 +00:00
|
|
|
pandora.api.getPage(pandora.user.ui.sitePage, function(result) {
|
2011-06-04 04:37:05 +00:00
|
|
|
that.html(result.data.body).css({overflowY: 'auto'});
|
2011-05-25 19:42:45 +00:00
|
|
|
});
|
2011-06-04 04:37:05 +00:00
|
|
|
}
|
2011-06-06 15:48:11 +00:00
|
|
|
} else if (pandora.user.ui.section == 'items') {
|
2011-05-25 19:42:45 +00:00
|
|
|
that = new Ox.SplitPanel({
|
|
|
|
elements: [
|
|
|
|
{
|
2011-06-06 15:48:11 +00:00
|
|
|
element: pandora.$ui.toolbar = pandora.ui.toolbar(),
|
2011-05-25 19:42:45 +00:00
|
|
|
size: 24
|
|
|
|
},
|
|
|
|
{
|
2011-06-06 15:48:11 +00:00
|
|
|
element: pandora.$ui.contentPanel = pandora.ui.contentPanel()
|
2011-05-25 19:42:45 +00:00
|
|
|
},
|
|
|
|
{
|
2011-06-06 15:48:11 +00:00
|
|
|
element: pandora.$ui.statusbar = pandora.ui.statusbar(),
|
2011-05-25 19:42:45 +00:00
|
|
|
size: 16
|
|
|
|
}
|
|
|
|
],
|
|
|
|
id: 'rightPanel',
|
|
|
|
orientation: 'vertical'
|
|
|
|
})
|
|
|
|
.bindEvent({
|
|
|
|
resize: function(event, data) {
|
|
|
|
//Ox.print('???? resize rightPanel', event, data)
|
2011-06-06 15:48:11 +00:00
|
|
|
if (!pandora.user.ui.item) {
|
2011-05-25 21:31:47 +00:00
|
|
|
pandora.resizeGroups(data);
|
2011-06-06 15:48:11 +00:00
|
|
|
pandora.$ui.list.size();
|
|
|
|
if (pandora.user.ui.lists[pandora.user.ui.list].listView == 'map') {
|
|
|
|
pandora.$ui.map.resizeMap();
|
2011-05-25 19:42:45 +00:00
|
|
|
}
|
|
|
|
} else {
|
2011-06-06 15:48:11 +00:00
|
|
|
pandora.$ui.browser.scrollToSelection();
|
|
|
|
pandora.user.ui.itemView == 'player' && pandora.$ui.player.options({
|
2011-05-25 19:42:45 +00:00
|
|
|
width: data
|
|
|
|
});
|
2011-06-06 15:48:11 +00:00
|
|
|
pandora.user.ui.itemView == 'timeline' && pandora.$ui.editor.options({
|
2011-05-25 19:42:45 +00:00
|
|
|
width: data
|
|
|
|
});
|
|
|
|
}
|
|
|
|
}
|
|
|
|
});
|
|
|
|
}
|
|
|
|
return that;
|
|
|
|
};
|
|
|
|
|