summaryrefslogtreecommitdiff
path: root/modules/system/system.module
diff options
context:
space:
mode:
authorGábor Hojtsy <gabor@hojtsy.hu>2007-10-04 18:51:04 +0000
committerGábor Hojtsy <gabor@hojtsy.hu>2007-10-04 18:51:04 +0000
commit560bd06f3b78f8ecd49a2b66acce06cb627d9027 (patch)
treedc94b06d81e53a2ed0cdf26ca449f7901ae21f9f /modules/system/system.module
parent5e771fa917f16acbcdce96f69d0f0af634eacbe2 (diff)
downloadbrdo-560bd06f3b78f8ecd49a2b66acce06cb627d9027.tar.gz
brdo-560bd06f3b78f8ecd49a2b66acce06cb627d9027.tar.bz2
#178973 by merlinofchaos: proper style and script inheritance between themes more then two levels deep in the hierarchy
Diffstat (limited to 'modules/system/system.module')
-rw-r--r--modules/system/system.module24
1 files changed, 1 insertions, 23 deletions
diff --git a/modules/system/system.module b/modules/system/system.module
index 65d6219b8..8827857e8 100644
--- a/modules/system/system.module
+++ b/modules/system/system.module
@@ -742,28 +742,6 @@ function system_theme_data() {
$themes[$key]->prefix = $key;
}
}
- // Add any stylesheets from the base theme, unless the names match in which case
- // the sub-theme wins. Note that we slip the base theme's stylesheets in at the
- // beginning of the array so that they get added to the page in the correct order.
- foreach ($themes[$base_key]->info['stylesheets'] as $media => $stylesheets) {
- foreach ($stylesheets as $stylesheet => $path) {
- if (!isset($themes[$key]->info['stylesheets'][$media][$stylesheet])) {
- // We need to ensure the media array exists, or the array addition below doesn't work.
- if (!isset($themes[$key]->info['stylesheets'][$media])) {
- $themes[$key]->info['stylesheets'][$media] = array();
- }
- $themes[$key]->info['stylesheets'][$media] = array($stylesheet => $path) + $themes[$key]->info['stylesheets'][$media];
- }
- }
- }
- // Add any scripts from the base theme, unless the names match in which case
- // the sub-theme wins. Note that we slip the base theme's scripts in at the
- // beginning of the array so that they get added to the page in the correct order.
- foreach ($themes[$base_key]->info['scripts'] as $script => $path) {
- if (!isset($themes[$key]->info['scripts'][$script])) {
- $themes[$key]->info['scripts'] = array($script => $path) + $themes[$key]->info['scripts'];
- }
- }
}
// Extract current files from database.
@@ -798,7 +776,7 @@ function system_find_base_theme($themes, $key, $used_keys = array()) {
// Is the base theme itself a child of another theme?
if (isset($themes[$base_key]->info['base theme'])) {
// Prevent loops.
- if ($used_keys[$base_key]) {
+ if (!empty($used_keys[$base_key])) {
return NULL;
}
$used_keys[$base_key] = TRUE;