登录 注册
当前位置:主页 > 资源下载 > 39 > MAC优化不可或缺的工具:beamOff

MAC优化不可或缺的工具:beamOff

  • 更新:2024-06-03 14:55:20
  • 大小:28KB
  • 推荐:★★★★★
  • 来源:网友上传分享
  • 类别:MacOS - 操作系统
  • 格式:ZIP

资源介绍

// // AppDelegate.m // beamoff // // Created by ANDREI VAYAVODA on 09.11.14. // Copyright (c) 2014 ANDREI VAYAVODA. All rights reserved. // #import "AppDelegate.h" extern void CGSSetDebugOptions(int); extern void CGSDeferredUpdates(int); typedef enum { disableBeamSync = 0, automaticBeamSync = 1, forcedBeamSyncMode = 2 } beamSyncMode; @interface AppDelegate () @property (weak) IBOutlet NSWindow *window; @end @implementation AppDelegate - (void)applicationDidFinishLaunching:(NSNotification *)aNotification { int mode = disableBeamSync; CGSSetDebugOptions(mode ? 0 : 0x08000000); CGSDeferredUpdates(mode); [self.window close]; [NSApp terminate:self]; } - (void)applicationWillTerminate:(NSNotification *)aNotification { // Insert code here to tear down your application }