arrangeInFront:
ウインドウメニューにリストされているウインドウを他のウインドウの前に持ってきます
- (void)arrangeInFront:(id)sender
func arrangeInFront(_ sender: AnyObject?)
他のすべてのウィンドウの前面にウィンドウ]メニューにリストされているウィンドウを配置します。
解説
ウインドウメニューにリストされているウインドウを他の(アプリケーションの)ウインドウの前に持ってきます。
返り値
なし
フレームワーク
ApplicationKit
クラス
NSApplication
使用可能
10.0
編集時のバージョン
10.10
参照
- addWindowsItem
- removeWindowsItem
- makeKeyAndOrderFront (NSWindow)
例文
#import "MyObject.h" @implementation MyObject NSTimer *timer=nil; - (IBAction)myAction:(id)sender { //5秒ごとにこのアプリのウインドウが全面になる timer = [NSTimer scheduledTimerWithTimeInterval:5.0 target:self selector:@selector(timerControl:) userInfo:nil repeats:YES]; } -(void) timerControl:(NSTimer *)timer { NSLog(@"fire"); [NSApp arrangeInFront:nil]; } @end
//NSApplication arrangeInFront @IBAction func function039(sender: AnyObject) { //共有アプリケーションインスタンスを取得 let anApplication = MyApplication.sharedApplication() // anApplication.arrangeInFront(self) NSLog("NSApplication arrangeInFront") }