// call before GUI.TextField! or TextField will consume the enterkey! bool enterPressed = Event.current.Equals(Event.KeyboardEvent("return"));