From 96b3dd0ae373a09120b66c9d23fa58d64c7c7698 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Bartosz=20Dziewo=C5=84ski?= Date: Thu, 18 Sep 2014 13:01:33 +0200 Subject: [PATCH] Move default logo to resources/assets/ directory The problem here is that the path to 'wiki.png' is saved in users' LocalSettings. We likely should not remap the path, like we did for footer license icons in Ic7c32e56: * It's likely that users changed their logo image by overwriting the file in skins/common/. * If the normal upgrade process is followed (overwrite-uploading new files), the old file will still be there with the skins/common/ directory. * If it does cause problems, they'll be rather easy to notice and fix. On the other hand, maybe we should? * This is going to be annoying for git users. * It will bite anyone who deletes all MediaWiki files when upgrading via tarball, which is more likely with the recent skin system changes encouraging users to remove old cruft from skins/ directory. Bug: 69277 Change-Id: I175fe57048ebf9d348fb2fe67bf62cf5df389003 --- includes/DefaultSettings.php | 2 +- includes/Setup.php | 2 +- includes/installer/Installer.php | 2 +- {skins/common/images => resources/assets}/wiki.png | Bin 4 files changed, 3 insertions(+), 3 deletions(-) rename {skins/common/images => resources/assets}/wiki.png (100%) diff --git a/includes/DefaultSettings.php b/includes/DefaultSettings.php index 9ec47f2cef..b696c84a43 100644 --- a/includes/DefaultSettings.php +++ b/includes/DefaultSettings.php @@ -253,7 +253,7 @@ $wgFileCacheDirectory = false; /** * The URL path of the wiki logo. The logo size should be 135x135 pixels. - * Defaults to "{$wgStylePath}/common/images/wiki.png". + * Defaults to "$wgResourceBasePath/resources/assets/wiki.png". */ $wgLogo = false; diff --git a/includes/Setup.php b/includes/Setup.php index 253d25b21d..7a89c7a320 100644 --- a/includes/Setup.php +++ b/includes/Setup.php @@ -82,7 +82,7 @@ if ( $wgResourceBasePath === null ) { } if ( $wgLogo === false ) { - $wgLogo = "$wgStylePath/common/images/wiki.png"; + $wgLogo = "$wgResourceBasePath/resources/assets/wiki.png"; } if ( $wgUploadPath === false ) { diff --git a/includes/installer/Installer.php b/includes/installer/Installer.php index f84ed0005d..86c36518ac 100644 --- a/includes/installer/Installer.php +++ b/includes/installer/Installer.php @@ -225,7 +225,7 @@ abstract class Installer { // $wgLogo is probably wrong (bug 48084); set something that will work. // Single quotes work fine here, as LocalSettingsGenerator outputs this unescaped. - 'wgLogo' => '$wgStylePath/common/images/wiki.png', + 'wgLogo' => '$wgScriptPath/resources/assets/wiki.png', ); /** diff --git a/skins/common/images/wiki.png b/resources/assets/wiki.png similarity index 100% rename from skins/common/images/wiki.png rename to resources/assets/wiki.png -- 2.20.1