forked from 0x2620/pandora
fix #1909 (that.resize -> that.resizeElement)
This commit is contained in:
parent
64fa66e327
commit
55bc138775
12 changed files with 15 additions and 21 deletions
|
@ -157,7 +157,7 @@ pandora.ui.contactForm = function() {
|
|||
) - 304 - Ox.UI.SCROLLBAR_SIZE, 512);
|
||||
}
|
||||
|
||||
that.resize = function() {
|
||||
that.resizeElement = function() {
|
||||
var width = getWidth();
|
||||
$form.css({width: width + 'px'});
|
||||
$form.options('items').forEach(function($input, i) {
|
||||
|
@ -169,7 +169,7 @@ pandora.ui.contactForm = function() {
|
|||
$receiptCheckbox.options({width: width - 136});
|
||||
}
|
||||
$text.css({width: width + 'px'});
|
||||
}
|
||||
};
|
||||
|
||||
return that;
|
||||
|
||||
|
|
|
@ -65,7 +65,7 @@ pandora.ui.homePage = function() {
|
|||
.html('center')
|
||||
.appendTo($center);
|
||||
|
||||
that.resize = function() {
|
||||
that.resizeElement = function() {
|
||||
var size = Ox.splitInt(window.innerWidth - pandora.user.ui.showSidebar * pandora.user.ui.sidebarSize - 1 - 64, 3);
|
||||
$left.css({width: size[0] + 'px'});
|
||||
$center.css({width: size[1] + 'px'});
|
||||
|
@ -74,7 +74,7 @@ pandora.ui.homePage = function() {
|
|||
$right.css({width: size[2] + 'px'});
|
||||
};
|
||||
|
||||
that.resize();
|
||||
that.resizeElement();
|
||||
|
||||
return that;
|
||||
|
||||
|
|
|
@ -1148,7 +1148,7 @@ pandora.ui.infoView = function(data) {
|
|||
pandora.user.level == 'admin' && $list.replaceWith($list = renderList());
|
||||
};
|
||||
|
||||
that.resize = function() {
|
||||
that.resizeElement = function() {
|
||||
var height = getHeight() + 'px';
|
||||
$data.css({height: height});
|
||||
$list && $list.css({height: height});
|
||||
|
|
|
@ -1052,8 +1052,6 @@ pandora.ui.infoView = function(data) {
|
|||
toggleIconSize();
|
||||
};
|
||||
|
||||
that.resize = Ox.noop;
|
||||
|
||||
that.bindEvent({
|
||||
pandora_icons: that.reload,
|
||||
pandora_showsiteposters: function() {
|
||||
|
|
|
@ -632,8 +632,6 @@ pandora.ui.infoView = function(data) {
|
|||
toggleIconSize();
|
||||
};
|
||||
|
||||
that.resize = Ox.noop;
|
||||
|
||||
that.bindEvent({
|
||||
pandora_icons: that.reload,
|
||||
pandora_showsiteposters: function() {
|
||||
|
|
|
@ -778,8 +778,6 @@ pandora.ui.infoView = function(data) {
|
|||
toggleIconSize();
|
||||
};
|
||||
|
||||
that.resize = Ox.noop;
|
||||
|
||||
that.bindEvent({
|
||||
pandora_icons: that.reload,
|
||||
pandora_showsiteposters: function() {
|
||||
|
|
|
@ -62,7 +62,7 @@ pandora.ui.item = function() {
|
|||
pandora.$ui.item = pandora.ui.infoView(result.data)
|
||||
.bindEvent({
|
||||
resize: function() {
|
||||
pandora.$ui.item.resize && pandora.$ui.item.resize();
|
||||
pandora.$ui.item.resizeElement && pandora.$ui.item.resizeElement();
|
||||
}
|
||||
})
|
||||
);
|
||||
|
@ -132,7 +132,7 @@ pandora.ui.item = function() {
|
|||
pandora.$ui.contentPanel.replaceElement(1,
|
||||
pandora.$ui.item = pandora.ui.PostersView().bindEvent({
|
||||
resize: function() {
|
||||
pandora.$ui.item.resize();
|
||||
pandora.$ui.item.resizeElement();
|
||||
}
|
||||
})
|
||||
);
|
||||
|
|
|
@ -189,7 +189,7 @@ pandora.ui.news = function(width, height) {
|
|||
renderList();
|
||||
}
|
||||
|
||||
that.resize = function(data) {
|
||||
that.resizeElement = function(data) {
|
||||
width = data.width;
|
||||
height = data.height;
|
||||
$left.css({width: width - 512});
|
||||
|
|
|
@ -22,9 +22,9 @@ pandora.ui.posterView = function() {
|
|||
orientation: 'horizontal'
|
||||
});
|
||||
|
||||
that.resize = function() {
|
||||
that.resizeElement = function() {
|
||||
selectedImage.url && renderPreview();
|
||||
}
|
||||
};
|
||||
|
||||
pandora.api.get({
|
||||
id: item,
|
||||
|
|
|
@ -172,9 +172,9 @@ pandora.ui.siteDialog = function(section) {
|
|||
dialogHeight = data.height;
|
||||
dialogWidth = data.width;
|
||||
if (selected == 'contact') {
|
||||
pandora.$ui.contactForm.resize();
|
||||
pandora.$ui.contactForm.resizeElement();
|
||||
} else if (selected == 'news') {
|
||||
pandora.$ui.news.resize(data);
|
||||
pandora.$ui.news.resizeElement(data);
|
||||
}
|
||||
},
|
||||
key_down: function() {
|
||||
|
|
|
@ -140,9 +140,9 @@ pandora.ui.siteDialog = function(section) {
|
|||
dialogHeight = data.height;
|
||||
dialogWidth = data.width;
|
||||
if (selected == 'contact') {
|
||||
pandora.$ui.contactForm.resize();
|
||||
pandora.$ui.contactForm.resizeElement();
|
||||
} else if (selected == 'news') {
|
||||
pandora.$ui.news.resize(data);
|
||||
pandora.$ui.news.resizeElement(data);
|
||||
}
|
||||
},
|
||||
key_down: function() {
|
||||
|
|
|
@ -1950,7 +1950,7 @@ pandora.resizeWindow = function() {
|
|||
} else {
|
||||
pandora.$ui.browser.scrollToSelection();
|
||||
if (pandora.user.ui.itemView == 'info') {
|
||||
pandora.$ui.item.resize && pandora.$ui.item.resize();
|
||||
pandora.$ui.item.resizeElement && pandora.$ui.item.resizeElement();
|
||||
} else if (pandora.user.ui.itemView == 'clips') {
|
||||
pandora.$ui.clipList.size();
|
||||
} else if (pandora.user.ui.itemView == 'timeline') {
|
||||
|
|
Loading…
Reference in a new issue