From: Evan Prodromou Date: Tue, 1 Mar 2011 11:00:03 +0000 (-0500) Subject: all nav menus use menu superclass X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=a64c6c501555bc70ef617ecb8c4a21b6e1f91518;p=quix0rs-gnu-social.git all nav menus use menu superclass --- diff --git a/lib/groupnav.php b/lib/groupnav.php index ee988d0a98..a2dd6eac00 100644 --- a/lib/groupnav.php +++ b/lib/groupnav.php @@ -49,9 +49,8 @@ require_once INSTALLDIR.'/lib/widget.php'; * @see HTMLOutputter */ -class GroupNav extends Widget +class GroupNav extends Menu { - var $action = null; var $group = null; /** @@ -63,7 +62,6 @@ class GroupNav extends Widget function __construct($action=null, $group=null) { parent::__construct($action); - $this->action = $action; $this->group = $group; } diff --git a/lib/logingroupnav.php b/lib/logingroupnav.php index a309e7320f..3c67f76322 100644 --- a/lib/logingroupnav.php +++ b/lib/logingroupnav.php @@ -44,21 +44,8 @@ require_once INSTALLDIR.'/lib/widget.php'; * * @see Widget */ -class LoginGroupNav extends Widget +class LoginGroupNav extends Menu { - var $action = null; - - /** - * Construction - * - * @param Action $action current action, used for output - */ - function __construct($action=null) - { - parent::__construct($action); - $this->action = $action; - } - /** * Show the menu * diff --git a/lib/personalgroupnav.php b/lib/personalgroupnav.php index 72d0893af7..d72a865677 100644 --- a/lib/personalgroupnav.php +++ b/lib/personalgroupnav.php @@ -2,7 +2,7 @@ /** * StatusNet, the distributed open-source microblogging tool * - * Base class for all actions (~views) + * Menu for personal group of actions * * PHP version 5 * @@ -19,11 +19,11 @@ * You should have received a copy of the GNU Affero General Public License * along with this program. If not, see . * - * @category Action + * @category Menu * @package StatusNet * @author Evan Prodromou * @author Sarven Capadisli - * @copyright 2008 StatusNet, Inc. + * @copyright 2008-2011 StatusNet, Inc. * @license http://www.fsf.org/licensing/licenses/agpl-3.0.html GNU Affero General Public License version 3.0 * @link http://status.net/ */ @@ -32,41 +32,20 @@ if (!defined('STATUSNET') && !defined('LACONICA')) { exit(1); } -require_once INSTALLDIR.'/lib/widget.php'; - /** - * Base class for all actions - * - * This is the base class for all actions in the package. An action is - * more or less a "view" in an MVC framework. - * - * Actions are responsible for extracting and validating parameters; using - * model classes to read and write to the database; and doing ouput. + * Menu for personal group of actions * - * @category Output + * @category Menu * @package StatusNet * @author Evan Prodromou * @author Sarven Capadisli + * @copyright 2008-2011 StatusNet, Inc. * @license http://www.fsf.org/licensing/licenses/agpl-3.0.html GNU Affero General Public License version 3.0 * @link http://status.net/ - * - * @see HTMLOutputter */ -class PersonalGroupNav extends Widget -{ - var $action = null; - - /** - * Construction - * - * @param Action $action current action, used for output - */ - function __construct($action=null) - { - parent::__construct($action); - $this->action = $action; - } +class PersonalGroupNav extends Menu +{ /** * Show the menu * diff --git a/lib/publicgroupnav.php b/lib/publicgroupnav.php index ae9cbdebb4..bd2ad53124 100644 --- a/lib/publicgroupnav.php +++ b/lib/publicgroupnav.php @@ -46,22 +46,8 @@ require_once INSTALLDIR.'/lib/widget.php'; * @see Widget */ -class PublicGroupNav extends Widget +class PublicGroupNav extends Menu { - var $action = null; - - /** - * Construction - * - * @param Action $action current action, used for output - */ - - function __construct($action=null) - { - parent::__construct($action); - $this->action = $action; - } - /** * Show the menu * diff --git a/lib/searchgroupnav.php b/lib/searchgroupnav.php index e843dc096c..cfe8fde353 100644 --- a/lib/searchgroupnav.php +++ b/lib/searchgroupnav.php @@ -2,7 +2,7 @@ /** * StatusNet, the distributed open-source microblogging tool * - * Menu for search actions + * Menu for search group of actions * * PHP version 5 * @@ -22,7 +22,7 @@ * @category Menu * @package StatusNet * @author Evan Prodromou - * @copyright 2008 StatusNet, Inc. + * @copyright 2008-2011 StatusNet, Inc. * @license http://www.fsf.org/licensing/licenses/agpl-3.0.html GNU Affero General Public License version 3.0 * @link http://status.net/ */ @@ -31,12 +31,10 @@ if (!defined('STATUSNET') && !defined('LACONICA')) { exit(1); } -require_once INSTALLDIR.'/lib/widget.php'; - /** * Menu for public group of actions * - * @category Output + * @category Menu * @package StatusNet * @author Evan Prodromou * @license http://www.fsf.org/licensing/licenses/agpl-3.0.html GNU Affero General Public License version 3.0 @@ -45,9 +43,8 @@ require_once INSTALLDIR.'/lib/widget.php'; * @see Widget */ -class SearchGroupNav extends Widget +class SearchGroupNav extends Menu { - var $action = null; var $q = null; /** @@ -59,7 +56,6 @@ class SearchGroupNav extends Widget function __construct($action=null, $q = null) { parent::__construct($action); - $this->action = $action; $this->q = $q; } diff --git a/lib/settingsnav.php b/lib/settingsnav.php index a73f73f86a..697e7ee46b 100644 --- a/lib/settingsnav.php +++ b/lib/settingsnav.php @@ -1,7 +1,7 @@ - * @copyright 2010 StatusNet, Inc. + * @copyright 2010,2011 StatusNet, Inc. * @license http://www.fsf.org/licensing/licenses/agpl-3.0.html AGPL 3.0 * @link http://status.net/ */ @@ -46,21 +46,8 @@ if (!defined('STATUSNET')) { * @see HTMLOutputter */ -class SettingsNav extends Widget +class SettingsNav extends Menu { - var $action = null; - - /** - * Construction - * - * @param Action $action current action, used for output - */ - function __construct($action=null) - { - parent::__construct($action); - $this->action = $action; - } - /** * Show the menu * diff --git a/lib/subgroupnav.php b/lib/subgroupnav.php index be3ba27480..ee4b0a8dff 100644 --- a/lib/subgroupnav.php +++ b/lib/subgroupnav.php @@ -22,7 +22,7 @@ * @category Subs * @package StatusNet * @author Evan Prodromou - * @copyright 2008-2009 StatusNet, Inc. + * @copyright 2008-2011 StatusNet, Inc. * @license http://www.fsf.org/licensing/licenses/agpl-3.0.html GNU Affero General Public License version 3.0 * @link http://status.net/ */ @@ -43,9 +43,8 @@ require_once INSTALLDIR.'/lib/widget.php'; * @link http://status.net/ */ -class SubGroupNav extends Widget +class SubGroupNav extends Menu { - var $action = null; var $user = null; /** @@ -57,7 +56,6 @@ class SubGroupNav extends Widget function __construct($action=null, $user=null) { parent::__construct($action); - $this->action = $action; $this->user = $user; }