From 1d9df22742c3110e1322829c285dcfa6a4a603d3 Mon Sep 17 00:00:00 2001 From: Dries Buytaert Date: Sat, 17 Oct 2009 11:39:15 +0000 Subject: [PATCH] - Patch #473268 by sun: documentation improvements for edit in place. --- CHANGELOG.txt | 3 +++ includes/menu.inc | 4 ++-- modules/menu/menu.api.php | 13 +++++++------ 3 files changed, 12 insertions(+), 8 deletions(-) diff --git a/CHANGELOG.txt b/CHANGELOG.txt index 607cce2bc19..1071896f2f1 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -19,6 +19,9 @@ Drupal 7.0, xxxx-xx-xx (development version) improved the flood control API to allow variable time windows and identifiers for limiting user access to resources. - Usability: + * Added contextual links (a.k.a. local tasks) to page elements, such as + blocks, nodes, or comments, which allows to perform the most common tasks + with a single click only. * Improved installer requirements check. * Improved support for integration of WYSIWYG editors. * Implemented drag-and-drop positioning for input format listings. diff --git a/includes/menu.inc b/includes/menu.inc index 8371980aa59..7a6787c5fb6 100644 --- a/includes/menu.inc +++ b/includes/menu.inc @@ -1782,8 +1782,8 @@ function menu_local_tasks($level = 0) { * Retrieve contextual links for a system object based on registered local tasks. * * This leverages the menu system to retrieve the first layer of registered - * local tasks for a given system path. All local tasks of the tab type 'task' - * or 'context' are taken into account. + * local tasks for a given system path. All local tasks of the tab type + * MENU_CONTEXT_INLINE are taken into account. * * @see hook_menu() * diff --git a/modules/menu/menu.api.php b/modules/menu/menu.api.php index 65170333c25..97f0737aea9 100644 --- a/modules/menu/menu.api.php +++ b/modules/menu/menu.api.php @@ -199,12 +199,11 @@ * this alone; the default alphabetical order is usually best. * - "menu_name": Optional. Set this to a custom menu if you don't want your * item to be placed in Navigation. - * - "context": (optional) Defines the type of a tab to control its placement - * depending on the requested context. By default, all tabs are only - * displayed as local tasks when being rendered in a page context. All tabs - * that should be accessible as contextual links in page region containers - * outside of the parent menu item's primary page context should be - * registered using one of the following contexts: + * - "context": (optional) Defines the context a tab may appear in. By + * default, all tabs are only displayed as local tasks when being rendered + * in a page context. All tabs that should be accessible as contextual links + * in page region containers outside of the parent menu item's primary page + * context should be registered using one of the following contexts: * - MENU_CONTEXT_PAGE: (default) The tab is displayed as local task for the * page context only. * - MENU_CONTEXT_INLINE: The tab is displayed as contextual link outside of @@ -536,6 +535,8 @@ function hook_menu_local_tasks_alter(&$data, $router_item, $root_path) { * 'node/123' became 'node/%'. * * @see menu_contextual_links() + * @see hook_menu() + * @see system_preprocess() */ function hook_menu_contextual_links_alter(&$links, $router_item, $root_path) { // Add a link to all contextual links for nodes.