mac/remote: move class local struct and enum definition to extension

the class local struct and enum are moved to an extension to separate
their definition and usage.
This commit is contained in:
der richter 2024-02-06 21:15:56 +01:00
parent 80cde2671c
commit 1883f2f7a0
1 changed files with 3 additions and 1 deletions

View File

@ -17,7 +17,7 @@
import MediaPlayer
class RemoteCommandCenter: NSObject {
extension RemoteCommandCenter {
enum KeyType {
case normal
case repeatable
@ -33,7 +33,9 @@ class RemoteCommandCenter: NSObject {
self.type = type
}
}
}
class RemoteCommandCenter: NSObject {
var configs: [MPRemoteCommand:Config] = [
MPRemoteCommandCenter.shared().pauseCommand: Config(key: MP_KEY_PAUSEONLY),
MPRemoteCommandCenter.shared().playCommand: Config(key: MP_KEY_PLAYONLY),