2011-07-29 18:37:11 +00:00
|
|
|
// vim: et:ts=4:sw=4:sts=4:ft=javascript
|
2011-08-17 09:29:42 +00:00
|
|
|
|
2011-05-25 19:42:45 +00:00
|
|
|
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 {
|
2011-08-17 09:29:42 +00:00
|
|
|
that = 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-06-19 17:49:25 +00:00
|
|
|
that = Ox.SplitPanel({
|
2011-05-25 19:42:45 +00:00
|
|
|
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) {
|
2011-06-06 15:48:11 +00:00
|
|
|
if (!pandora.user.ui.item) {
|
2011-08-24 06:19:34 +00:00
|
|
|
pandora.resizeGroups();
|
2011-06-06 15:48:11 +00:00
|
|
|
pandora.$ui.list.size();
|
2011-08-19 06:40:19 +00:00
|
|
|
if (pandora.user.ui.lists[pandora.user.ui.list].listView == 'timelines') {
|
|
|
|
pandora.$ui.list.options({
|
|
|
|
width: data
|
|
|
|
});
|
|
|
|
} else if (pandora.user.ui.lists[pandora.user.ui.list].listView == 'map') {
|
2011-06-06 15:48:11 +00:00
|
|
|
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;
|
|
|
|
};
|
|
|
|
|