Skip to content

feat(device_info_plus): Add iOS device identifiers for iPhone 18 Pro and iPhone 18 Pro Max - #3993

Merged
vbuberen merged 1 commit into
fluttercommunity:mainfrom
stackflowdev:feat/device-info-plus-iphone-18-pro
Sep 30, 2026
Merged

vbuberen merged 1 commit into
fluttercommunity:mainfrom
stackflowdev:feat/device-info-plus-iphone-18-pro

Conversation

@stackflowdev

Copy link
Copy Markdown
Contributor

Description

Adds the iOS device identifiers of the iPhone 18 Pro and the iPhone 18 Pro Max. Without them IosDeviceInfo.modelName returns Unknown device on both phones.

Identifier Name
iPhone19,2 iPhone 18 Pro
iPhone19,3 iPhone 18 Pro Max (United States)
iPhone19,7 iPhone 18 Pro Max (other regions)

The two Pro Max identifiers are regional variants of one phone, so they share one branch, the way the iPhone XS Max pair (iPhone11,4, iPhone11,6) does.

The identifiers and names come from Apple's own tables:

  • macOS 27.0, /System/Library/CoreServices/CoreTypes.bundle/Contents/Library/MobileDevices-0001.bundle/Contents/Info.plist: iPhone19,2 (V63AP) is described as "iPhone 18 Pro", and iPhone19,3 and iPhone19,7 (V64AP, V64sAP) as "iPhone 18 Pro Max".
  • Xcode 27.0 (27A266a) simulator profiles: modelIdentifier is iPhone19,2 for iPhone 18 Pro and iPhone19,3 for iPhone 18 Pro Max.

iPhone19,4 is left out: the same macOS table lists it with no marketing name yet.

How it was checked: DeviceIdentifiers.m compiles with -Wall -Werror for iOS devices and the simulator; a small harness calling +userKnownDeviceModel: returns the new names for all three identifiers, still returns Unknown device for iPhone19,4, and returns the same names as before for existing identifiers; clang-format leaves the file unchanged; the package's unit tests pass; and dart analyze --fatal-infos finds no issues with the example linked to the local package, as melos bootstrap links it.

Related Issues

None.

Checklist

  • I read the Contributor Guide and followed the process outlined there for submitting PRs.
  • I titled the PR using Conventional Commits.
  • I did not modify the CHANGELOG.md nor the plugin version in pubspec.yaml files.
  • All existing and new tests are passing.
  • The analyzer (flutter analyze) does not report any problems on my PR.

Breaking Change

Does your PR require plugin users to manually update their apps to accommodate your change?

  • Yes, this is a breaking change (please indicate that with a ! in the title as explained in Conventional Commits).
  • No, this is not a breaking change.

🤖 Generated with Claude Code

…and iPhone 18 Pro Max

The table stops at the iPhone 17 family, so `modelName` returns
"Unknown device" on both new phones.

- iPhone19,2: iPhone 18 Pro
- iPhone19,3 and iPhone19,7: iPhone 18 Pro Max. They are two regional
  variants of one phone, so they share one branch, the way the
  iPhone XS Max pair does.

The identifiers and names are Apple's own. macOS 27.0's device table
(CoreTypes.bundle, MobileDevices-0001.bundle) describes iPhone19,2 as
"iPhone 18 Pro" and iPhone19,3 and iPhone19,7 as "iPhone 18 Pro Max",
and the simulator profiles of Xcode 27.0 give iPhone19,2 and iPhone19,3
for the two phones.

iPhone19,4 is left out: the same macOS table lists it with no marketing
name yet.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@stackflowdev

Copy link
Copy Markdown
Contributor Author

The two red checks are not from this change:

  • analyze fails on android_intent_plus (19 deprecated_member_use infos for LocalPlatform and FakePlatform), the same failure as the push to main at 2df7ac5 this branch is based on. In this run device_info_plus, device_info_plus_platform_interface and device_info_plus_example all report "No issues found!".
  • android_integration_test (32) failed before any test ran: Gradle could not download kotlin-compiler-embeddable-2.2.20.jar (HTTP 500 from github.com). The same test passed on API 24, 29 and 36, so a re-run should clear it.

The change itself touches only the iOS DeviceIdentifiers.m.

@vbuberen
vbuberen merged commit 59f6543 into fluttercommunity:main Sep 30, 2026
18 of 21 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants