some work towards making places and events editable from annotations panel (#561)
This commit is contained in:
parent
4629d64361
commit
b77045f375
6 changed files with 11 additions and 4 deletions
|
@ -66,6 +66,7 @@ pandora.URL = (function() {
|
||||||
if (Ox.isEmpty(state)) {
|
if (Ox.isEmpty(state)) {
|
||||||
|
|
||||||
if (pandora.user.ui.showHome) {
|
if (pandora.user.ui.showHome) {
|
||||||
|
Ox.print('*** showScreen via URL')
|
||||||
pandora.$ui.home = pandora.ui.home().showScreen();
|
pandora.$ui.home = pandora.ui.home().showScreen();
|
||||||
}
|
}
|
||||||
callback && callback();
|
callback && callback();
|
||||||
|
|
|
@ -49,6 +49,7 @@ pandora.ui.appPanel = function() {
|
||||||
}
|
}
|
||||||
} else if (page == 'home') {
|
} else if (page == 'home') {
|
||||||
// if we're on page load, show screen immediately
|
// if we're on page load, show screen immediately
|
||||||
|
Ox.print('*** ' + (!pandora.$ui.appPanel ? 'showScreen' : 'fadeInScreen') + ' via appPanel')
|
||||||
pandora.$ui.home = pandora.ui.home()[
|
pandora.$ui.home = pandora.ui.home()[
|
||||||
!pandora.$ui.appPanel ? 'showScreen' : 'fadeInScreen'
|
!pandora.$ui.appPanel ? 'showScreen' : 'fadeInScreen'
|
||||||
]();
|
]();
|
||||||
|
|
|
@ -2,7 +2,8 @@
|
||||||
|
|
||||||
'use strict';
|
'use strict';
|
||||||
|
|
||||||
pandora.ui.eventsDialog = function() {
|
pandora.ui.eventsDialog = function(options) {
|
||||||
|
// options can be {id: '...'} or {name: '...'}
|
||||||
var height = Math.round((window.innerHeight - 48) * 0.9),
|
var height = Math.round((window.innerHeight - 48) * 0.9),
|
||||||
width = Math.round(window.innerWidth * 0.9),
|
width = Math.round(window.innerWidth * 0.9),
|
||||||
that = Ox.Dialog({
|
that = Ox.Dialog({
|
||||||
|
@ -93,6 +94,7 @@ pandora.ui.eventsDialog = function() {
|
||||||
callback(result);
|
callback(result);
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
selected: options ? options.id : '',
|
||||||
showControls: pandora.user.ui.showCalendarControls,
|
showControls: pandora.user.ui.showCalendarControls,
|
||||||
width: width
|
width: width
|
||||||
})
|
})
|
||||||
|
|
|
@ -585,7 +585,7 @@ pandora.ui.home = function() {
|
||||||
return that;
|
return that;
|
||||||
};
|
};
|
||||||
|
|
||||||
that.showScreen = function() {
|
that.showScreen = function(callback) {
|
||||||
that.css({opacity: 1}).appendTo(Ox.UI.$body);
|
that.css({opacity: 1}).appendTo(Ox.UI.$body);
|
||||||
$box.css({marginTop: '80px'});
|
$box.css({marginTop: '80px'});
|
||||||
that.find('*').css({opacity: 1});
|
that.find('*').css({opacity: 1});
|
||||||
|
@ -600,6 +600,7 @@ pandora.ui.home = function() {
|
||||||
});
|
});
|
||||||
}, 250);
|
}, 250);
|
||||||
*/
|
*/
|
||||||
|
callback && callback();
|
||||||
return that;
|
return that;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -339,8 +339,9 @@ pandora.ui.item = function() {
|
||||||
pandora.UI.set({annotationsSort: data.sort});
|
pandora.UI.set({annotationsSort: data.sort});
|
||||||
},
|
},
|
||||||
define: function(data) {
|
define: function(data) {
|
||||||
pandora.$ui.placesDialog && pandora.$ui.placesDialog.remove();
|
var dialog = data.type + 'sDialog';
|
||||||
pandora.$ui.placesDialog = pandora.ui.placesDialog(data).open();
|
pandora.$ui[dialog] && pandora.$ui[dialog].remove();
|
||||||
|
pandora.$ui[dialog] = pandora.ui[dialog](data).open();
|
||||||
},
|
},
|
||||||
downloadvideo: function(data) {
|
downloadvideo: function(data) {
|
||||||
document.location.href = '/' + pandora.user.ui.item + '/torrent/';
|
document.location.href = '/' + pandora.user.ui.item + '/torrent/';
|
||||||
|
|
|
@ -4,6 +4,7 @@
|
||||||
|
|
||||||
pandora.ui.placesDialog = function(options) {
|
pandora.ui.placesDialog = function(options) {
|
||||||
// options can be {id: '...'} or {name: '...'}
|
// options can be {id: '...'} or {name: '...'}
|
||||||
|
Ox.print('placesDialog', options);
|
||||||
var height = Math.round((window.innerHeight - 48) * 0.9),
|
var height = Math.round((window.innerHeight - 48) * 0.9),
|
||||||
width = Math.round(window.innerWidth * 0.9),
|
width = Math.round(window.innerWidth * 0.9),
|
||||||
$content = Ox.ListMap({
|
$content = Ox.ListMap({
|
||||||
|
|
Loading…
Reference in a new issue