Redesigned hooks system (moving from CMS_RESPONSE to CMS_API).

Indeed, hooks does not require RESPONSE interface,
   and should be setup before, at the system level (i.e CMS_API)
Added exportation solution via CMS_HOOK_EXPORT.
Updated blocks settings for demo example project.
This commit is contained in:
2015-11-09 21:07:02 +01:00
parent 6b3ff6f980
commit 420051cd14
30 changed files with 609 additions and 100 deletions

View File

@@ -12,7 +12,7 @@ inherit
module_api as feed_aggregator_api
redefine
initialize,
register_hooks,
setup_hooks,
permissions,
feed_aggregator_api
end
@@ -181,13 +181,13 @@ feature -- Handle
feature -- Hooks configuration
register_hooks (a_response: CMS_RESPONSE)
setup_hooks (a_hooks: CMS_HOOK_CORE_MANAGER)
-- Module hooks configuration.
do
a_response.hooks.subscribe_to_block_hook (Current)
a_response.hooks.subscribe_to_response_alter_hook (Current)
a_response.hooks.subscribe_to_menu_system_alter_hook (Current)
a_response.hooks.subscribe_to_cache_hook (Current)
a_hooks.subscribe_to_block_hook (Current)
a_hooks.subscribe_to_response_alter_hook (Current)
a_hooks.subscribe_to_menu_system_alter_hook (Current)
a_hooks.subscribe_to_cache_hook (Current)
end
feature -- Hook