fluttercommunity / fluttercommunity/chewie
The judgment of whether it is the Android platform is a question
- Dominant language
- Dart
- Stars
- 2.1k
- Forks
- 1.1k
- Avg merge
- 6d 8h
- Merged PRs (30d)
- 6
Description
final isAndroid = Theme.of(context).platform == TargetPlatform.android;
I need to swipe back or center the title of the appbar, or some other IOS feature to use on Android
so I set the `ThemeData` platform is `TargetPlatform.iOS`.
i think you should use `defaultTargetPlatform` or `Platform.isAndroid` to judgment the device os
Contributor guide
No contributing guide indexed for this repository
Research direction
Start by locating the Chewie code that checks Theme.of(context).platform and compare it with the platform-detection alternatives named in the issue. Reproduce the behavior with ThemeData.platform set to TargetPlatform.iOS on Android, then verify that Android-specific behavior still follows the device platform rather than the theme setting.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- dart, flutter
- Domain
- mobile-dev
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100