문제

I have a custom control that I use that has some (NSTextField *) NSCells in it. I have attempted at the cell level to disable all cells from usage, yet my loop that goes through all the cells seems to do nothing.

[myCell setEnabled:NO];

compile and run...

cell is still clickable and editable.

My final goal is to ofcourse disable only a few during runtime... but I cant even disable all of them during setup.

도움이 되었습니까?

해결책 2

the issue was with a super method that was toggling everything. I then had to deal with both the keyDown actions and keyUp actions that were also enabling entry. Also had to deal with the NSStepper ability to circumvent the fields not being enabled.

다른 팁

Try calling setEditable:NO on them as well.

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top