Execute an Action when the Enter-Key is pressed in a NSTextField?

后端 未结 8 1953
野的像风
野的像风 2020-12-02 06:23

I have a small problem right now. I want to execute a method when the Enter key is pressed in a NSTextField. The user should be able to enter his data and a calculation meth

8条回答
  •  死守一世寂寞
    2020-12-02 06:42

    In Interface Builder - click on your NSTextField, go to the connections editor, drag from selector to your controller object - you're actions should come up!

提交回复
热议问题