mirror of
https://github.com/nasa/openmct.git
synced 2025-01-21 12:05:12 +00:00
[Selection] Expose contextual gesture
This commit is contained in:
parent
152f55652f
commit
fdab4a614f
@ -24,19 +24,28 @@ define([
|
|||||||
'./selection/Selection',
|
'./selection/Selection',
|
||||||
'./selection/ContextManager',
|
'./selection/ContextManager',
|
||||||
'./selection/SelectGesture',
|
'./selection/SelectGesture',
|
||||||
|
'./ui/menu/ContextMenuGesture',
|
||||||
'./ui/ViewRegistry'
|
'./ui/ViewRegistry'
|
||||||
], function (Selection, ContextManager, SelectGesture, ViewRegistry) {
|
], function (
|
||||||
|
Selection,
|
||||||
|
ContextManager,
|
||||||
|
SelectGesture,
|
||||||
|
ContextMenuGesture,
|
||||||
|
ViewRegistry
|
||||||
|
) {
|
||||||
var openmct = {};
|
var openmct = {};
|
||||||
var selection = new Selection();
|
var selection = new Selection();
|
||||||
var manager = new ContextManager();
|
var manager = new ContextManager();
|
||||||
var select = new SelectGesture(manager, selection);
|
var select = new SelectGesture(manager, selection);
|
||||||
|
var contextMenu = new ContextMenuGesture(selection, {}, {}, manager);
|
||||||
|
|
||||||
openmct.selection = selection;
|
openmct.selection = selection;
|
||||||
|
|
||||||
openmct.inspectors = new ViewRegistry();
|
openmct.inspectors = new ViewRegistry();
|
||||||
|
|
||||||
openmct.gestures = {
|
openmct.gestures = {
|
||||||
selectable: select.apply.bind(select)
|
selectable: select.apply.bind(select),
|
||||||
|
contextual: contextMenu.apply.bind(contextMenu)
|
||||||
};
|
};
|
||||||
|
|
||||||
return openmct;
|
return openmct;
|
||||||
|
Loading…
Reference in New Issue
Block a user