
Flash Player 7 + TheSpringBox 1.1.2
Widget.onPaste = function(clipboard:String) : Void {
// your statements here
}
clipboard - The string from the clipboard.
Nothing.
Event handler; an event handling function called when a user presse CTRL+v to paste content form the clipboard.
The function below could be used to handle a paste event. Place two input fields componentes on your stage named "inputOne" and "inputTwo".
var restrictStr = "= * ~ , ) ( % $ + ' | _ & ? / : . @ A-Z a-z 0-9 \\20 \\x16 \\^ \\-";
inputOne.restrict = restrictStr;
inputTwo.restrict = restrictStr;
Widget.onPaste = function(clipboard)
{
var clipWithFocus = inputOne.getFocus();
var itsInstanceName = clipWithFocus._parent._name;
if(itsInstanceName == "inputOne" || itsInstanceName == "inputTwo")
{
clipWithFocus._parent.text = clipboard;
}
};