Page Index Toggle Pages: 1 Send TopicPrint
Normal Topic Copy / Paste Ctrl+C / Ctrl+V for multi-selection (Read 1592 times)
chieh
Junior Member
**
Offline


I love YaBB 1G - SP1!

Posts: 64
Joined: Aug 18th, 2010
Copy / Paste Ctrl+C / Ctrl+V for multi-selection
Sep 3rd, 2010 at 10:23am
Print Post  
Hi,

Currently, I am using JavaApplet Mode for diagram.
I have two questions in copy/paste on multi-selection nodes
The 1st is,
Is it possible to do copy and paste for multi selection on shapes when clicking the javascript function contains
var applet = <%= diagramView.AppletElement %>;
applet.copyToClipboard();
applet.pasteFromClipboard(10, 10);
? And then the 2nd question is,
Is it possible to enable keyboard's ctrl+c and ctrl+v for copy/past?
Any suggestions?
Many thanks
  
Back to top
 
IP Logged
 
Stoyo
God Member
*****
Offline


MindFusion support

Posts: 13230
Joined: Jul 20th, 2005
Re: Copy / Paste Ctrl+C / Ctrl+V for multi-selecti
Reply #1 - Sep 3rd, 2010 at 11:49am
Print Post  
Hi,

1. It should be possible doing that from the ClickedScript JS handler.

2. Try setting KeyPressScript to the following.

Code
Select All
function onKeyPress(sender, args)
{
	//alert(args.getKeyChar());
	var CtrlC = 3;
	var CtrlV = 22;
	var CtrlX = 24;

	var applet = <%= diagramView.AppletElement %>;
	if (args.getKeyChar() == CtrlC)
		applet.copyToClipboard();
	if (args.getKeyChar() == CtrlV)
		applet.pasteFromClipboard(10, 10);
} 



I hope that helps,
Stoyan
  
Back to top
 
IP Logged
 
Page Index Toggle Pages: 1
Send TopicPrint