This repository has been archived by the owner on Oct 9, 2023. It is now read-only.
Enable Xamarin.Forms AppTheme on legacy devices #1
Labels
enhancement
New feature or request
good first issue
Good for newcomers
help wanted
Extra attention is needed
Xamarin.Forms has a very useful markup extension for AppThemes which can be used to change the UI of your app depending on if the theme on the device is light or dark.
However, there is one small issue
and considering that Android 10 only has around 25% of the android market (July 2020), that leaves a large amount of users without access to AppTheme.
I have devised a simple way to add in 'support' for these devices with the following snippet
However this overrides the normal AppTheme functionality for devices that do support it.
It also cannot be built in directly into BrightnessService as it needs the Application from Xamarin forms.
It also needs the ability to allow for user manual overrides.
these are some preprocessor codes I initially thought of that outline the API's required for the normal operation of AppTheme
This issue is to track
The text was updated successfully, but these errors were encountered: