diff --git a/code/apps/Managed Software Center/Managed Software Center/MSCBadgedTemplateImage.py b/code/apps/Managed Software Center/Managed Software Center/MSCBadgedTemplateImage.py index 0bd3e3ca..3da5abab 100644 --- a/code/apps/Managed Software Center/Managed Software Center/MSCBadgedTemplateImage.py +++ b/code/apps/Managed Software Center/Managed Software Center/MSCBadgedTemplateImage.py @@ -18,6 +18,9 @@ # limitations under the License. +# builtin super doesn't work with Cocoa classes in recent PyObjC releases. +from objc import super + from Foundation import * from AppKit import * diff --git a/code/apps/Managed Software Center/Managed Software Center/MSCMainWindowController.py b/code/apps/Managed Software Center/Managed Software Center/MSCMainWindowController.py index 6033f243..210e477c 100644 --- a/code/apps/Managed Software Center/Managed Software Center/MSCMainWindowController.py +++ b/code/apps/Managed Software Center/Managed Software Center/MSCMainWindowController.py @@ -23,12 +23,12 @@ import munki import mschtml import msclib import msclog -import MSCBadgedTemplateImage import MunkiItems from urlparse import urlparse from AlertController import AlertController +from MSCBadgedTemplateImage import MSCBadgedTemplateImage from objc import YES, NO, IBAction, IBOutlet, nil from PyObjCTools import AppHelper diff --git a/code/apps/Managed Software Center/Managed Software Center/MSCToolbar.py b/code/apps/Managed Software Center/Managed Software Center/MSCToolbar.py index 64437de4..efb37b3d 100644 --- a/code/apps/Managed Software Center/Managed Software Center/MSCToolbar.py +++ b/code/apps/Managed Software Center/Managed Software Center/MSCToolbar.py @@ -6,8 +6,12 @@ # Created by Daniel Hazelbaker on 9/2/14. # +# builtin super doesn't work with Cocoa classes in recent PyObjC releases. +from objc import super + from objc import YES, NO, nil from Foundation import * +from AppKit import * class MSCToolbarButton(NSButton): @@ -26,13 +30,14 @@ class MSCToolbarButton(NSButton): return view - class MSCToolbarButtonCell(NSButtonCell): '''Subclass of NSButtonCell which properly works inside of a toolbar item to allow clicking on the label.''' - def _hitTestForTrackMouseEvent_inRect_ofView_(self, theEvent, rect, controlView): - aPoint = controlView.superview().convertPoint_fromView_(theEvent.locationInWindow(), nil) + def _hitTestForTrackMouseEvent_inRect_ofView_(self, theEvent, + rect, controlView): + aPoint = controlView.superview().convertPoint_fromView_( + theEvent.locationInWindow(), nil) hit = NO for v in controlView.superview().subviews():