1
1
mirror of https://github.com/danbee/persephone synced 2025-03-04 08:39:11 +00:00
persephone/Persephone/Preferences/Controllers/AlbumArtPrefsController.swift
Dan Barber fe748e2c61
WIP: Refactor MPDClient
This should make handling the queuing side work more reliably.
2019-03-20 20:06:23 -04:00

38 lines
847 B
Swift

//
// AlbumArtPrefsController.swift
// Persephone
//
// Created by Daniel Barber on 2019/2/23.
// Copyright © 2019 Dan Barber. All rights reserved.
//
import Cocoa
class AlbumArtPrefsController: NSViewController {
var preferences = Preferences()
override func viewDidLoad() {
super.viewDidLoad()
if let mpdLibraryDir = preferences.mpdLibraryDir {
mpdLibraryDirField.stringValue = mpdLibraryDir
}
preferredContentSize = NSMakeSize(view.frame.size.width, view.frame.size.height)
}
override func viewDidAppear() {
super.viewDidAppear()
guard let title = title
else { return }
self.parent?.view.window?.title = title
}
@IBAction func updateMpdLibraryDir(_ sender: NSTextField) {
preferences.mpdLibraryDir = sender.stringValue
}
@IBOutlet var mpdLibraryDirField: NSTextField!
}