public void Copy()
{
if ((this.selectIndex != this.cursorIndex) && !this.isPasswordField)
{
string str;
if (this.cursorIndex < this.selectIndex)
{
str = this.text.Substring(this.cursorIndex, this.selectIndex - this.cursorIndex);
}
else
{
str = this.text.Substring(this.selectIndex, this.cursorIndex - this.selectIndex);
}
GUIUtility.systemCopyBuffer = str;
}
}