diff options
author | Nathan Kinkade <nkinkade@nkinka.de> | 2010-12-06 16:14:26 +0000 |
---|---|---|
committer | Nathan Kinkade <nkinkade@nkinka.de> | 2010-12-06 16:14:26 +0000 |
commit | cf1965957c48b1c88a3913f8167688d03d191cec (patch) | |
tree | 9da9e719c68f4428771c9b70389b93f7a1bafd26 /modules/gallery/helpers/block_manager.php | |
parent | 1659e487a26ef0460926376b7b8b40aaba0c0577 (diff) | |
parent | c3ef8921260db8e39b6d2a7b4708e3d19f35f8b5 (diff) |
Merge branch 'master' of git://github.com/gallery/gallery3
Diffstat (limited to 'modules/gallery/helpers/block_manager.php')
-rw-r--r-- | modules/gallery/helpers/block_manager.php | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/modules/gallery/helpers/block_manager.php b/modules/gallery/helpers/block_manager.php index 4dcd6c32..2237b702 100644 --- a/modules/gallery/helpers/block_manager.php +++ b/modules/gallery/helpers/block_manager.php @@ -27,10 +27,10 @@ class block_manager_Core { } static function add($location, $module_name, $block_id) { - $blocks = self::get_active($location); + $blocks = block_manager::get_active($location); $blocks[rand()] = array($module_name, $block_id); - self::set_active($location, $blocks); + block_manager::set_active($location, $blocks); } static function activate_blocks($module_name) { @@ -38,25 +38,25 @@ class block_manager_Core { if (method_exists($block_class, "get_site_list")) { $blocks = call_user_func(array($block_class, "get_site_list")); foreach (array_keys($blocks) as $block_id) { - self::add("site_sidebar", $module_name, $block_id); + block_manager::add("site_sidebar", $module_name, $block_id); } } } static function remove($location, $block_id) { - $blocks = self::get_active($location); + $blocks = block_manager::get_active($location); unset($blocks[$block_id]); - self::set_active($location, $blocks); + block_manager::set_active($location, $blocks); } static function remove_blocks_for_module($location, $module_name) { - $blocks = self::get_active($location); + $blocks = block_manager::get_active($location); foreach ($blocks as $key => $block) { if ($block[0] == $module_name) { unset($blocks[$key]); } } - self::set_active($location, $blocks); + block_manager::set_active($location, $blocks); } static function deactivate_blocks($module_name) { @@ -64,14 +64,14 @@ class block_manager_Core { if (method_exists($block_class, "get_site_list")) { $blocks = call_user_func(array($block_class, "get_site_list")); foreach (array_keys($blocks) as $block_id) { - self::remove_blocks_for_module("site_sidebar", $module_name); + block_manager::remove_blocks_for_module("site_sidebar", $module_name); } } if (method_exists($block_class, "get_admin_list")) { $blocks = call_user_func(array($block_class, "get_admin_list")); foreach (array("dashboard_sidebar", "dashboard_center") as $location) { - self::remove_blocks_for_module($location, $module_name); + block_manager::remove_blocks_for_module($location, $module_name); } } } @@ -99,7 +99,7 @@ class block_manager_Core { } static function get_html($location, $theme=null) { - $active = self::get_active($location); + $active = block_manager::get_active($location); $result = ""; foreach ($active as $id => $desc) { if (method_exists("$desc[0]_block", "get")) { |