move top-level navigation to default local navigation

This commit is contained in:
Evan Prodromou 2011-03-01 06:30:51 -05:00
parent dba2aaa59f
commit 7d77bdcc48
2 changed files with 3 additions and 23 deletions

View File

@ -637,7 +637,8 @@ class Action extends HTMLOutputter // lawsuit
*/ */
function showLocalNav() function showLocalNav()
{ {
// does nothing by default $nav = new DefaultLocalNav($this);
$nav->show();
} }
/** /**

View File

@ -54,23 +54,6 @@ class PrimaryNav extends Menu
'id' => 'site_nav_global_primary')); 'id' => 'site_nav_global_primary'));
if (Event::handle('StartPrimaryNav', array($this->action))) { if (Event::handle('StartPrimaryNav', array($this->action))) {
if (!empty($user)) { if (!empty($user)) {
$this->action->menuItem(common_local_url('all',
array('nickname' => $user->nickname)),
_m('Home'),
_m('Friends timeline'),
false,
'nav_home');
$this->action->menuItem(common_local_url('showstream',
array('nickname' => $user->nickname)),
_m('Profile'),
_m('Your profile'),
false,
'nav_profile');
$this->action->menuItem(common_local_url('public'),
_m('Public'),
_m('Everyone on this site'),
false,
'nav_public');
$this->action->menuItem(common_local_url('profilesettings'), $this->action->menuItem(common_local_url('profilesettings'),
_m('Settings'), _m('Settings'),
_m('Change your personal settings'), _m('Change your personal settings'),
@ -89,11 +72,6 @@ class PrimaryNav extends Menu
false, false,
'nav_logout'); 'nav_logout');
} else { } else {
$this->action->menuItem(common_local_url('public'),
_m('Public'),
_m('Everyone on this site'),
false,
'nav_public');
$this->action->menuItem(common_local_url('login'), $this->action->menuItem(common_local_url('login'),
_m('Login'), _m('Login'),
_m('Login to the site'), _m('Login to the site'),
@ -111,6 +89,7 @@ class PrimaryNav extends Menu
Event::handle('EndPrimaryNav', array($this->action)); Event::handle('EndPrimaryNav', array($this->action));
} }
$this->action->elementEnd('ul'); $this->action->elementEnd('ul');
} }
} }