Platform
UIKit
iOS
UIActivityViewController
Environment
Device (issue reported): iPhone 16
iOS Version: 26.2
App Type: UIKit / Swift (standard modal presentation of UIActivityViewController)
Summary
When presenting UIActivityViewController to share a CSV file, the share sheet does not allow vertical scrolling, making lower actions (including Save to Files) unreachable.
The same flow works correctly when sharing a PDF, and the issue cannot be reproduced on other test devices.
Steps to Reproduce
Launch the app and log in
Navigate to More → Reports
Tap Export Report
Choose Export Report (CSV)
Observe the share sheet
Expected Result
The user should be able to vertically scroll the share sheet
All share actions (including Save to Files) should be reachable
Actual Result
Share sheet opens but vertical scrolling is disabled
Lower options (including Save to Files) are not reachable
No crash or console errors
UIKit
RSS for tagConstruct and manage graphical, event-driven user interfaces for iOS or tvOS apps using UIKit.
Posts under UIKit tag
200 Posts
Selecting any option will automatically load the page
Post
Replies
Boosts
Views
Activity
I run into a layout problem where I cannot center an image inside ScrollView which is also inside Navigation Controller. The problem is surely the fact that there is a navigation bar because using this view without NavigationContoller works fine and the image is centered but I don’t know how to account for the space that navigation bar takes up.
Here is the code:
import UIKit
class PhotoViewController: UIViewController {
var photoName: String
private lazy var photoView = {
let image = UIImageView()
image.translatesAutoresizingMaskIntoConstraints = false
image.contentMode = .scaleAspectFit
image.clipsToBounds = true
return image
}()
var photoViewBottomConstraint: NSLayoutConstraint?
var photoViewLeadingConstraint: NSLayoutConstraint?
var photoViewTopConstraint: NSLayoutConstraint?
var photoViewTrailingConstraint: NSLayoutConstraint?
private lazy var scrollView = {
let sv = UIScrollView()
sv.translatesAutoresizingMaskIntoConstraints = false
return sv
}()
override func viewDidLoad() {
super.viewDidLoad()
setupUI()
}
override func viewWillLayoutSubviews() {
super.viewWillLayoutSubviews()
updateMinZoomScaleForSize(view.bounds.size)
}
func updateMinZoomScaleForSize(_ size: CGSize) {
let widthScale = size.width / photoView.bounds.width
let heightScale = size.height / photoView.bounds.height
let minScale = min(widthScale, heightScale)
scrollView.minimumZoomScale = minScale
scrollView.zoomScale = minScale
}
func setupUI() {
photoView.image = UIImage(named: photoName)
scrollView.delegate = self
view.addSubview(scrollView)
scrollView.addSubview(photoView)
setupConstraints()
}
func setupConstraints() {
NSLayoutConstraint.activate([
scrollView.leadingAnchor.constraint(equalTo: view.safeAreaLayoutGuide.leadingAnchor),
scrollView.topAnchor.constraint(equalTo: view.safeAreaLayoutGuide.topAnchor),
scrollView.trailingAnchor.constraint(equalTo: view.safeAreaLayoutGuide.trailingAnchor),
scrollView.bottomAnchor.constraint(equalTo: view.safeAreaLayoutGuide.bottomAnchor)
])
photoViewLeadingConstraint = NSLayoutConstraint(
item: photoView,
attribute: .leading,
relatedBy: .equal,
toItem: scrollView,
attribute: .leading,
multiplier: 1,
constant: 0
)
photoViewTopConstraint = NSLayoutConstraint(
item: photoView,
attribute: .top,
relatedBy: .equal,
toItem: scrollView,
attribute: .top,
multiplier: 1,
constant: 0
)
photoViewTrailingConstraint = NSLayoutConstraint(
item: photoView,
attribute: .trailing,
relatedBy: .equal,
toItem: scrollView,
attribute: .trailing,
multiplier: 1,
constant: 0
)
photoViewBottomConstraint = NSLayoutConstraint(
item: photoView,
attribute: .bottom,
relatedBy: .equal,
toItem: scrollView,
attribute: .bottom,
multiplier: 1,
constant: 0
)
photoViewLeadingConstraint?.isActive = true
photoViewTopConstraint?.isActive = true
photoViewTrailingConstraint?.isActive = true
photoViewBottomConstraint?.isActive = true
}
init(photoName: String) {
self.photoName = photoName
super.init(nibName: nil, bundle: nil)
}
required init?(coder: NSCoder) {
fatalError("init(coder:) has not been implemented")
}
}
extension PhotoViewController: UIScrollViewDelegate {
func viewForZooming(in scrollView: UIScrollView) -> UIView? {
photoView
}
func scrollViewDidZoom(_ scrollView: UIScrollView) {
updateConstraintsForSize(view.bounds.size)
}
func updateConstraintsForSize(_ size: CGSize) {
let yOffset = max(0, (size.height - photoView.frame.height) / 2)
photoViewTopConstraint?.constant = yOffset
photoViewBottomConstraint?.constant = yOffset
let xOffset = max(0, (size.width - photoView.frame.width) / 2)
photoViewLeadingConstraint?.constant = xOffset
photoViewTrailingConstraint?.constant = xOffset
view.layoutIfNeeded()
}
}
Hello,
We are seeing an intermittent crash when initializing a base UITableView with Apple's [initWithFrame:style:] initializer.
Crash stack:
Role: Foreground
OS Version: iOS 26.1
Exception Type: EXC_BREAKPOINT
Exception Subtype: KERN_INVALID_ADDRESS
EXC_BREAKPOINT:
0 libswiftCore.dylib +0x1358c0 _assertionFailure(_:_:file:line:flags:)
1 UIKitCore +0x1fdca0 0x188c26ca0 (0x188c26b20 + 384)
2 UIKitCore +0x1ffa60 0x188c28a60 (0x188c2890c + 340)
3 UIKitCore +0x2012d0 0x188c2a2d0 (0x188c2a1ec + 228)
4 UIKitCore +0x200f20 0x188c29f20 (0x188c29cac + 628)
5 UIKitCore +0x200428 0x188c29428 (0x188c29384 + 164)
6 UIKitCore +0x18af7f4 -[UITableMetricsAdapter _updateSharedSectionMetricsForListGeometry:]
7 UIKitCore +0x201da8 -[UITableMetricsAdapter tableBackgroundColor]
8 UIKitCore +0x1643a44 ___39-[UITableView _applyAppearanceDefaults]_block_invoke
9 UIKitCore +0x196f3d0 +[UIView _performSystemAppearanceModifications:]
10 UIKitCore +0x1643978 -[UITableView _applyAppearanceDefaults]
11 UIKitCore +0x202854 -[UITableView _setupTableViewCommon]
12 UIKitCore +0x1643760 -[UITableView initWithFrame:style:]
13 Application +0x30b6a40 closure #1 in variable initialization expression of MyAppClass.tableView
14 Application +0x30b6ef0 MyAppClass.init(frame:)
Has anyone else seen something like this?
Any insights or advice is much appreciated, thank you!
I am building an app for iOS and MacCatalyst that indexes files by storing their local paths. Because the app relies on the file remaining at its original location, I only want to accept items that can be opened in place.
I am struggling to determine if an item is "Open In Place" compatible early in the drag-and-drop lifecycle. Specifically:
In dropInteraction(_:canHandle:) and dropInteraction(_:sessionDidUpdate:), calling itemProvider.registeredTypeIdentifiers(fileOptions: [.openInPlace]) returns an empty array.
Only once the drop is actually committed in dropInteraction(_:performDrop:) does that same call return the expected type identifiers.
This creates a poor user experience. I want to validate the "In Place" capability at the very start of the session so the drop target only activates for valid files. If an item is ephemeral (like a dragged photo from the Photos app or a temporary export), the drop zone should not react at all.
How can I reliably detect if an NSItemProvider supports .openInPlace before the performDrop delegate method is called?
Topic:
App & System Services
SubTopic:
General
Tags:
Mac Catalyst
UIKit
Files and Storage
Foundation
Hi all,
I’m seeing a lifecycle behavior change on iOS 26.0 (and up).
While my app is in the foreground and active, pressing the hardware Lock button triggers didBecomeActive callbacks/notifications even though the app is transitioning away from active state.
I’m observing this sequence:
willResignActive
didBecomeActive
willResignActive
didEnterBackground
This happens for:
• UISceneDelegate.sceneDidBecomeActive(:)
• UIApplicationDelegate.applicationDidBecomeActive(:)
• UIApplication.didBecomeActiveNotification
On iOS 18 (same app, same code) I do not see didBecomeActive in the middle of locking/backgrounding.
Problem is reproduced on totally new project.
I would expect a normal transition to background:
• willResignActive → didEnterBackground
…and no extra didBecomeActive between them.
I have “became active” logic (refresh UI/state, resume timers, analytics). On iOS 26.0 this logic runs unexpectedly during locking, causing unnecessary work and incorrect state transitions.
Is this callback ordering expected on iOS 26.0 when pressing the Lock button?
If expected, what’s the recommended way to detect a “real” activation (and avoid transient didBecomeActive during locking/backgrounding)?
If this is a regression, is there a known workaround or best practice?
What works
let backButton = UIBarButtonItem(title: "", style: .plain, target: nil, action: nil)
backButton.hidesSharedBackground = true
self.navigationItem.rightBarButtonItem = backButton
// or
self.navigationItem.leftBarButtonItem = backButton
What doesn't work
let backButton = UIBarButtonItem(title: "", style: .plain, target: nil, action: nil)
backButton.hidesSharedBackground = true
self.navigationItem.backBarButtonItem = backButton
I've tried setting this property on all possible permutations and combinations e.g. Inside navigationController(_ navigationController: UINavigationController, willShow viewController: UIViewController, animated: Bool) and pushViewController(_ viewController: UIViewController, animated: Bool) of a custom UINavigationController to make sure.
Expected vs Actual behavior
Setting hidesSharedBackground = true should remove the glass background from both regular bar button items and back bar button items but it has no effect on backBarButtonItem.
Additional context
I’m aware of the UIDesignRequiresCompatibility Info.plist key, but I’m looking for a programmatic solution if there is one. The goal is to remove the glass background from back buttons.
My app start up has became horrid. It takes 1 minute to open SQLlite database for my rust core. Impossible to work...
I have Address Sanitizer, Thread Perf Checker and Thread Sanitizer disabled...
I just found a weird bug:
If you place a Text view using .foregroundStyle(.secondary), .tertiary, or other semantic colors inside a ScrollView, and apply a Material background clipped to an UnevenRoundedRectangle, the text becomes invisible. This issue does not occur when:
The text uses .primary or explicit colors (e.g., .red, Color.blue), or
The background is clipped to a standard shape (e.g., RoundedRectangle).
A minimal reproducible example is shown below:
ScrollView{
VStack {
Image(systemName: "globe")
.imageScale(.large)
.foregroundStyle(.tint)
Text("Hello World.")
.font(.system(size: 15))
.foregroundStyle(.quinary)
}
}
.padding()
.frame(height: 100)
.background(Material.regular)
.clipShape(UnevenRoundedRectangle(topLeadingRadius: 10,bottomLeadingRadius: 8,bottomTrailingRadius:8, topTrailingRadius: 8))
I had take screenshots by following code
let scenes = UIApplication.shared.connectedScenes
let windowScene = scenes.first as? UIWindowScene
let window = windowScene?.windows.first
self.uiImage = window?.rootViewController?.view!.getImage(rect: rect)
View has two views. One is ImageView contains some image and overlay of image detection results with .overlay. another view is InfoView contains several info and button which above code fired. on iOS 17, I can take screenshots as I saw, but on iOS26, missing on image of ImageView. Overlay(detected rectangle) in Imageview and InfView can be taken.
How can I take screenshots as I saw on iOS26?(iPad)
I’ve notice that in Maps, some pins contain images and do not have the little triangle at the bottom of it, yet they still animate the same when clicked. How could this be achieved? I believe the name of this annotation is MKMapFeatureAnnotation.
I've tried this and it did not give the same result. I'm able to create a custom MKMarkerAnnotationView but it does not animate the same (balloon animation like the MKMapFeatureAnnotation). I was looking forward to create a custom MKMapFeatureAnnotation similar in design which would animate the same. Unfortunately, I cannot create a custom MKMapFeatureAnnotation because everything is privated
When using UITraitBridgedEnvironmentKey to pass a trait value to the swift environment, it causes a crash when trying to access the value from the environment.
The issue seems to be related to how swift uses the UITraitBridgedEnvironmentKey protocol since the crash occurs in swift::_getWitnessTable () from lazy protocol witness table accessor…. It can occur when calling any function that is generic using the UITraitBridgedEnvironmentKey type.
I originally encountered the issue when trying to use a UITraitBridgedEnvironmentKey in SwiftUI, but have been able to reproduce the issue with any function with a similar signature.
https://developer.apple.com/documentation/swiftui/environmentvalues/subscript(_:)-9zku
Steps to Reproduce
Requirements for the issue to occur
Project with a minimum iOS version of iOS 16
Build the project with Xcode 26
Run on iOS 18
Add the following code to a project and call foo(key: MyCustomTraitKey.self) from anywhere.
@available(iOS 17.0, *)
func foo<K>(key: K.Type) where K: UITraitBridgedEnvironmentKey {
// Crashes before this is called
}
@available(iOS 17.0, *)
public enum MyCustomTraitKey: UITraitBridgedEnvironmentKey {
public static let defaultValue: Bool = false
public static func read(from traitCollection: UITraitCollection) -> Bool { false }
public static func write(to mutableTraits: inout UIMutableTraits, value: Bool) {}
}
// The crash will occur when calling this. It can be added to a project anywhere
// The sample project calls it from scene(_:willConnectTo:options:)
foo(key: MyCustomTraitKey.self)
For example, I added it to the SceneDelegate in a UIKit Project
class SceneDelegate: UIResponder, UIWindowSceneDelegate {
var window: UIWindow?
func scene(_ scene: UIScene, willConnectTo session: UISceneSession, options connectionOptions: UIScene.ConnectionOptions) {
if #available(iOS 17, *) {
// The following line of code can be placed anywhere in a project, `SceneDelegate` is just a convenient place to put it to reproduce the issue.
foo(key: MyCustomTraitKey.self)
// ^ CRASH: Thread 1: EXC_BAD_ACCESS (code=1, address=0x10)
}
}
}
Actual Behaviour
The app crashes with the stack trace showing the place calling foo but before foo is actually called. (ie, a breakpoint or print in foo is never hit)
#0 0x000000019595fbc4 in swift::_getWitnessTable ()
#1 0x0000000104954128 in lazy protocol witness table accessor for type MyCustomTraitKey and conformance MyCustomTraitKey ()
#2 0x0000000104953bc4 in SceneDelegate.scene(_:willConnectTo:options:) at .../SceneDelegate.swift:20
The app does not crash when run on iOS 17, or 26 or when the minimum ios version is raised to iOS 17 or higher.
It also doesn't crash on iOS 16 since it's not calling foo since UITraitBridgedEnvironmentKey was added in iOS 17.
Expected behaviour
The app should not crash. It should call foo on iOS 17, 18, and 26.
Our app supports UIScene. As a result, launchOptions in application(_:didFinishLaunchingWithOptions:) is always nil.
However, the documentation mentions that UIApplication.LaunchOptionsKey.location should be present when the app is launched due to a location event.
Given that our app is scene-based:
How can we reliably determine whether the app was launched due to a location update, geofence, or significant location change?
Is there a recommended pattern or API to detect this scenario in a Scene-based app lifecycle?
This information is critical for us to correctly initialize location-related logic on launch.
Relevant documentation:
https://developer.apple.com/documentation/corelocation/cllocationmanager/startmonitoringsignificantlocationchanges()
1. Summary
In a hybrid iOS app using WKWebView (Angular + Capacitor), after programmatically blurring an element and connecting a Bluetooth keyboard, pressing Ctrl+Home or Ctrl+End causes the app to crash.
The crash stack shows the issue occurs inside UIKit keyboard handling (UITextInteractionSelectableInputDelegate _moveToStartOfLine), indicating a system-level bug.
2. Steps to Reproduce
Open the hybrid app containing a WKWebView.
Blur the input (programmatically).
Connect a Bluetooth keyboard.
Press Ctrl + Home or Ctrl + End.
Expected result:
No crash. The command should be ignored if no text input is active.
Actual result:
App crashes immediately.
3. Crash Log (Crashlytics Trace)
Crashed: com.apple.main-thread
0 WebKit 0xfbdad0 <redacted> + 236
1 UIKitCore 0x10b0548 -[UITextInteractionSelectableInputDelegate _moveToStartOfLine:withHistory:] + 96
2 UIKitCore 0xd0fb38 -[UIKBInputDelegateManager _moveToStartOfLine:withHistory:] + 188
3 UIKitCore 0xa16174 __158-[_UIKeyboardStateManager handleMoveCursorToStartOfLine:beforePublicKeyCommands:testOnly:savedHistory:force:canHandleSelectableInputDelegateCommand:keyEvent:]_block_invoke + 52
4 UIKitCore 0xa36ae4 -[_UIKeyboardStateManager performBlockWithTextInputChangesIgnoredForNonMacOS:] + 48
5 UIKitCore 0xa160f0 -[_UIKeyboardStateManager handleMoveCursorToStartOfLine:beforePublicKeyCommands:testOnly:savedHistory:force:canHandleSelectableInputDelegateCommand:keyEvent:] + 440
6 UIKitCore 0xa06614 -[_UIKeyboardStateManager handleKeyCommand:repeatOkay:options:] + 3204
7 UIKitCore 0xa2fb64 -[_UIKeyboardStateManager _handleKeyCommandCommon:options:] + 76
8 UIKitCore 0xa2fb08 -[_UIKeyboardStateManager _handleKeyCommand:] + 20
9 UIKitCore 0xa30684 -[_UIKeyboardStateManager handleKeyEvent:executionContext:] + 2464
10 UIKitCore 0xa2f95c __42-[_UIKeyboardStateManager handleKeyEvent:]_block_invoke + 40
11 UIKitCore 0x4b9460 -[UIKeyboardTaskEntry execute:] + 208
12 UIKitCore 0x4b92f4 -[UIKeyboardTaskQueue continueExecutionOnMainThread] + 356
13 UIKitCore 0x4b8be0 -[UIKeyboardTaskQueue addTask:breadcrumb:] + 120
14 UIKitCore 0xa2f8d0 -[_UIKeyboardStateManager handleKeyEvent:] + 432
15 CoreFoundation 0x2f934 __invoking___ + 148
16 CoreFoundation 0x2efac -[NSInvocation invoke] + 424
17 UIKitCore 0x14cbcc4 -[UIRepeatedAction invoke] + 176
18 UIKitCore 0x14cbeb8 -[UIRepeatedAction _preInvocationTimerFire] + 56
19 UIKitCore 0x1195364 -[UIApplication _handleKeyboardPressEvent:] + 2192
20 UIKitCore 0x1187278 -[UIApplication pressesBegan:withEvent:] + 328
21 UIKitCore 0x9b808 forwardTouchMethod + 376
22 UIKitCore 0x9b808 forwardTouchMethod + 376
23 UIKitCore 0x9b808 forwardTouchMethod + 376
24 UIKitCore 0x9b808 forwardTouchMethod + 376
25 UIKitCore 0x9b808 forwardTouchMethod + 376
26 UIKitCore 0x9b808 forwardTouchMethod + 376
27 UIKitCore 0x9b808 forwardTouchMethod + 376
28 UIKitCore 0x9b808 forwardTouchMethod + 376
29 WebKit 0x66e2b4 <redacted> + 84
30 UIKitCore 0x9b808 forwardTouchMethod + 376
31 UIKitCore 0x157290c -[UIScrollView pressesBegan:withEvent:] + 148
32 UIKitCore 0x9b808 forwardTouchMethod + 376
33 WebKit 0xfbbd04 <redacted> + 100
34 UIKitCore 0x11a7620 -[UIWindow _sendButtonsForEvent:] + 312
35 UIKitCore 0x522dc -[UIWindow sendEvent:] + 568
36 UIKitCore 0x5f508 -[UIApplication sendEvent:] + 376
37 UIKitCore 0x1194364 -[UIApplication _handleKeyUIEvent:] + 136
38 UIKitCore 0x11a3e14 -[UIResponder _handleKeyUIEvent:] + 56
39 UIKitCore 0x11a3e14 -[UIResponder _handleKeyUIEvent:] + 56
40 UIKitCore 0x11a3e14 -[UIResponder _handleKeyUIEvent:] + 56
41 UIKitCore 0x11a3e14 -[UIResponder _handleKeyUIEvent:] + 56
42 UIKitCore 0x11a3e14 -[UIResponder _handleKeyUIEvent:] + 56
43 UIKitCore 0x11a3e14 -[UIResponder _handleKeyUIEvent:] + 56
44 UIKitCore 0x11a3e14 -[UIResponder _handleKeyUIEvent:] + 56
45 UIKitCore 0x11a3e14 -[UIResponder _handleKeyUIEvent:] + 56
46 UIKitCore 0x11a3e14 -[UIResponder _handleKeyUIEvent:] + 56
47 UIKitCore 0x11a3e14 -[UIResponder _handleKeyUIEvent:] + 56
48 UIKitCore 0x11943e8 -[UIApplication handleKeyUIEvent:] + 56
49 UIKitCore 0x11942ac -[UIApplication _handleKeyHIDEvent:usingSyntheticEvent:] + 660
50 UIKitCore 0x117ac __dispatchPreprocessedEventFromEventQueue + 4648
51 UIKitCore 0xfbe4 __processEventQueue + 4812
52 UIKitCore 0x94e4 updateCycleEntry + 160
53 UIKitCore 0x9404 _UIUpdateSequenceRun + 84
54 UIKitCore 0x8ab4 schedulerStepScheduledMainSection + 208
55 UIKitCore 0x41e4 runloopSourceCallback + 92
56 CoreFoundation 0xf92c __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE0_PERFORM_FUNCTION__ + 28
57 CoreFoundation 0xf744 __CFRunLoopDoSource0 + 172
58 CoreFoundation 0xf5a0 __CFRunLoopDoSources0 + 232
59 CoreFoundation 0xff20 __CFRunLoopRun + 840
60 CoreFoundation 0x11adc CFRunLoopRunSpecific + 572
61 GraphicsServices 0x1454 GSEventRunModal + 168
62 UIKitCore 0x135274 -[UIApplication _run] + 816
63 UIKitCore 0x100a28 UIApplicationMain + 336
64 Order 0xa2ed0 main + 21 (AppDelegate.swift:21)
4. Environment
iPadOS versions: 18.1.0, 18.4.1, 18.6.2
WebView: WKWebView
Hybrid stack: Angular + (Capacitor)
Reproducible on multiple iPads and multiple iPadOS 18.x versions.
5. Expected Behavior
Pressing Ctrl+Home or Ctrl+End when no text input is active should be ignored and should not crash the app.
Hi there. I want to use Adobe XD for designing and prototyping apps, and I would like to get the UIKit design resources working. I downloaded it and tried to open it with Adobe XD, but it threw this error:
There was an error opening the file Apple iOS 26 UI Kit.sketch
(Error code: 115)
I really prefer to use the UIKit in Adobe XD rather than paying for Figma or Sketch. Thanks.
Apple Design Resources
In iOS 26, keyboardLayoutGuide does not provide the correct constraint when using third-party input method.
A demo’s source code is attached to FB18594298 to illustrate the issue.
The setup includes:
An inputAccessoryView above keyboard
An input box anchored to the top of the inputAccessoryView using the following constraint:
[self.view.keyboardLayoutGuide.topAnchor constraintEqualToAnchor:self.inputBoxContainerView.bottomAnchor]
Expected Behavior:
Before iOS 26, when keyboard toggled by clicking the input box, the input box should move above the inputAccessoryView.
Actual Behavior:
However, on iOS 26, when switching to a third-party IME (e.g. 百度输入法baidu,搜狗输入法sogou,微信输入法wechat), then click the input box, the input box is above the keyboard instead of the inputAccessoryView, and is covered by the inputAccessoryView.
I am struggling to change the tint of the back button in an UINavigationItem. In iOS 18.6 it looks like this
while on iOS 26 the same looks like this
I can live without the Dictionary but I'd like to get the blue color back.
In viewDidLoad() I have tried
navigationItem.backBarButtonItem?.tintColor = .link
but this did not work since navigationItem.backBarButtonItem is nil. My second attempt was
navigationController?.navigationBar.tintColor = .link
but this didn't work either.
I have even set the Global Tint to Link Color
but this had no effect either.
Does anyone have an idea how to change the tint of the back button in an UINavigationItem on iOS 26?
After reviewing the following Apple Technote, I have confirmed the statement below: https://developer.apple.com/documentation/technotes/tn3187-migrating-to-the-uikit-scene-based-life-cycle
In the next major release following iOS 26, UIScene lifecycle will be required when building with the latest SDK; otherwise, your app won’t launch. While supporting multiple scenes is encouraged, only adoption of scene life-cycle is required.
Based on the above, I would appreciate it if you could confirm the following points:
Is my understanding correct that the term “latest SDK” refers to Xcode 27?
Is it correct that an app built with the latest SDK (Xcode 27, assuming the above understanding is correct) will not launch without adopting the UIScene lifecycle, with no exceptions?
Is it correct that an app built with Xcode 26 without UIScene lifecycle support will still launch without issues on an iPhone updated to iOS 27?
Setup:
I have a segment view with 3 segments, and the last on (at index 2) is disabled.
Issue:
When I drag the liquid glass handle of the segment view from what was previously selected to the disabled segment, the liquid glass handle freezes mid-air.
Workaround:
I can still interact with the handle and manually restore its position, or tap on any other segment to restore its position.
Notes:
I'm using UIKit, and no extra customizations are applied.
class ViewController: UIViewController {
@IBOutlet weak var segmentView: UISegmentedControl!
override func viewDidLoad() {
super.viewDidLoad()
segmentView.removeAllSegments()
let segments = ["Option 1", "Option 2", "Option 3"]
for (index, title) in segments.enumerated() {
segmentView.insertSegment(withTitle: title, at: index, animated: false)
}
// Select the first one by default
segmentView.selectedSegmentIndex = 0
// Disable the last segment
segmentView.setEnabled(false, forSegmentAt: 2)
}
}
Hello!
I'm making a list of app icons for users to choose, but when I increase or decrease the font size, the image is still in the same spot and isn't centered vertically with the text. I have it initialized with a frame with hard-coded values, but I was wondering if there was a better way of doing it, such as with constraints or some sort of image scaling.
I've provided code blocks and an image of what is happening.
ImageView Configuration
// App Icon Image
UIImageView *appIconImageView = [[UIImageView alloc] initWithFrame: CGRectMake(12.5, 17, 22.5, 22.5)];
// Configurations
UIImageSymbolConfiguration *multicolorConfiguration = [UIImageSymbolConfiguration configurationPreferringMulticolor];
UIImageSymbolConfiguration *sizeConfiguration = [UIImageSymbolConfiguration configurationWithScale: UIImageSymbolScaleSmall];
UIImageSymbolConfiguration *appIconConfiguration = [multicolorConfiguration configurationByApplyingConfiguration: sizeConfiguration];
appIconImageView.preferredSymbolConfiguration = appIconConfiguration;
appIconImageView.contentMode = UIViewContentModeScaleAspectFill;
self.appIconImage = appIconImageView;
[appIconImageView release];
ImageView Constraints
[self.appIconImage.firstBaselineAnchor constraintEqualToAnchor: self.contentView.firstBaselineAnchor constant: 5.0],
[self.appIconImage.leadingAnchor constraintEqualToAnchor: self.contentView.layoutMarginsGuide.leadingAnchor],
// Label
[self.colorLabel.leadingAnchor constraintEqualToAnchor:self.appIconImage.trailingAnchor constant: 10],
[self.colorLabel.trailingAnchor constraintEqualToAnchor:self.contentView.layoutMarginsGuide.trailingAnchor],
[self.colorLabel.topAnchor constraintEqualToAnchor: self.contentView.layoutMarginsGuide.topAnchor],
[self.colorLabel.bottomAnchor constraintEqualToAnchor: self.contentView.layoutMarginsGuide.bottomAnchor],
Image
We are seeing a strange lifecycle issue on multiple MDM-managed iPads where
application(_:didFinishLaunchingWithOptions:) is not called after the device is idle overnight.
Even if we terminate the app manually via the app switcher, the next morning the system does not perform a cold launch. Instead, the app resumes directly in:
applicationDidBecomeActive(_:)
This causes all initialization logic that depends on didFinishLaunching to be completely skipped.
This behavior is consistent across four different supervised MDM devices.
Environment
Devices: iPads enrolled in MDM (supervised)
iOS version: 18.3
Xcode: 16.4
macOS: Sequoia 15.7.2
App type: Standard UIKit iOS app
App: Salux Audiometer (App Store app)
Expected Behavior
If the app was terminated manually using the app switcher, the next launch should:
Start a new process
Trigger application(_:didFinishLaunchingWithOptions:)
Follow the normal cold-start lifecycle
Actual Behavior
After leaving the iPad idle overnight (8–12 hours):
The next launch skips didFinishLaunching
The app resumes directly in applicationDidBecomeActive
No new process is started
App behaves as if it had been suspended, even though it was manually terminated
Logs (Relevant Extracts)
Day 1 — Normal cold launch
[12:06:44.152 PM] PROCESS_STARTED
[12:06:44.214 PM] DID_FINISH_LAUNCHING_START launchOptions=[]
[12:06:44.448 PM] DID_FINISH_LAUNCHING_END
We then used the app and terminated it via app switcher.
Day 2 — Unexpected resume without cold start
[12:57:49.328 PM] APP_DID_BECOME_ACTIVE
No PROCESS_STARTED
No didFinishLaunching
No cold-start logs
This means the OS resumed the app from a previous state that should not exist.
Reproducible Steps
Use an MDM-enrolled iPad.
Launch the app normally.
Terminate it manually via the multitasking app switcher.
Leave the device idle overnight (8–12 hours).
Launch the app the next morning.
Observe that:
didFinishLaunching does not fire
applicationDidBecomeActive fires directly
Questions for Apple Engineers / Community
Is this expected behavior on MDM-supervised devices in iOS 18?
Are there any known OS-level changes where terminated apps may be revived from disk/memory?
Could MDM restrictions or background restoration policies override app termination?
How can we ensure that our app always performs a clean initialization when launched after a long idle period?
Additional Information
We have full logs from four separate MDM iPads showing identical behavior.
Happy to share a minimal reproducible sample if required.