Closed (fixed)
Project:
Zen
Version:
6.x-2.x-dev
Component:
PHP Code
Priority:
Critical
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
1 Oct 2009 at 16:37 UTC
Updated:
14 Apr 2010 at 20:53 UTC
Jump to comment: Most recent file
Comments
Comment #1
sfyn commentedI created a parallel issue in the Panels cue: http://drupal.org/node/593296
Comment #2
sfyn commentedHere's a simple patch that introduces support for the ctools local_tasks functions into the core zen template.php file. The implementation defaults to the drupal core functions if ctools is not present. Since I am unsure that the zen team/users desire to incorporate this functionality, I'm flagging this as needing work.
Comment #3
sfyn commentedComment #4
johnalbinConsidering Panels/ctools and Zen are both heavily-used projects, getting them to work together without users having to hand-edit php is important.
The patch in #2 is okay, but I want to try my hand at getting Panels to handle the issue on its end. Because its better to patch CTools then it is to patch every single theme that overrides theme_menu_local_tasks(). :-p
Comment #5
sfyn commentedAwesome - that would be twice as good.
Comment #6
johnalbinI did some research and discovered just how much I hate theme_menu_local_tasks. :-p
I tweaked the patch in #2 slightly and committed it. Thanks, sfyn! You're in the CHANGELOG. :-)
Fixed in 6.x-2.x-dev and 6.x-1.x-dev.
Comment #7
sfyn commentedNeato.
Sometime, I would be very curious to learn about this research of yours.
Comment #8
johnalbinWell, it was eyeball research (i.e. stare at the code). Plus the years of experience I've had with theme functions.
Good theme functions are passed data and manipulate it and output markup. This allows modules to alter the data via preprocess functions (in D7 anyway, D6 modules can only alter data passed to templates) and allows themes to override the markup by overriding the function/template. And both module and theme are happy.
theme_menu_local_tasks(), on the other hand, isn't passed any data and grabs its data directly from the database (via menu_primary_local_tasks and menu_secondary_local_tasks). That means the only method that both module and theme have to affect the output is to override the function/template themselves. And since only one of the overrides will be the active override, the other is SOL.