PasswordField bug?!

Hi everyone,

I’m currently implementing a main menu script. One of the requirements is too list all player profiles in a table format. The user can then select a particular profile and edit various details such as player name, facebook username and password. I’m using Unity’s basic components like the TextField and PasswordField.

The problem is that whenever you copy&paste the value within the password field to a normal text field, the real characters are shown instead of * character. The simple script below can help you verify this…

Can someone tell me how to go about this?

private string _text = "";
private string _pass = "";

void OnGUI(){
	_text = GUI.TextField(new Rect(10, 10, 200, 30), _text);
	_pass = GUI.PasswordField(new Rect(10, 40, 200, 30), _pass, "*"[0]);
}

Regards,
Clayton

I’m not sure that’d be classified as a bug, although I can understand why you might not want the behaviour. However, the best I can suggest in this case is to look for / file a feature request to have the behaviour changed in a future release of Unity.