예제 #1
0
def withoutUpdateDialog_(self, notification):
    app = NSApplication.sharedApplication()
    message = "There is no updated version of MyCube Vault yet. Try again next time."
    alertPanel = NSGetAlertPanel("MyCube Vault", message, "Close", None, None)
    alertPanel.setFloatingPanel_(True)
    self.displayed = True
    app.runModalForWindow_(alertPanel)
    NSReleaseAlertPanel(alertPanel)
예제 #2
0
def withUpdateDialog_(self, notification):
    app = NSApplication.sharedApplication()
    message = "A new version of MyCube Vault is available for download."
    alertPanel = NSGetAlertPanel("MyCube Vault", message, "Download", "Do not download", None)
    alertPanel.setFloatingPanel_(True)
    self.displayed = True
    response = app.runModalForWindow_(alertPanel)
    NSReleaseAlertPanel(alertPanel)

    if response == 1:
        webbrowser.open("http://sourceforge.net/projects/themycubevault/files/MyCubeVault.dmg/download")