english/administrator/components/com_menus/views/items/view.html.php
/**
	 * Add the page title and toolbar.
	 *
	 * @since	1.6
	 */
Add the page title and toolbar.
Add the page title and toolbar .
protected function addToolbar()
	{
		require_once JPATH_COMPONENT.'/helpers/menus.php';
		$canDo	= MenusHelper::getActions($this->state->get('filter.parent_id'));
		JToolBarHelper::title(JText::_('COM_MENUS_VIEW_ITEMS_TITLE'), 'menumgr.png');
		if ($canDo->get('core.create')) {
			JToolBarHelper::addNew('item.add');
		}
		if ($canDo->get('core.edit')) {
			JToolBarHelper::editList('item.edit');
		}
		if ($canDo->get('core.edit.state')) {
			JToolBarHelper::divider();
			JToolBarHelper::publish('items.publish', 'JTOOLBAR_PUBLISH', true);
			JToolBarHelper::unpublish('items.unpublish', 'JTOOLBAR_UNPUBLISH', true);
		}
		if (JFactory::getUser()->authorise('core.admin')) {
			JToolBarHelper::divider();
			JToolBarHelper::checkin('items.checkin', 'JTOOLBAR_CHECKIN', true);
		}
		if ($canDo->get('core.edit.state')) {
			JToolBarHelper::trash('items.trash');
		}
		if ($this->state->get('filter.published') == -2 && $canDo->get('core.delete')) {
			JToolBarHelper::deleteList('', 'items.delete', 'JTOOLBAR_EMPTY_TRASH');
		}
		if ($canDo->get('core.edit.state')) {
			JToolBarHelper::makeDefault('items.setDefault', 'COM_MENUS_TOOLBAR_SET_HOME');
			JToolBarHelper::divider();
		}
		if (JFactory::getUser()->authorise('core.admin')) {
			JToolBarHelper::custom('items.rebuild', 'refresh.png', 'refresh_f2.png', 'JToolbar_Rebuild', false);
			JToolBarHelper::divider();
		}
		JToolBarHelper::help('JHELP_MENUS_MENU_ITEM_MANAGER');
	}
protected function addToolbar ( ) { require_once JPATH_COMPONENT . '/helpers/menus.php' ; $ canDo = MenusHelper :: getActions ( $ this -> state -> get ( 'filter.parent_id' ) ) ; JToolBarHelper :: title ( JText :: _ ( 'COM_MENUS_VIEW_ITEMS_TITLE' ) , 'menumgr.png' ) ; if ( $ canDo -> get ( 'core.create' ) ) { JToolBarHelper :: addNew ( 'item.add' ) ; } if ( $ canDo -> get ( 'core.edit' ) ) { JToolBarHelper :: editList ( 'item.edit' ) ; } if ( $ canDo -> get ( 'core.edit.state' ) ) { JToolBarHelper :: divider ( ) ; JToolBarHelper :: publish ( 'items.publish' , 'JTOOLBAR_PUBLISH' , true ) ; JToolBarHelper :: unpublish ( 'items.unpublish' , 'JTOOLBAR_UNPUBLISH' , true ) ; } if ( JFactory :: getUser ( ) -> authorise ( 'core.admin' ) ) { JToolBarHelper :: divider ( ) ; JToolBarHelper :: checkin ( 'items.checkin' , 'JTOOLBAR_CHECKIN' , true ) ; } if ( $ canDo -> get ( 'core.edit.state' ) ) { JToolBarHelper :: trash ( 'items.trash' ) ; } if ( $ this -> state -> get ( 'filter.published' ) == - 2 && $ canDo -> get ( 'core.delete' ) ) { JToolBarHelper :: deleteList ( '' , 'items.delete' , 'JTOOLBAR_EMPTY_TRASH' ) ; } if ( $ canDo -> get ( 'core.edit.state' ) ) { JToolBarHelper :: makeDefault ( 'items.setDefault' , 'COM_MENUS_TOOLBAR_SET_HOME' ) ; JToolBarHelper :: divider ( ) ; } if ( JFactory :: getUser ( ) -> authorise ( 'core.admin' ) ) { JToolBarHelper :: custom ( 'items.rebuild' , 'refresh.png' , 'refresh_f2.png' , 'JToolbar_Rebuild' , false ) ; JToolBarHelper :: divider ( ) ; } JToolBarHelper :: help ( 'JHELP_MENUS_MENU_ITEM_MANAGER' ) ; }
Add the page title and toolbar.
Add the page title and toolbar .