Skip to content
Snippets Groups Projects
Commit 8b64daac authored by Demian Katz's avatar Demian Katz
Browse files

Use CamelCase service name for future ServiceManager v3 compatibility.

parent b9e2fd46
No related merge requests found
......@@ -179,7 +179,7 @@ class Bootstrapper
{
$callback = function ($event) {
$serviceManager = $event->getApplication()->getServiceManager();
$viewModel = $serviceManager->get('viewmanager')->getViewModel();
$viewModel = $serviceManager->get('ViewManager')->getViewModel();
// Grab the template name from the first child -- we can use this to
// figure out the current template context.
......@@ -352,7 +352,7 @@ class Bootstrapper
}
}
// Send key values to view:
$viewModel = $sm->get('viewmanager')->getViewModel();
$viewModel = $sm->get('ViewManager')->getViewModel();
$viewModel->setVariable('userLang', $language);
$viewModel->setVariable('allLangs', $config->Languages);
$rtlLangs = isset($config->LanguageSettings->rtl_langs)
......@@ -473,7 +473,7 @@ class Bootstrapper
// a user-friendly message instead of a fatal error.
$callback = function ($event) {
$serviceManager = $event->getApplication()->getServiceManager();
$viewModel = $serviceManager->get('viewmanager')->getViewModel();
$viewModel = $serviceManager->get('ViewManager')->getViewModel();
$viewModel->renderingError = true;
};
$this->events->attach('render.error', $callback, 10000);
......
......@@ -75,7 +75,7 @@ class Factory
// The right-to-left setting is injected into the layout by the Bootstrapper;
// pull it back out here to avoid duplicate effort, then use it to apply
// the mirror setting appropriately.
$layout = $sm->getServiceLocator()->get('viewmanager')->getViewModel();
$layout = $sm->getServiceLocator()->get('ViewManager')->getViewModel();
if ($layout->rtl && $mirror) {
$sidebarOnLeft = !$sidebarOnLeft;
}
......
......@@ -269,7 +269,7 @@ class Initializer
protected function sendThemeOptionsToView()
{
// Get access to the view model:
$viewModel = $this->serviceManager->get('viewmanager')->getViewModel();
$viewModel = $this->serviceManager->get('ViewManager')->getViewModel();
// Send down the view options:
$viewModel->setVariable('themeOptions', $this->getThemeOptions());
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment