|
@@ -8,9 +8,9 @@ import { getDi } from '../../util/ModelUtil';
|
|
|
* A palette provider for BPMN 2.0 elements.
|
|
|
*/
|
|
|
export default function PaletteProvider(
|
|
|
- palette, create, elementFactory,
|
|
|
- spaceTool, lassoTool, handTool,
|
|
|
- globalConnect, translate) {
|
|
|
+ palette, create, elementFactory,
|
|
|
+ spaceTool, lassoTool, handTool,
|
|
|
+ globalConnect, translate) {
|
|
|
|
|
|
this._palette = palette;
|
|
|
this._create = create;
|
|
@@ -36,16 +36,16 @@ PaletteProvider.$inject = [
|
|
|
];
|
|
|
|
|
|
|
|
|
-PaletteProvider.prototype.getPaletteEntries = function(element) {
|
|
|
+PaletteProvider.prototype.getPaletteEntries = function (element) {
|
|
|
|
|
|
var actions = {},
|
|
|
- create = this._create,
|
|
|
- elementFactory = this._elementFactory,
|
|
|
- spaceTool = this._spaceTool,
|
|
|
- lassoTool = this._lassoTool,
|
|
|
- handTool = this._handTool,
|
|
|
- globalConnect = this._globalConnect,
|
|
|
- translate = this._translate;
|
|
|
+ create = this._create,
|
|
|
+ elementFactory = this._elementFactory,
|
|
|
+ spaceTool = this._spaceTool,
|
|
|
+ lassoTool = this._lassoTool,
|
|
|
+ handTool = this._handTool,
|
|
|
+ globalConnect = this._globalConnect,
|
|
|
+ translate = this._translate;
|
|
|
|
|
|
function createAction(type, group, className, title, options) {
|
|
|
|
|
@@ -88,9 +88,9 @@ PaletteProvider.prototype.getPaletteEntries = function(element) {
|
|
|
parent: subProcess
|
|
|
});
|
|
|
|
|
|
- create.start(event, [ subProcess, startEvent ], {
|
|
|
+ create.start(event, [subProcess, startEvent], {
|
|
|
hints: {
|
|
|
- autoSelect: [ subProcess ]
|
|
|
+ autoSelect: [subProcess]
|
|
|
}
|
|
|
});
|
|
|
}
|
|
@@ -105,7 +105,7 @@ PaletteProvider.prototype.getPaletteEntries = function(element) {
|
|
|
className: 'bpmn-icon-hand-tool',
|
|
|
title: translate('Activate the hand tool'),
|
|
|
action: {
|
|
|
- click: function(event) {
|
|
|
+ click: function (event) {
|
|
|
handTool.activateHand(event);
|
|
|
}
|
|
|
}
|
|
@@ -115,7 +115,7 @@ PaletteProvider.prototype.getPaletteEntries = function(element) {
|
|
|
className: 'bpmn-icon-lasso-tool',
|
|
|
title: translate('Activate the lasso tool'),
|
|
|
action: {
|
|
|
- click: function(event) {
|
|
|
+ click: function (event) {
|
|
|
lassoTool.activateSelection(event);
|
|
|
}
|
|
|
}
|
|
@@ -125,7 +125,7 @@ PaletteProvider.prototype.getPaletteEntries = function(element) {
|
|
|
className: 'bpmn-icon-space-tool',
|
|
|
title: translate('Activate the create/remove space tool'),
|
|
|
action: {
|
|
|
- click: function(event) {
|
|
|
+ click: function (event) {
|
|
|
spaceTool.activateSelection(event);
|
|
|
}
|
|
|
}
|
|
@@ -135,7 +135,7 @@ PaletteProvider.prototype.getPaletteEntries = function(element) {
|
|
|
className: 'bpmn-icon-connection-multi',
|
|
|
title: translate('Activate the global connect tool'),
|
|
|
action: {
|
|
|
- click: function(event) {
|
|
|
+ click: function (event) {
|
|
|
globalConnect.start(event);
|
|
|
}
|
|
|
}
|
|
@@ -148,52 +148,52 @@ PaletteProvider.prototype.getPaletteEntries = function(element) {
|
|
|
'bpmn:StartEvent', 'event', 'bpmn-icon-start-event-none',
|
|
|
translate('Create StartEvent')
|
|
|
),
|
|
|
- 'create.intermediate-event': createAction(
|
|
|
- 'bpmn:IntermediateThrowEvent', 'event', 'bpmn-icon-intermediate-event-none',
|
|
|
- translate('Create Intermediate/Boundary Event')
|
|
|
- ),
|
|
|
+ // 'create.intermediate-event': createAction(
|
|
|
+ // 'bpmn:IntermediateThrowEvent', 'event', 'bpmn-icon-intermediate-event-none',
|
|
|
+ // translate('Create Intermediate/Boundary Event')
|
|
|
+ // ),
|
|
|
'create.end-event': createAction(
|
|
|
'bpmn:EndEvent', 'event', 'bpmn-icon-end-event-none',
|
|
|
translate('Create EndEvent')
|
|
|
),
|
|
|
- 'create.exclusive-gateway': createAction(
|
|
|
- 'bpmn:ExclusiveGateway', 'gateway', 'bpmn-icon-gateway-none',
|
|
|
- translate('Create Gateway')
|
|
|
- ),
|
|
|
- 'create.task': createAction(
|
|
|
- 'bpmn:Task', 'activity', 'bpmn-icon-task',
|
|
|
- translate('Create Task')
|
|
|
- ),
|
|
|
- 'create.data-object': createAction(
|
|
|
- 'bpmn:DataObjectReference', 'data-object', 'bpmn-icon-data-object',
|
|
|
- translate('Create DataObjectReference')
|
|
|
- ),
|
|
|
- 'create.data-store': createAction(
|
|
|
- 'bpmn:DataStoreReference', 'data-store', 'bpmn-icon-data-store',
|
|
|
- translate('Create DataStoreReference')
|
|
|
- ),
|
|
|
- 'create.subprocess-expanded': {
|
|
|
- group: 'activity',
|
|
|
- className: 'bpmn-icon-subprocess-expanded',
|
|
|
- title: translate('Create expanded SubProcess'),
|
|
|
- action: {
|
|
|
- dragstart: createSubprocess,
|
|
|
- click: createSubprocess
|
|
|
- }
|
|
|
- },
|
|
|
- 'create.participant-expanded': {
|
|
|
- group: 'collaboration',
|
|
|
- className: 'bpmn-icon-participant',
|
|
|
- title: translate('Create Pool/Participant'),
|
|
|
- action: {
|
|
|
- dragstart: createParticipant,
|
|
|
- click: createParticipant
|
|
|
- }
|
|
|
- },
|
|
|
- 'create.group': createAction(
|
|
|
- 'bpmn:Group', 'artifact', 'bpmn-icon-group',
|
|
|
- translate('Create Group')
|
|
|
- ),
|
|
|
+ // 'create.exclusive-gateway': createAction(
|
|
|
+ // 'bpmn:ExclusiveGateway', 'gateway', 'bpmn-icon-gateway-none',
|
|
|
+ // translate('Create Gateway')
|
|
|
+ // ),
|
|
|
+ // 'create.task': createAction(
|
|
|
+ // 'bpmn:Task', 'activity', 'bpmn-icon-task',
|
|
|
+ // translate('Create Task')
|
|
|
+ // ),
|
|
|
+ // 'create.data-object': createAction(
|
|
|
+ // 'bpmn:DataObjectReference', 'data-object', 'bpmn-icon-data-object',
|
|
|
+ // translate('Create DataObjectReference')
|
|
|
+ // ),
|
|
|
+ // 'create.data-store': createAction(
|
|
|
+ // 'bpmn:DataStoreReference', 'data-store', 'bpmn-icon-data-store',
|
|
|
+ // translate('Create DataStoreReference')
|
|
|
+ // ),
|
|
|
+ // 'create.subprocess-expanded': {
|
|
|
+ // group: 'activity',
|
|
|
+ // className: 'bpmn-icon-subprocess-expanded',
|
|
|
+ // title: translate('Create expanded SubProcess'),
|
|
|
+ // action: {
|
|
|
+ // dragstart: createSubprocess,
|
|
|
+ // click: createSubprocess
|
|
|
+ // }
|
|
|
+ // },
|
|
|
+ // 'create.participant-expanded': {
|
|
|
+ // group: 'collaboration',
|
|
|
+ // className: 'bpmn-icon-participant',
|
|
|
+ // title: translate('Create Pool/Participant'),
|
|
|
+ // action: {
|
|
|
+ // dragstart: createParticipant,
|
|
|
+ // click: createParticipant
|
|
|
+ // }
|
|
|
+ // },
|
|
|
+ // 'create.group': createAction(
|
|
|
+ // 'bpmn:Group', 'artifact', 'bpmn-icon-group',
|
|
|
+ // translate('Create Group')
|
|
|
+ // ),
|
|
|
});
|
|
|
|
|
|
return actions;
|