Post

Replies

Boosts

Views

Activity

Applying NSLayoutConstraints makes NSTableView unresponsive
In MacOS app I present modally NSTableView. The table is created in IB and its data and functionality are handled in corresponding NSViewController. As long as the positioning of modally presented table is left to the system, the tableview is placed in the center of the presenting view controller and everything works fine. But if I apply NSLayoutConstraints to position it as I need for visual design reasons, the table stops responding to mouse clicks. Here's the code inside the presenting view controller: bookmarks_TVC = Bookmarks_TVC() bookmarks_TVC.view.translatesAutoresizingMaskIntoConstraints = false self.present(bookmarks_TVC, animator: ModalPresentationAnimator()) NSLayoutConstraint.activate([ self.bookmarks_TVC.view.leadingAnchor.constraint(equalTo: self.view.leadingAnchor, constant:410), self.bookmarks_TVC.view.topAnchor.constraint(equalTo: self.view.topAnchor, constant: 170) ]) Once again, without NSLayoutConstraints the table responds as expected. Once the constraints are added, it becomes unresponsive. Thanks in advance for any helpful suggestions.
0
0
263
Dec ’24
Speech Recognition Problem in iOS 18.0
It looks like Apple has added some new API(s) to SFSpeechRecognition My app, which is currently listed on App Store does feature speech recognition. Yet, trying to use it under iOS 18.0 throws errors: -[SFSpeechRecognitionTask localSpeechRecognitionClient:speechRecordingDidFail:]_block_invoke Ignoring subsequent local speech recording error: Error Domain=kAFAssistantErrorDomain Code=1101 "(null)" What happens is that after several words are transcribed and displayed, the next sentence results in previous words disappearance. That's probably what that portion of the error text - "Ignoring subsequent local speech recording error: Error Domain=kAFAssistantErrorDomain Code=1101 "(null)" means. The problem occurs ONLY when the app is running under iOS 18.0 Even when it's compiled in Xcode 16.0 using iOS 17.5 everything works fine. Any suggestions?
37
9
5.1k
Aug ’24
WKWebView audio volume control
Using WKWebView in iOS, I encountered a problem with controlling audio output level from <audio> element in HTML page.I tried the 'volume' property of the <audio> and also the Web Audio API 'GainNode'. Neither approach worked. The player's output stays/reported as 1.0.Curiously, within the same scope of code I can change player's other properties such as playback rate; this does work. But calls to 'volume' or 'GainNode' are flatly ignored. Two observations make me believe that this is a bug.The first one: if I use instead of WKWebView the old deprecated UIWebView, everything works fine; even Web Audio API AudioContext, Splitter, Merger, etc.The second observation: in the version of the app for macOS the very same HTML page and <audio> element behave as expected.Any suggestions for 'workaround' would be much appreciated,Igor Borodin
2
1
5.8k
Jul ’17