12345678910111213141516171819202122232425262728293031323334 |
- "use strict";
- /**
- * Licensed Materials - Property of IBM
- * IBM Cognos Products: Cognos Analytics
- * Copyright IBM Corp. 2020
- * US Government Users Restricted Rights - Use, duplication or disclosure
- * restricted by GSA ADP Schedule Contract with IBM Corp.
- */
- define(['bi/commons/ui/core/Class', 'ba-react-admin/ba-react-admin.min'], function (Class, AdminReact) {
- 'use strict'; //NOSONAR: meant to be strict
- var ContextMenuController = Class.extend({
- acmAdapter: null,
- init: function init() {
- this.acmAdapter = new AdminReact.AccountsContextMenuAdapter();
- },
- /**
- * Called by glass for each menu item to know if it's visible or not
- */
- isItemVisible: function isItemVisible(context) {
- return this.acmAdapter.isItemVisible(context);
- },
- /**
- * Called when the menu item is pressed
- */
- onSelectItem: function onSelectItem(context) {
- this.acmAdapter.onSelectItem(context);
- }
- });
- return ContextMenuController;
- });
|