3 つの IBActions があり、それぞれが次のように独自のボタンにリンクされています。
#import "Controller.h"
#import "Application.h"
@implementation Controller
- (IBAction)deal:(id)sender {
NSButton *deal = (NSButton *)sender;
...
}
- (IBAction)hit:(id)sender {
NSButton *hit = (NSButton *)sender;
...
}
- (IBAction)stay:(id)sender {
NSButton *stay = (NSButton *)sender;
...
}
@end
スコープ外のボタンをどのように使用/呼び出しますか? 私はこのようなことをしようとしています:
- (IBAction)hit:(id)sender {
NSButton *hit = (NSButton *)sender;
...
[hit setEnabled: NO];
[stay setEnabled: NO]; // Using/altering "Stay's" button
}
前もって感謝します!