Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/matomo-org/matomo.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'core/Menu/MenuTop.php')
-rw-r--r--core/Menu/MenuTop.php11
1 files changed, 5 insertions, 6 deletions
diff --git a/core/Menu/MenuTop.php b/core/Menu/MenuTop.php
index 17cefa2135..7a860ef7d6 100644
--- a/core/Menu/MenuTop.php
+++ b/core/Menu/MenuTop.php
@@ -12,15 +12,14 @@ use Piwik\Piwik;
/**
* Contains menu entries for the Top menu (the menu at the very top of the page).
- * Plugins can subscribe to the {@hook Menu.Top.addItems} event to add new pages to
- * the top menu.
+ * Plugins can implement the `configureTopMenu()` method of the `Menu` plugin class to add, rename of remove
+ * items. If your plugin does not have a `Menu` class yet you can create one using `./console generate:menu`.
*
* **Example**
- *
- * // add a new page in an observer to Menu.Admin.addItems
- * public function addTopMenuItem()
+ *
+ * public function configureTopMenu(MenuTop $menu)
* {
- * MenuTop::getInstance()->add(
+ * $menu->add(
* 'MyPlugin_MyTranslatedMenuCategory',
* 'MyPlugin_MyTranslatedMenuName',
* array('module' => 'MyPlugin', 'action' => 'index'),