add menu item to toggle icon size

This commit is contained in:
j 2020-09-29 11:03:39 +02:00
parent f13f7d238c
commit ac8c01ee98

View file

@ -44,6 +44,12 @@ pandora.ui.infoView = function(data, isMixed) {
$options = Ox.MenuButton({ $options = Ox.MenuButton({
items: [ items: [
{
id: 'toggle',
title: Ox._('Toggle {0} size...', [
Ox._(ui.icons == 'posters' ? 'poster' : 'icon')
]),
},
{ {
id: 'delete', id: 'delete',
title: Ox._('Delete {0}...', [pandora.site.itemName.singular]), title: Ox._('Delete {0}...', [pandora.site.itemName.singular]),
@ -62,7 +68,9 @@ pandora.ui.infoView = function(data, isMixed) {
}) })
.bindEvent({ .bindEvent({
click: function(data_) { click: function(data_) {
if (data_.id == 'delete') { if (data_.id == 'toggle') {
toggleIconSize()
} else if (data_.id == 'delete') {
pandora.$ui.deleteItemsDialog = pandora.ui.deleteItemsDialog({ pandora.$ui.deleteItemsDialog = pandora.ui.deleteItemsDialog({
items: [data] items: [data]
}).open(); }).open();