MDL-39871 themes RTL: Get rtlblockmanipulations from any parent
authorDamyon Wiese <damyon@moodle.com>
Tue, 27 Aug 2013 03:11:11 +0000 (11:11 +0800)
committerDamyon Wiese <damyon@moodle.com>
Tue, 27 Aug 2013 03:14:53 +0000 (11:14 +0800)
lib/outputlib.php

index 59b8cd2..8bfc1b2 100644 (file)
@@ -488,8 +488,13 @@ class theme_config {
         }
 
         // Use parent theme's "blockrtlmanipulations" if it was defined and if it was not defined on current theme.
-        if (empty($this->blockrtlmanipulations) and !empty($parent_config->blockrtlmanipulations)) {
-            $this->blockrtlmanipulations = $parent_config->blockrtlmanipulations;
+        if (empty($this->blockrtlmanipulations)) {
+            foreach ($this->parent_configs as $parent_config) {
+                if (!empty($parent_config->blockrtlmanipulations)) {
+                    $this->blockrtlmanipulations = $parent_config->blockrtlmanipulations;
+                    continue;
+                }
+            }
         }
 
         //fix arrows if needed