The development house I work at uses Panels for stuff a lot, and they're a central design tool for our clients. While we're able to group our own Panels content types and View Panes by specifying a category name, it isn't so easy for everything else: there's the useless content types in the "Activity" category, the confusing content types in "Entity", the overwhelming and mostly-useless content types in "Node (Tokens)", the really useless content types in "Page elements" (Why would I need to repeat design elements already in place on the page?)... I could go on.
Plus random blocks are always dropped in the "Miscellaneous" category -- seemingly the last place I always look for content types I cannot find.
What I really need is the ability to organize Panels content types, and hide categories that aren't needed.
To that end I've started work on a module that lets the use build and organize Panels content types into custom categories. However, the first major roadblock I've run into is convincing Panels to use my layout instead of the one it generates from the plugin info hooks.
In panels/includes/add-content.inc is
template_preprocess_panels_add_content_modal(), which is where Panels seems to set up its category tree (Via the function's $vars argument).
- Is there any way of inserting a hook into the function chain that
discards the $var variable that Panels is passing to
template_preprocess_panels_add_content_modal()and instead delivers my own?
- If not, is there a way to override
template_preprocess_panels_add_content_modal()with my own version?
- Or, best yet, is there a module somewhere that already does what I'm trying to do?