1
0

Fold code from xxx_menu helpers into xxx_event to match a recent API change.

This commit is contained in:
Bharat Mediratta 2009-07-29 18:00:23 -07:00
parent 2e8461c86d
commit e410a2cbd8
9 changed files with 25 additions and 45 deletions

View File

@ -17,8 +17,8 @@
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA 02110-1301, USA.
*/
class contactowner_menu_Core {
static function admin($menu, $theme) {
class contactowner_event_Core {
static function admin_menu($menu, $theme) {
$menu->get("settings_menu")
->append(Menu::factory("link")
->id("contactowner")

View File

@ -17,8 +17,8 @@
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA 02110-1301, USA.
*/
class developer_menu_Core {
static function admin($menu, $theme) {
class developer_event_Core {
static function admin_menu($menu, $theme) {
$developer_menu = Menu::factory("submenu")
->id("developer_menu")
->label(t("Developer Tools"));

View File

@ -17,8 +17,8 @@
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA 02110-1301, USA.
*/
class downloadfullsize_menu_Core {
static function photo($menu, $theme) {
class downloadfullsize_event_Core {
static function photo_menu($menu, $theme) {
if (access::can("view_full", $theme->item)) {
if (module::get_var("downloadfullsize", "fButton")) {
$downloadLink = url::site("downloadfullsize/send/$theme->item");
@ -32,7 +32,7 @@ class downloadfullsize_menu_Core {
}
}
static function admin($menu, $theme) {
static function admin_menu($menu, $theme) {
$menu->get("settings_menu")
->append(Menu::factory("link")
->id("downloadfullsize")

View File

@ -16,8 +16,8 @@
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA 02110-1301, USA.
*/
class dynamic_menu {
static function admin($menu, $theme) {
class dynamic_event_Core {
static function admin_menu($menu, $theme) {
$menu->get("content_menu")
->append(Menu::factory("link")
->id("dynamic_menu")

View File

@ -17,8 +17,8 @@
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA 02110-1301, USA.
*/
class embedlinks_menu_Core {
static function admin($menu, $theme) {
class embedlinks_event_Core {
static function admin_menu($menu, $theme) {
$menu->get("settings_menu")
->append(Menu::factory("link")
->id("embedlinks")

View File

@ -17,8 +17,8 @@
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA 02110-1301, USA.
*/
class google_analytics_menu {
static function admin($menu, $theme) {
class google_analytics_event_Core {
static function admin_menu($menu, $theme) {
$menu->get("settings_menu")
->append(Menu::factory("link")
->id("google_analytics_menu")

View File

@ -17,8 +17,8 @@
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA 02110-1301, USA.
*/
class phpmailer_menu_Core {
static function admin($menu, $theme) {
class phpmailer_event_Core {
static function admin_menu($menu, $theme) {
$menu->get("settings_menu")
->append(Menu::factory("link")
->id("phpmailer")

View File

@ -19,7 +19,7 @@
*/
class tagsmap_event_Core {
static function module_change($changes) {
// See if the Tags module is installed,
// See if the Tags module is installed,
// tell the user to install it if it isn't.
if (!module::is_active("tag") || in_array("tag", $changes->deactivate)) {
site_status::warning(
@ -31,4 +31,13 @@ class tagsmap_event_Core {
site_status::clear("tagsmap_needs_tag");
}
}
static function admin_menu($menu, $theme) {
// Add a link to the TagsMap admin page to the Content menu.
$menu->get("content_menu")
->append(Menu::factory("link")
->id("tagsmap")
->label(t("TagsMap Settings"))
->url(url::site("admin/tagsmap")));
}
}

View File

@ -1,29 +0,0 @@
<?php defined("SYSPATH") or die("No direct script access.");
/**
* Gallery - a web based photo album viewer and editor
* Copyright (C) 2000-2009 Bharat Mediratta
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or (at
* your option) any later version.
*
* This program is distributed in the hope that it will be useful, but
* WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA 02110-1301, USA.
*/
class tagsmap_menu_Core {
static function admin($menu, $theme) {
// Add a link to the TagsMap admin page to the Content menu.
$menu->get("content_menu")
->append(Menu::factory("link")
->id("tagsmap")
->label(t("TagsMap Settings"))
->url(url::site("admin/tagsmap")));
}
}