From 7b4fea0e39be9e74e9aef13e73af9bbd2b1a6397 Mon Sep 17 00:00:00 2001 From: ArthurHoaro Date: Tue, 17 Jul 2018 13:13:26 +0200 Subject: Bunch of improvement for thumbnails integration: - add a default thumb size value (125x90px) - improve private vertical bar visual, especially with thumbnails - translations - add a sync thumbs button in tool and empty picwall page - fixes WT download mode in JSON config --- index.php | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) (limited to 'index.php') diff --git a/index.php b/index.php index 299d6d9b..ac0baf7d 100644 --- a/index.php +++ b/index.php @@ -632,6 +632,7 @@ function renderPage($conf, $pluginManager, $LINKSDB, $history, $sessionManager, $PAGE->assign($key, $value); } + $PAGE->renderPage('picwall'); exit; } @@ -1015,9 +1016,11 @@ function renderPage($conf, $pluginManager, $LINKSDB, $history, $sessionManager, $conf->set('translation.language', escape($_POST['language'])); $thumbnailsMode = extension_loaded('gd') ? $_POST['enableThumbnails'] : Thumbnailer::MODE_NONE; - if ($conf->get('thumbnails.enabled', Thumbnailer::MODE_NONE) !== Thumbnailer::MODE_NONE) { + if ($thumbnailsMode !== Thumbnailer::MODE_NONE + && $thumbnailsMode !== $conf->get('thumbnails.mode', Thumbnailer::MODE_NONE) + ) { $_SESSION['warnings'][] = t( - 'You have enabled or changed thumbnails mode. Please synchonize them.' + 'You have enabled or changed thumbnails mode. Please synchronize them.' ); } $conf->set('thumbnails.mode', $thumbnailsMode); @@ -1517,7 +1520,7 @@ function renderPage($conf, $pluginManager, $LINKSDB, $history, $sessionManager, $ids[] = $link['id']; } $PAGE->assign('ids', $ids); - $PAGE->assign('pagetitle', t('Thumbnail update') .' - '. $conf->get('general.title', 'Shaarli')); + $PAGE->assign('pagetitle', t('Thumbnails update') .' - '. $conf->get('general.title', 'Shaarli')); $PAGE->renderPage('thumbnails'); exit; } -- cgit v1.2.3