I was just stymied by a bug report of a hotkey not working in my app that I couldn't reproduce.
It turned out that Mission Control hijacks Ctrl-arrow hotkeys, but I have all that turned off on my system.
How do you check a hotkey you're planning to use in your app against ones in use by the OS? A Web search on this issue turns up plenty of questions but no answers that I've seen.
Another annoyance is that the menu bar showed that the hotkey was going to work.
Selecting any option will automatically load the page
Post
Replies
Boosts
Views
Activity
My app has a lot of buttons that indicate their "on" state with a special image, assigned in Interface Builder to the Selected state. There's a different image assigned to the Default state, for "off."
I found that when the user tapped a button that was "on," iOS insisted on redrawing it with the Default image. It turns out that Interface Builder misrepresents button states as exclusive:
default
highlighted
selected
disabled
Wrong. For example, a button can be selected AND highlighted. That was the problem in my case, which you can solve programmatically by doing a union of states like this:
thirdsButton.setImage(UIImage(named: "frame_guide_3x3"), for: UIControl.State.selected.union(.highlighted))
That actually does work... but it breaks "highlighted adjusts image," where iOS will dim the button slightly on contact. Now the user doesn't get any feedback upon pressing the button.
Known defect?
After a minor source-code change, my project wouldn't build anymore; Xcode raised dozens of errors complaining about a missing module and loads of other issues.
Lately Xcode (13.1) has been spewing spurious errors on a regular basis, highlighting allegedly erroneous source lines with repeated instances of the same complaint... but declaring 'build succeeded" in the status bar at the top of the screen and running the app successfully. This is happening on two systems, one Intel and the other Apple Silicon. I've not found any explanation. Cleaning and deleting DerivedData don't fix it.
So I've learned to ignore these "errors." But this time the build really was failing, so I looked at the first error. Xcode had inserted a line (into a years-old file) that attempted to import a nonexistent module. The name ("SwiftProtobufTests") appears in the package-definition file of a subproject (which builds Google protocol-buffer support in Swift). But it's not referred to or used anywhere, and I certainly didn't change anything in this source file related to it.
Has anybody else had this happen?
Xcode seems to have suffered from major regressions lately; it's barely stable enough to use right now. There are other insidious signs of internal problems. For example, when Xcode offers to "fix" an erroneous line (whether the error is real or not), it often inserts the fix into the wrong place in the text, garbling it and causing syntax errors.
It also inserts missing cases in switch statements (after the "must be exhaustive" error) at the wrong level in the hierarchy, also causing an error.
Again, this is happening on two systems, one a brand-new M1 Pro that was set up from scratch.
I had just uploaded a new build of my app and it had been processed. I went to submit it for beta testing, when I noticed another build with the next build number "processing." But I never submitted any such build.
I went back to my project and double-checked the version number. It was what I expected it to be: one lower than this mysterious build that suddenly appeared.
App Store Connect now shows that this mystery build is ready to be submitted.
I'm the only developer on this app. Has anyone seen this before? Thanks!
Our QA team is trying to test our application on all platforms we support, but Apple has inexplicably blocked installation of TestFlight on OS 11.
Does anyone know the rationale behind this, or how we're supposed to distribute test builds in an orderly manner now? Having to make ad-hoc builds piecemeal and E-mail them around with duplicated instructions is not exactly professional.
Thanks for any insight!
Our application is available for current and previous generations of Mac OS. But our QA team can't test it, because Apple has inexplicably blocked previous OSes from TestFlight.
Does anyone have an explanation for this idiotic policy?
I'm not talking about the Music service (or MusicKit); I mean for adding functions to the desktop Apple Music software.
I need to duck the audio coming from ApplicationMusicPlayer while playing a local file using AVAudioPlayer.
I've tried using the duckOthers option as follows, but it doesn't work:
let appAudioSession = AVAudioSession.sharedInstance()
do
{
try appAudioSession.setCategory(.playAndRecord, mode: .default, options: .duckOthers)
Maybe this is because there's one session for the entire app, and ApplicationMusicPlayer is using it?
This is a fairly critical problem for my application, since Music content is always much louder than locally recorded content. Any insight appreciated.
I suddenly noticed that changes I made in code had no effect on the app when I rebuilt it and ran it on my M1 Mac as a "made for iPad" target. The debugger will even stop on new lines and seem to execute them, but they do nothing. If I clean the build folder and re-run, the same line executes as expected.
This wastes an incredible amount of time until you discover what's happening. Now I have to remember to clean build folder every time I build and run.
The application's structure is very simple, with no included libraries or third-party dependencies.
Anybody else seeing this?
Xcode 15.3 under Sonoma (14.4.1).