[Selection] Expose contextual gesture

This commit is contained in:
Victor Woeltjen 2016-09-22 11:48:44 -07:00
parent 152f55652f
commit fdab4a614f

View File

@ -24,19 +24,28 @@ define([
'./selection/Selection',
'./selection/ContextManager',
'./selection/SelectGesture',
'./ui/menu/ContextMenuGesture',
'./ui/ViewRegistry'
], function (Selection, ContextManager, SelectGesture, ViewRegistry) {
], function (
Selection,
ContextManager,
SelectGesture,
ContextMenuGesture,
ViewRegistry
) {
var openmct = {};
var selection = new Selection();
var manager = new ContextManager();
var select = new SelectGesture(manager, selection);
var contextMenu = new ContextMenuGesture(selection, {}, {}, manager);
openmct.selection = selection;
openmct.inspectors = new ViewRegistry();
openmct.gestures = {
selectable: select.apply.bind(select)
selectable: select.apply.bind(select),
contextual: contextMenu.apply.bind(contextMenu)
};
return openmct;