Documentation Archive Developer
Search

PreferencePanes Changes for Swift

PreferencePanes

Removed NSPreferencePaneUnselectReply.init(_: UInt32)
Removed NSPreferencePaneUnselectReply.value
Modified NSPreferencePane
Declaration
From
class NSPreferencePane : NSObject {
    init!(bundle bundle: NSBundle!)
    var bundle: NSBundle! { get }
    func loadMainView() -> NSView!
    func mainViewDidLoad()
    var mainNibName: String! { get }
    func assignMainView()
    func willSelect()
    func didSelect()
    var shouldUnselect: NSPreferencePaneUnselectReply { get }
    func replyToShouldUnselect(_ shouldUnselect: Bool)
    func willUnselect()
    func didUnselect()
    var mainView: NSView!
    var initialKeyView: NSView!
    var firstKeyView: NSView!
    var lastKeyView: NSView!
    var autoSaveTextFields: Bool { get }
    var selected: Bool { get }
    func updateHelpMenuWithArray(_ inArrayOfMenuItems: [AnyObject]!)
}
To
class NSPreferencePane : NSObject {
    init(bundle bundle: NSBundle)
    var bundle: NSBundle { get }
    func loadMainView() -> NSView
    func mainViewDidLoad()
    var mainNibName: String { get }
    func assignMainView()
    func willSelect()
    func didSelect()
    var shouldUnselect: NSPreferencePaneUnselectReply { get }
    func replyToShouldUnselect(_ shouldUnselect: Bool)
    func willUnselect()
    func didUnselect()
    var mainView: NSView
    var initialKeyView: NSView?
    var firstKeyView: NSView?
    var lastKeyView: NSView?
    var autoSaveTextFields: Bool { get }
    var selected: Bool { get }
    func updateHelpMenuWithArray(_ inArrayOfMenuItems: [[String : String]]?)
}

Modified NSPreferencePane.bundle
Declaration
From
var bundle: NSBundle! { get }
To
var bundle: NSBundle { get }

Modified NSPreferencePane.firstKeyView
Declaration
From
var firstKeyView: NSView!
To
var firstKeyView: NSView?

Modified NSPreferencePane.init(bundle: NSBundle)
Declaration
From
init!(bundle bundle: NSBundle!)
To
init(bundle bundle: NSBundle)

Modified NSPreferencePane.initialKeyView
Declaration
From
var initialKeyView: NSView!
To
var initialKeyView: NSView?

Modified NSPreferencePane.lastKeyView
Declaration
From
var lastKeyView: NSView!
To
var lastKeyView: NSView?

Modified NSPreferencePane.loadMainView() -> NSView
Declaration
From
func loadMainView() -> NSView!
To
func loadMainView() -> NSView

Modified NSPreferencePane.mainNibName
Declaration
From
var mainNibName: String! { get }
To
var mainNibName: String { get }

Modified NSPreferencePane.mainView
Declaration
From
var mainView: NSView!
To
var mainView: NSView

Modified NSPreferencePane.updateHelpMenuWithArray(_: [[String : String]]?)
Declaration
From
func updateHelpMenuWithArray(_ inArrayOfMenuItems: [AnyObject]!)
To
func updateHelpMenuWithArray(_ inArrayOfMenuItems: [[String : String]]?)

Modified NSPreferencePaneUnselectReply [enum]
DeclarationProtocolsIntroductionRaw Value Type
From
struct NSPreferencePaneUnselectReply {
    init(_ value: UInt32)
    var value: UInt32
}
--OS X 10.10--
To
enum NSPreferencePaneUnselectReply : UInt {
    case UnselectCancel
    case UnselectNow
    case UnselectLater
}
Equatable, Hashable, RawRepresentableOS X 10.11UInt

Modified NSPreferencePaneUnselectReply.UnselectCancel
NameDeclarationIntroduction
FromNSUnselectCancel
var NSUnselectCancel: NSPreferencePaneUnselectReply { get }
OS X 10.10
ToUnselectCancel
case UnselectCancel
OS X 10.11

Modified NSPreferencePaneUnselectReply.UnselectLater
NameDeclarationIntroduction
FromNSUnselectLater
var NSUnselectLater: NSPreferencePaneUnselectReply { get }
OS X 10.10
ToUnselectLater
case UnselectLater
OS X 10.11

Modified NSPreferencePaneUnselectReply.UnselectNow
NameDeclarationIntroduction
FromNSUnselectNow
var NSUnselectNow: NSPreferencePaneUnselectReply { get }
OS X 10.10
ToUnselectNow
case UnselectNow
OS X 10.11