Skip to content

Commit e9b8113

Browse files
committed
Package now builds on iOS, tvOS, watchOS and visionOS
1 parent bb3c810 commit e9b8113

File tree

6 files changed

+24
-0
lines changed

6 files changed

+24
-0
lines changed

Sources/MenuBarExtraAccess/MenuBarExtra Window Introspection.swift

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,8 @@
44
// © 2023 Steffan Andrews • Licensed under MIT License
55
//
66

7+
#if os(macOS)
8+
79
import SwiftUI
810

911
extension View {
@@ -25,3 +27,5 @@ extension View {
2527
}
2628
}
2729
}
30+
31+
#endif

Sources/MenuBarExtraAccess/MenuBarExtraAccess.swift

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,8 @@
44
// © 2023 Steffan Andrews • Licensed under MIT License
55
//
66

7+
#if os(macOS)
8+
79
import SwiftUI
810
import Combine
911

@@ -146,3 +148,5 @@ struct MenuBarExtraAccess<Content: Scene>: Scene {
146148
}
147149
}
148150
}
151+
152+
#endif

Sources/MenuBarExtraAccess/MenuBarExtraUtils.swift

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,8 @@
44
// © 2023 Steffan Andrews • Licensed under MIT License
55
//
66

7+
#if os(macOS)
8+
79
import AppKit
810
import SwiftUI
911
import Combine
@@ -311,3 +313,5 @@ extension MenuBarExtraUtils {
311313
return String("\(anyView)".hashValue)
312314
}
313315
}
316+
317+
#endif

Sources/MenuBarExtraAccess/NSStatusItem Extensions.swift

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,8 @@
44
// © 2023 Steffan Andrews • Licensed under MIT License
55
//
66

7+
#if os(macOS)
8+
79
import AppKit
810
import SwiftUI
911

@@ -87,3 +89,5 @@ extension NSStatusItem {
8789
button?.publisher(for: \.cell!.state, options: [.initial, .new])
8890
}
8991
}
92+
93+
#endif

Sources/MenuBarExtraAccess/NSWindow Extensions.swift

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,8 @@
44
// © 2023 Steffan Andrews • Licensed under MIT License
55
//
66

7+
#if os(macOS)
8+
79
import AppKit
810

911
extension NSWindow /* actually NSStatusBarWindow but it's a private AppKit type */ {
@@ -16,3 +18,5 @@ extension NSWindow /* actually NSStatusBarWindow but it's a private AppKit type
1618
?? Mirror(reflecting: self).descendant("statusItem") as? NSStatusItem
1719
}
1820
}
21+
22+
#endif

Sources/MenuBarExtraAccess/Unused/Unused Code.swift

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,8 @@
44
// © 2023 Steffan Andrews • Licensed under MIT License
55
//
66

7+
#if os(macOS)
8+
79
import SwiftUI
810
import Combine
911

@@ -48,3 +50,5 @@ extension Scene {
4850
return nil
4951
}
5052
}
53+
54+
#endif

0 commit comments

Comments
 (0)