diff options
-rw-r--r-- | lib/private/app.php | 17 | ||||
-rw-r--r-- | lib/public/app.php | 3 | ||||
-rw-r--r-- | settings/admin.php | 2 | ||||
-rw-r--r-- | settings/help.php | 2 | ||||
-rw-r--r-- | settings/users.php | 2 |
5 files changed, 5 insertions, 21 deletions
diff --git a/lib/private/app.php b/lib/private/app.php index c6e235eda4d..78b039b87f0 100644 --- a/lib/private/app.php +++ b/lib/private/app.php @@ -361,23 +361,6 @@ class OC_App { } /** - * marks a navigation entry as active - * - * @param string $id id of the entry - * @return bool - * - * This function sets a navigation entry as active and removes the 'active' - * property from all other entries. The templates can use this for - * highlighting the current position of the user. - * - * @deprecated Use \OC::$server->getNavigationManager()->setActiveEntry() instead - */ - public static function setActiveNavigationEntry($id) { - OC::$server->getNavigationManager()->setActiveEntry($id); - return true; - } - - /** * gets the active Menu entry * * @return string id or empty string diff --git a/lib/public/app.php b/lib/public/app.php index c66d988c315..cc414842628 100644 --- a/lib/public/app.php +++ b/lib/public/app.php @@ -82,7 +82,8 @@ class App { * @since 4.0.0 */ public static function setActiveNavigationEntry( $id ) { - return \OC_App::setActiveNavigationEntry( $id ); + \OC::$server->getNavigationManager()->setActiveEntry($id); + return true; } /** diff --git a/settings/admin.php b/settings/admin.php index bccb1171743..ae4340cf14f 100644 --- a/settings/admin.php +++ b/settings/admin.php @@ -33,7 +33,7 @@ use OC\Lock\NoopLockingProvider; OC_Util::checkAdminUser(); -OC_App::setActiveNavigationEntry("admin"); +\OC::$server->getNavigationManager()->setActiveEntry("admin"); $template = new OC_Template('settings', 'admin', 'user'); $l = \OC::$server->getL10N('settings'); diff --git a/settings/help.php b/settings/help.php index aa89277d883..60719a3df92 100644 --- a/settings/help.php +++ b/settings/help.php @@ -30,7 +30,7 @@ OC_Util::checkLoggedIn(); // Load the files we need OC_Util::addStyle( "settings", "settings" ); -OC_App::setActiveNavigationEntry( "help" ); +\OC::$server->getNavigationManager()->setActiveEntry('help'); if(isset($_GET['mode']) and $_GET['mode'] === 'admin') { diff --git a/settings/users.php b/settings/users.php index 2795032a161..ccf1bcd9e1a 100644 --- a/settings/users.php +++ b/settings/users.php @@ -35,7 +35,7 @@ OC_Util::checkSubAdminUser(); -OC_App::setActiveNavigationEntry( 'core_users' ); +\OC::$server->getNavigationManager()->setActiveEntry('core_users'); $userManager = \OC_User::getManager(); $groupManager = \OC_Group::getManager(); |