zendframework/zf2 — pull request #5670 by Xerkus (2014-01-03 19:31:00+00:00)
Title: [WIP] Add controller namespace prefix to template mapping

InjectTemplateListener changes behaviour when controller is matched by
map entry. Mapped namespace prefix is replaced with provided value and
rest of the controller inflected. If map entry value is boolean true,
then whole controller class is inflected. In all cases\Controller\
namespace and trailing Controller are stripped.

Most notable use case is when module name is not top level namespace

With map entry 'Vendor\Module' => true and controller class
Vendor\ModuleName\Controller\FooController resulting template name will be
vendor/module-name/foo/action-name