mirror of
https://github.com/munki/munki.git
synced 2026-04-23 13:29:26 -05:00
Change to Managed Software Update.app so it is more aggressive about checking for updates when manually launched.
git-svn-id: http://munki.googlecode.com/svn/trunk@996 a4e17f2e-e282-11dd-95e1-755cbddbdd66
This commit is contained in:
@@ -17,11 +17,11 @@
|
||||
<key>CFBundlePackageType</key>
|
||||
<string>APPL</string>
|
||||
<key>CFBundleShortVersionString</key>
|
||||
<string>3.0.12</string>
|
||||
<string>3.0.13</string>
|
||||
<key>CFBundleSignature</key>
|
||||
<string>????</string>
|
||||
<key>CFBundleVersion</key>
|
||||
<string>3.0.12</string>
|
||||
<string>3.0.13</string>
|
||||
<key>LSHasLocalizedDisplayName</key>
|
||||
<true/>
|
||||
<key>NSMainNibFile</key>
|
||||
|
||||
@@ -63,8 +63,15 @@ class MSUAppDelegate(NSObject):
|
||||
elif self.runmode == "MunkiStatus":
|
||||
self.munkiStatusController.startMunkiStatusSession()
|
||||
else:
|
||||
# display updates if available; if no available updates
|
||||
# trigger an update check
|
||||
# user may have launched the app manually, or it may have
|
||||
# been launched by /usr/local/munki/managedsoftwareupdate
|
||||
# to display available updates
|
||||
lastcheck = NSDate.dateWithString_(munki.pref('LastCheckDate'))
|
||||
if not lastcheck or lastcheck.timeIntervalSinceNow() < -60:
|
||||
# it's been more than a minute since the last check
|
||||
self.checkForUpdates()
|
||||
return
|
||||
# do we have existing updates to display?
|
||||
if not self._listofupdates:
|
||||
self.getAvailableUpdates()
|
||||
if self._listofupdates:
|
||||
@@ -82,7 +89,8 @@ class MSUAppDelegate(NSObject):
|
||||
|
||||
def munkiStatusSessionEnded_(self, socketSessionResult):
|
||||
consoleuser = munki.getconsoleuser()
|
||||
if self.runmode == "MunkiStatus" or consoleuser == None or consoleuser == u"loginwindow":
|
||||
if (self.runmode == "MunkiStatus" or consoleuser == None
|
||||
or consoleuser == u"loginwindow"):
|
||||
# Status Window only, so we should just quit
|
||||
NSApp.terminate_(self)
|
||||
|
||||
|
||||
@@ -18,6 +18,7 @@
|
||||
C0458B4D11EB8899001F1172 /* ScaledImageView.m in Sources */ = {isa = PBXBuildFile; fileRef = C0458B4C11EB8899001F1172 /* ScaledImageView.m */; };
|
||||
C0458B5111EB88C0001F1172 /* MSUStatusWindowController.py in Resources */ = {isa = PBXBuildFile; fileRef = C0458B5011EB88C0001F1172 /* MSUStatusWindowController.py */; };
|
||||
C062868911E677820009B44B /* MSUOptionalInstallsViewController.py in Resources */ = {isa = PBXBuildFile; fileRef = C062868811E677820009B44B /* MSUOptionalInstallsViewController.py */; };
|
||||
C082286F12C3CF5D007BAD36 /* ManagedInstalls.manifest in Resources */ = {isa = PBXBuildFile; fileRef = C082286E12C3CF5D007BAD36 /* ManagedInstalls.manifest */; };
|
||||
C0828C801123DBC5003D5807 /* MSUWebViewPolicyDelegate.py in Resources */ = {isa = PBXBuildFile; fileRef = C0828C7F1123DBC5003D5807 /* MSUWebViewPolicyDelegate.py */; };
|
||||
C0828C901123DCFF003D5807 /* ShutDownReq.tif in Resources */ = {isa = PBXBuildFile; fileRef = C0828C871123DCFF003D5807 /* ShutDownReq.tif */; };
|
||||
C0828C911123DCFF003D5807 /* RestartRec.tif in Resources */ = {isa = PBXBuildFile; fileRef = C0828C881123DCFF003D5807 /* RestartRec.tif */; };
|
||||
@@ -57,6 +58,7 @@
|
||||
C0458B4F11EB88AD001F1172 /* ScaledImageView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = ScaledImageView.h; sourceTree = "<group>"; };
|
||||
C0458B5011EB88C0001F1172 /* MSUStatusWindowController.py */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.script.python; path = MSUStatusWindowController.py; sourceTree = "<group>"; };
|
||||
C062868811E677820009B44B /* MSUOptionalInstallsViewController.py */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.script.python; path = MSUOptionalInstallsViewController.py; sourceTree = "<group>"; };
|
||||
C082286E12C3CF5D007BAD36 /* ManagedInstalls.manifest */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xml; path = ManagedInstalls.manifest; sourceTree = "<group>"; };
|
||||
C0828C7F1123DBC5003D5807 /* MSUWebViewPolicyDelegate.py */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.script.python; path = MSUWebViewPolicyDelegate.py; sourceTree = "<group>"; };
|
||||
C0828C871123DCFF003D5807 /* ShutDownReq.tif */ = {isa = PBXFileReference; lastKnownFileType = image.tiff; path = ShutDownReq.tif; sourceTree = "<group>"; };
|
||||
C0828C881123DCFF003D5807 /* RestartRec.tif */ = {isa = PBXFileReference; lastKnownFileType = image.tiff; path = RestartRec.tif; sourceTree = "<group>"; };
|
||||
@@ -178,6 +180,7 @@
|
||||
C0828C8E1123DCFF003D5807 /* package.tiff */,
|
||||
C0828C8F1123DCFF003D5807 /* Installer.tiff */,
|
||||
8D1107310486CEB800E47090 /* Info.plist */,
|
||||
C082286E12C3CF5D007BAD36 /* ManagedInstalls.manifest */,
|
||||
);
|
||||
name = Resources;
|
||||
sourceTree = "<group>";
|
||||
@@ -266,6 +269,7 @@
|
||||
C0E9E82411EFB1EB003CE81A /* Solid Aqua Blue.png in Resources */,
|
||||
C0C548FD12B6E52B002C76CD /* Localizable.strings in Resources */,
|
||||
C0C5493212B9691B002C76CD /* MainMenu.strings in Resources */,
|
||||
C082286F12C3CF5D007BAD36 /* ManagedInstalls.manifest in Resources */,
|
||||
);
|
||||
runOnlyForDeploymentPostprocessing = 0;
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user