target
アクションセルのターゲットオブジェクトを返します
解説
アクションセルのターゲットオブジェクト(anObject)を返します。
返り値
( id )
ターゲットオブジェクト
引数
フレームワーク
ApplicationKit
クラス
NSActionCell
Instance Methods
使用可能
10.0
参照
例文
#import "MyObject1.h" @implementation MyObject1 - (IBAction)myAction:(id)sender { //but1,but2はtextfield //aCellはbutton if ([aCell target]==but1){ [but1 setStringValue:@" "]; [aCell setTarget:but2]; }else{ [but2 setStringValue:@" "]; [aCell setTarget:but1]; } } @end