summaryrefslogtreecommitdiff
path: root/modules/gallery/views
diff options
context:
space:
mode:
authorBharat Mediratta <bharat@menalto.com>2009-10-27 14:00:32 -0700
committerBharat Mediratta <bharat@menalto.com>2009-10-27 14:00:32 -0700
commit13faf6035d726f8a77b7dcac7e8e8fa3b24bfaf2 (patch)
treec458a11bbe520834ffd20ffe9ccc35e30152a458 /modules/gallery/views
parent3b66ea3c3a4889c3ab3a2da0626fa5b554c1a7c9 (diff)
Remove Menu::compact() in favor of putting an if-then clause in
menu.html.php. This serves two purposes: 1) It's more efficient since we're doing less passes over the Menu tree 2) We're allowing themers to decide whether or not to show empty menus
Diffstat (limited to 'modules/gallery/views')
-rw-r--r--modules/gallery/views/menu.html.php2
1 files changed, 2 insertions, 0 deletions
diff --git a/modules/gallery/views/menu.html.php b/modules/gallery/views/menu.html.php
index ba16ef36..b4b38c93 100644
--- a/modules/gallery/views/menu.html.php
+++ b/modules/gallery/views/menu.html.php
@@ -1,4 +1,5 @@
<?php defined("SYSPATH") or die("No direct script access.") ?>
+<? if ($menu->elements): // Don't show the menu if it has no choices ?>
<? if ($menu->is_root): ?>
<ul class="<?= $menu->css_class ?>">
@@ -21,3 +22,4 @@
</li>
<? endif ?>
+<? endif ?>