Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support for copy and paste #69

Closed
jan-ladleif opened this issue Dec 14, 2018 · 2 comments
Closed

Support for copy and paste #69

jan-ladleif opened this issue Dec 14, 2018 · 2 comments
Assignees
Labels
bug Something isn't working

Comments

@jan-ladleif
Copy link
Member

Copy and paste does not work currently. For example, when trying to paste a choreography task:

TypeError: self.canPaste is not a function[Learn More] ChoreoRules.js:213:11
	[38]</ChoreoRules.prototype.init/< ChoreoRules.js:213:11
	unwrapEvent/< CommandInterceptor.js:43:11
	<anonymous> self-hosted:978:17
	invokeFunction EventBus.js:480:9
	[172]</EventBus.prototype._invokeListener EventBus.js:356:18
	[172]</EventBus.prototype._invokeListeners EventBus.js:344:18
	[172]</EventBus.prototype.fire EventBus.js:304:18
	[167]</CommandStack.prototype._fire CommandStack.js:346:13
	[167]</CommandStack.prototype.canExecute CommandStack.js:178:15
	[278]</Rules.prototype.allowed Rules.js:41:14
	[201]</CopyPaste.prototype.paste CopyPaste.js:225:13
	[210]</EditorActions.prototype._registerDefaultActions/< EditorActions.js:101:6
	[210]</EditorActions.prototype.trigger EditorActions.js:173:9
	[221]</KeyboardBindings.prototype.registerBindings/< KeyboardBindings.js:107:6
	invokeFunction EventBus.js:480:9
	[172]</EventBus.prototype._invokeListener EventBus.js:356:18
	[172]</EventBus.prototype._invokeListeners EventBus.js:344:18
	[172]</EventBus.prototype.fire EventBus.js:304:18
	[220]</Keyboard.prototype._keyHandler Keyboard.js:94:19
	<anonymous> self-hosted:976:17
@jan-ladleif jan-ladleif added the bug Something isn't working label Dec 14, 2018
@yT0n1 yT0n1 self-assigned this Dec 17, 2018
@yT0n1
Copy link
Collaborator

yT0n1 commented Dec 17, 2018

First of all we will have to add a canPaste function to ChoreoRules. Then BpmnCopyPaste.js which registers a function on 'element.paste' (element without 's', so every single element) looks like a candidate to overwrite/disable/subscribe.
It iteratively gets a context which contains some (should be possible to contain all) pasted elements. It could be possible to implement correct copy/clone and re-referencing here.

yT0n1 added a commit that referenced this issue Mar 27, 2019
Implements copy-paste functionality. Implements #69
@yT0n1
Copy link
Collaborator

yT0n1 commented Mar 27, 2019

Closed in #81

@yT0n1 yT0n1 closed this as completed Mar 27, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants