summaryrefslogtreecommitdiffstats
path: root/lib/private/TemplateLayout.php
diff options
context:
space:
mode:
Diffstat (limited to 'lib/private/TemplateLayout.php')
-rw-r--r--lib/private/TemplateLayout.php9
1 files changed, 9 insertions, 0 deletions
diff --git a/lib/private/TemplateLayout.php b/lib/private/TemplateLayout.php
index 264c10f5f1b..a8c4bbb0d16 100644
--- a/lib/private/TemplateLayout.php
+++ b/lib/private/TemplateLayout.php
@@ -108,6 +108,15 @@ class TemplateLayout extends \OC_Template {
$this->assign('userAvatarVersion', $this->config->getUserValue(\OC_User::getUser(), 'avatar', 'version', 0));
}
+ // check if app menu icons should be inverted
+ try {
+ /** @var \OCA\Theming\Util $util */
+ $util = \OC::$server->query(\OCA\Theming\Util::class);
+ $this->assign('themingInvertMenu', $util->invertTextColor(\OC::$server->getThemingDefaults()->getColorPrimary()));
+ } catch (\OCP\AppFramework\QueryException $e) {
+ $this->assign('themingInvertMenu', false);
+ }
+
} else if ($renderAs == 'error') {
parent::__construct('core', 'layout.guest', '', false);
$this->assign('bodyid', 'body-login');