merge app into pandora
This commit is contained in:
parent
7081cd7544
commit
40b2ca0dff
35 changed files with 735 additions and 734 deletions
|
|
@ -43,17 +43,17 @@ pandora.URL = (function() {
|
|||
section: 'items',
|
||||
item: ''
|
||||
});
|
||||
pandora.UI.set(['lists', app.user.ui.list, 'listView'].join('|'), url);
|
||||
pandora.UI.set(['lists', pandora.user.ui.list, 'listView'].join('|'), url);
|
||||
},
|
||||
'^[0-9A-Z]': function(url) {
|
||||
var split = url.split('/'),
|
||||
item = split[0],
|
||||
view = new RegExp(
|
||||
'^(' + $.map(app.site.itemViews, function(v) {
|
||||
'^(' + $.map(pandora.site.itemViews, function(v) {
|
||||
return v.id;
|
||||
}).join('|') + ')$'
|
||||
).exec(split[1]);
|
||||
view = view ? view[0] : app.user.ui.itemView;
|
||||
view = view ? view[0] : pandora.user.ui.itemView;
|
||||
pandora.UI.set({
|
||||
section: 'items',
|
||||
item: item,
|
||||
|
|
@ -73,8 +73,8 @@ pandora.URL = (function() {
|
|||
if (arguments.length == 1) { // fixme: remove later
|
||||
url = title;
|
||||
}
|
||||
history.pushState({}, app.site.site.name + (title ? ' - ' + title : ''), '/' + url);
|
||||
old.user.ui = $.extend({}, app.user.ui); // make a clone
|
||||
history.pushState({}, pandora.site.site.name + (title ? ' - ' + title : ''), '/' + url);
|
||||
old.user.ui = $.extend({}, pandora.user.ui); // make a clone
|
||||
this.update();
|
||||
},
|
||||
|
||||
|
|
@ -95,16 +95,16 @@ pandora.URL = (function() {
|
|||
|
||||
update: function() {
|
||||
this.parse();
|
||||
if (app.user.ui.section != old.user.ui.section) {
|
||||
app.$ui.appPanel.replaceElement(1, app.$ui.mainPanel = pandora.ui.mainPanel());
|
||||
} else if (app.user.ui.sitePage != old.user.ui.sitePage) {
|
||||
app.$ui.mainPanel.replaceElement(1, app.$ui.rightPanel = pandora.ui.rightPanel());
|
||||
} else if (!app.user.ui.item || !old.user.ui.item) {
|
||||
app.$ui.mainPanel.replaceElement(1, app.$ui.rightPanel = pandora.ui.rightPanel());
|
||||
app.$ui.leftPanel.replaceElement(2, app.$ui.info = pandora.ui.info());
|
||||
if (pandora.user.ui.section != old.user.ui.section) {
|
||||
pandora.$ui.appPanel.replaceElement(1, pandora.$ui.mainPanel = pandora.ui.mainPanel());
|
||||
} else if (pandora.user.ui.sitePage != old.user.ui.sitePage) {
|
||||
pandora.$ui.mainPanel.replaceElement(1, pandora.$ui.rightPanel = pandora.ui.rightPanel());
|
||||
} else if (!pandora.user.ui.item || !old.user.ui.item) {
|
||||
pandora.$ui.mainPanel.replaceElement(1, pandora.$ui.rightPanel = pandora.ui.rightPanel());
|
||||
pandora.$ui.leftPanel.replaceElement(2, pandora.$ui.info = pandora.ui.info());
|
||||
} else {
|
||||
app.$ui.contentPanel.replaceElement(1, pandora.ui.item());
|
||||
app.$ui.leftPanel.replaceElement(2, app.$ui.info = pandora.ui.info());
|
||||
pandora.$ui.contentPanel.replaceElement(1, pandora.ui.item());
|
||||
pandora.$ui.leftPanel.replaceElement(2, pandora.$ui.info = pandora.ui.info());
|
||||
}
|
||||
if (
|
||||
old.user.ui.item &&
|
||||
|
|
@ -112,7 +112,7 @@ pandora.URL = (function() {
|
|||
) {
|
||||
pandora.UI.set(
|
||||
'videoPosition|' + old.user.ui.item,
|
||||
app.$ui[
|
||||
pandora.$ui[
|
||||
old.user.ui.itemView == 'player' ? 'player' : 'editor'
|
||||
].options('position')
|
||||
);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue