【问题标题】:Quit app after window is closed in AppleScript在 AppleScript 中关闭窗口后退出应用程序
【发布时间】:2011-12-03 13:37:53
【问题描述】:

我在 Xcode 中创建了一个 AppleScript 应用程序,我想知道如何让应用程序在窗口关闭后退出。

【问题讨论】:

    标签: xcode applescript


    【解决方案1】:

    在你的 AppDelegate 中添加一个applicationShouldTerminateAfterLastWindowClosed: 方法,例如:

    on applicationShouldTerminateAfterLastWindowClosed_(sender)
        return true
    end applicationShouldTerminateAfterLastWindowClosed_
    

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多