In looking into #256471-2: Expand API-based control over pane type configuration forms in more detail, I've noticed that in recent versions (at least since beta4, maybe earlier), the value returned by a content type's title callback function is no longer used to set the title bar for the panes on the content drag-n-drop editing tab.

sdboyer and I are looking into this now in IRC, but I wanted to post an issue about it...

Comments

dww’s picture

Assigned: Unassigned » dww
Status: Active » Needs review
StatusFileSize
new1.09 KB

I tracked it down. The problem is in panels_show_pane(). Oddly, panels_get_pane_title() (which is where the content type's callback is invoked), was only getting called if the $content_type was empty. ;) I've restored the old behavior from when this used to work, and in my limited testing, it's working exactly as expected. Tracing through the code, it looks like this should handle all the right cases, even if the content type isn't there, or doesn't define a title callback, etc, etc. Plus, this is only the title bar on the pane itself, so if there's an error message up there from something not being defined, that seems utterly reasonable on an administrative page like this.

dww’s picture

StatusFileSize
new1.26 KB

Upon further review by sdboyer, he pointed out that we still might need a condition when $content_type is empty to fall back to the $block->title title. However, neither of us can come up with a case where $content_type is empty. ;) So, I'm not sure if this is needed, and I can't confirm the 2nd code path, but it's closer to how it used to be (only the logic works now)... ;)

sdboyer’s picture

Status: Needs review » Fixed

Great, committed. Thanks!

Anonymous’s picture

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for two weeks with no activity.