Post

Replies

Boosts

Views

Activity

Request review without having a view controller?
SKStoreReviewController.requestReview() is deprecated in favor of AppStore.requestReview(in:). The problem is that AppStore.requestReview(in:) requires passing in a NSViewController, and in some contexts, this is not possible. For example, a menu bar app that only has a NSMenu when you click it. It has no NSViewController that could be passed in. How are we supposed to request a review for such apps? FB14887376
1
1
503
Aug ’24
Detect if the active keyboard on macOS has a physical `Fn` key in Swift
I want to use the Fn modifier key if available, and if not, offer the user a different modifier. But only offer it to users without a Fn key. Some external keyboard do not have a Fn key. Is there any way to detect whether the active keyboard has a physical Fn key? (I am not asking how to detect a Fn key press) I'm looking for a solution in Swift that works within a sandboxed app. I already tried asking on Stack Overflow.
0
1
796
May ’22
How to use `.focusedSceneObject()` with @Observable?
According to docs, .focusedObject() usage should be moved to .focusedValue() when migrating to @Observable, but there is no .focusedSceneValue() overload that accepts Observable like with .focusedValue(). So how are we supposed migrate .focusedSceneObject() to @Observable?
Replies
2
Boosts
1
Views
917
Activity
Jun ’25
Request review without having a view controller?
SKStoreReviewController.requestReview() is deprecated in favor of AppStore.requestReview(in:). The problem is that AppStore.requestReview(in:) requires passing in a NSViewController, and in some contexts, this is not possible. For example, a menu bar app that only has a NSMenu when you click it. It has no NSViewController that could be passed in. How are we supposed to request a review for such apps? FB14887376
Replies
1
Boosts
1
Views
503
Activity
Aug ’24
How to convert 10-bit HEIC image to 16-bit PNG with Image I/O on macOS?
I'm trying to convert a 10-bit HEIC image to a 16-bit PNG, but it ends up 8-bit PNG. Is there any way to force it to be 16-bit? I'm using CGImageSourceCreateWithURL on macOS.
Replies
2
Boosts
0
Views
1.8k
Activity
Sep ’22
Detect if the active keyboard on macOS has a physical `Fn` key in Swift
I want to use the Fn modifier key if available, and if not, offer the user a different modifier. But only offer it to users without a Fn key. Some external keyboard do not have a Fn key. Is there any way to detect whether the active keyboard has a physical Fn key? (I am not asking how to detect a Fn key press) I'm looking for a solution in Swift that works within a sandboxed app. I already tried asking on Stack Overflow.
Replies
0
Boosts
1
Views
796
Activity
May ’22