Closed (fixed)
Project:
DHTML Menu
Version:
7.x-1.x-dev
Component:
User Interface
Priority:
Normal
Category:
Task
Assigned:
Unassigned
Reporter:
Created:
31 May 2009 at 16:01 UTC
Updated:
23 Nov 2010 at 21:30 UTC
Jump to comment: Most recent file
Comments
Comment #1
cburschkaThis patch does the following.
a) Privatize dhtml_menu_menus to _dhtml_menu_menus. There's no hook_menus, but as this function is internal, it should be named accordingly.
b) Use menu_get_menus (if menu.module is enabled), book_get_books (if book.module is enabled) and menu_list_system_menus (always) to build a human-readable list of menu names.
c) Add the code to filter these names through menu_get_names(), which will remove empty (unused) menus and add the internal names of any menu perhaps created by some other contrib module. This code is not called now (the function returns first) until #473240 is fixed.
Comment #2
cburschkaDidn't clean my local copy properly. Here is the patch without other changes.
Comment #3
cburschkaI asked around, and module_exists() is completely redundant here as far as performance is concerned.
Comment #4
cburschkaTested and read over repeatedly, and found nothing to improve (reviewing your own patches is tough). Committed to HEAD.
Comment #6
cburschka#473240: menu_get_names() crashes when called. has long since been fixed. This workaround should now be reversed.
Comment #7
cburschkaHere's a patch.
Comment #8
cburschkaCommitted to HEAD and to DRUPAL-6--4.