WatchOS 8 pressing one of the side buttons dismisses modal sheet - swift

The behavior of the crown button on the Apple Watch has always been to close your app and take you to your Home Screen / watch face. Now when I build my watch app with Xcode 13 and WatchOS 8 when I press one of the side buttons it dismisses whatever modal sheet I have in my app.
This is a terrible user experience as my app is a workout app and I want my users to quickly get to other apps such as music while they are working out without closing everything out.
Apple's workout app presents a modal to add a workout but when I hit the side button in their app it takes me to the Home Screen. I have tried to watch all the latest videos and read the documentation but I don't see anywhere that I can disable this new functionality of the side buttons. Anyone know how I can change the physical side button behavior for my app? Thank you for your help!

It is a new feature. Add .interactiveDismissDisabled() to the content on the sheet or fullScreenCover.
https://developer.apple.com/documentation/swiftui/navigationview/interactivedismissdisabled(_:)

This is working as intended, it got changed in WatchOS 8.
Your best bet would be to submit it to Apple feature assistant.

Related

Swiftui sheets on mac app doesn't work properly

When attempting to use sheets on a Mac OS app, it's not interactable (sliding down to go back to the previous view) like on iOs. Is this normal or would I need a workaround to go back to the previous view?
You’ll need a close button on macOS, there is no dismissal gesture. If your app supports iOS too, it’s probably wise to have a close button there too — not all iPad users are familiar with the gesture, and the gesture doesn’t work on landscape phones.

Going back from Calendar to my app

Im my app, I have this code at a given time:
UIApplication.sharedApplication().openURL(NSURL(string: "calshow://")!)
which takes you to the calendar of the device. How could I get back to the scene where that line is executed?
Thank you.
EDIT:
Pressing home (option+shift+h, since the frame is not shown in my iOS Simulator) takes you to home, not the app, as it should be.
A quote from this:
Unlike other platforms such as Android, iPhone does not create a stack of actions (back stacking on Android). What this means is that if you do decide to launch another application, your application will not resume when the user exits from the application you opened.
If user want to get back to your app, they should press home (option+shift+H) twice, and select the your application from the list.
iOS9 introduced a new "Back-To-App" button at top-left corner, which allow you get back to your application. You should see this button after the calendar is showed from your app.

iPhone - hide assistive touch view programmatically

Does anyone know how to hide assistive touch view programmatically like Apple Music App does when playing video?
There is no SDK method to hide the assistive view.
Apple iPod App is done by Apple, so the App is probably using some private / undocumented SDK calls.
Yes there is. Go to Settings then General then Accessibility then Triple Click Home. Now choose Assistive Touch. Now whenever you want it to disappear just triple click the Home button on either the actual iPhone or using the Assustive Touch icon itself. Poof and its gone! To bring it back just triple click again.

IPhone: Why does my app resume and not restart when I relaunch it on device?

I don't know if this is an iOS4 thing or something, but basically say I have a few screens in my app. Now, when I hit the home button and relaunch my app it launches the app on the screen where I left off. It's almost like it's not restarting my app, but resumes it. I don't want it to do that. (I'd like it to show my splash screen main menu, etc. )
Does anyone know how to resolve this? thanks
In iOS 4, apps are suspended (not terminated) when the home button is pressed. When you "relaunch" the app, it is simply moved to the foreground. If you want your app to terminate when the user presses the home button, set the value of UIApplicationExitsOnSuspend to YES in your app's Info.plist file. If you do this, when the user taps the home button the applicationWillTerminate: method of your app delegate will be called and then your application will terminate.
I think this should help you. Basically what you need to do is disable the multi-tasking features of iOS4.
http://www.iphonedevsdk.com/forum/iphone-sdk-development/60989-disable-multi-tasking-ios4-application.html
That's exactly the multi-tasking you asked about yesterday working behind the scenes. You need to opt-out if you want that behavior. See answers to your previous question here. Have you read the answers there???

Tap to focus on camera apps, Supposedly not possible, but a bug in my app enables it (although useless)

I would like to get tap to focus in my app and the controls are hidden
Supposedly this is impossible but I know its not. I have a simple iAD dragged into an overlay, no code or anything. When I click on the iAD nothing. but when I close it with the home button I get a modal exit of the nonexistant iAD and the camera apps relaunches but in the top left with only a small portion viewable. But this time the tap to focus is enabled.
So how can I do this without the bug?
Thanks!
Guess no one got it? I just showed the controls to take a snap and zoom and focus came up!