From 76c0c7f3a1246319242e8fff7649c1450da0f98e Mon Sep 17 00:00:00 2001 From: Bharat Mediratta Date: Tue, 27 Oct 2009 13:46:24 -0700 Subject: Change our menu building blocks to use PHP templates so that themes can override them and define their own menu formats. I worry a little bit that this approach may be too heavy since we're now doing a lot more template includes than we were before. Also, I had to change the Menu API to stop using __toString() because you can't throw exceptions from __toString() which would make it an unhappy experience for developers. --- modules/gallery/libraries/Admin_View.php | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'modules/gallery/libraries/Admin_View.php') diff --git a/modules/gallery/libraries/Admin_View.php b/modules/gallery/libraries/Admin_View.php index 6eedec0d..4cbefbbd 100644 --- a/modules/gallery/libraries/Admin_View.php +++ b/modules/gallery/libraries/Admin_View.php @@ -47,8 +47,7 @@ class Admin_View_Core extends Gallery_View { public function admin_menu() { $menu = Menu::factory("root"); module::event("admin_menu", $menu, $this); - $menu->compact(); - return $menu; + return $menu->compact()->render(); } /** -- cgit v1.2.3