Skip to content

Fix appearance changed into wrong activity#34

Merged
Kudo merged 1 commit intoexp-latestfrom
@kudo/eng-11171-appearance-setcolorscheme-does-not-work-on-android
Jan 23, 2024
Merged

Fix appearance changed into wrong activity#34
Kudo merged 1 commit intoexp-latestfrom
@kudo/eng-11171-appearance-setcolorscheme-does-not-work-on-android

Conversation

@Kudo
Copy link

@Kudo Kudo commented Jan 23, 2024

Why

fixes expo/expo#26556
close ENG-11171

How

the original AppCompatDelegate.setDefaultNightMode() is a global setup. when changing the night mode, it will actually call HomeActivity's onConfigurationChanged. this pr tries to set night mode to current activity by using the setLocalNightMode()

Test Plan

unversioned expo-go with repro from expo/expo#26556

@linear
Copy link

linear bot commented Jan 23, 2024

@Kudo Kudo requested review from alanjhughes and lukmccall January 23, 2024 10:02
@Kudo Kudo merged commit cf55a59 into exp-latest Jan 23, 2024
@Kudo Kudo deleted the @kudo/eng-11171-appearance-setcolorscheme-does-not-work-on-android branch January 23, 2024 10:20
@Kudo Kudo mentioned this pull request Jan 23, 2024
2 tasks
Kudo added a commit to expo/expo that referenced this pull request Jan 23, 2024
# Why

fixes #26556
fixes #26561
close ENG-11171
close ENG-11173

# How

- the #26556 appearance issue was resolved by
expo/react-native#34. i've cherry-picked the fix
to both sdk-49 and sdk-50 branch of react-native-lab fork.
- the #26561 was coming from incompatible fresco versions. since fresco
was bumped from react-native 0.73, we should re-version sdk-49 aar with
new fresco. here's what i did

# Test Plan

tested on the local versioned release build expo-go
- #26556 for both sdk-49 and sdk-50
- #26561 doesn't have a repro but i can copy a repro from
https://github.com/jobtoday/react-native-image-viewing/tree/master/example
gabrieldonadel pushed a commit that referenced this pull request Mar 13, 2024
the original `AppCompatDelegate.setDefaultNightMode()` is a global setup. when changing the night mode, it will actually call HomeActivity's `onConfigurationChanged`. this pr tries to set night mode to current activity by using the `setLocalNightMode()`
alanjhughes pushed a commit that referenced this pull request Jun 4, 2024
the original `AppCompatDelegate.setDefaultNightMode()` is a global setup. when changing the night mode, it will actually call HomeActivity's `onConfigurationChanged`. this pr tries to set night mode to current activity by using the `setLocalNightMode()`
gabrieldonadel pushed a commit that referenced this pull request Aug 5, 2024
the original `AppCompatDelegate.setDefaultNightMode()` is a global setup. when changing the night mode, it will actually call HomeActivity's `onConfigurationChanged`. this pr tries to set night mode to current activity by using the `setLocalNightMode()`
gabrieldonadel pushed a commit that referenced this pull request Aug 22, 2024
the original `AppCompatDelegate.setDefaultNightMode()` is a global setup. when changing the night mode, it will actually call HomeActivity's `onConfigurationChanged`. this pr tries to set night mode to current activity by using the `setLocalNightMode()`
gabrieldonadel pushed a commit that referenced this pull request Aug 12, 2025
the original `AppCompatDelegate.setDefaultNightMode()` is a global setup. when changing the night mode, it will actually call HomeActivity's `onConfigurationChanged`. this pr tries to set night mode to current activity by using the `setLocalNightMode()`
gabrieldonadel pushed a commit that referenced this pull request Aug 15, 2025
the original `AppCompatDelegate.setDefaultNightMode()` is a global setup. when changing the night mode, it will actually call HomeActivity's `onConfigurationChanged`. this pr tries to set night mode to current activity by using the `setLocalNightMode()`
gabrieldonadel pushed a commit that referenced this pull request Aug 27, 2025
the original `AppCompatDelegate.setDefaultNightMode()` is a global setup. when changing the night mode, it will actually call HomeActivity's `onConfigurationChanged`. this pr tries to set night mode to current activity by using the `setLocalNightMode()`
gabrieldonadel pushed a commit that referenced this pull request Sep 9, 2025
the original `AppCompatDelegate.setDefaultNightMode()` is a global setup. when changing the night mode, it will actually call HomeActivity's `onConfigurationChanged`. this pr tries to set night mode to current activity by using the `setLocalNightMode()`
gabrieldonadel pushed a commit that referenced this pull request Sep 10, 2025
the original `AppCompatDelegate.setDefaultNightMode()` is a global setup. when changing the night mode, it will actually call HomeActivity's `onConfigurationChanged`. this pr tries to set night mode to current activity by using the `setLocalNightMode()`
gabrieldonadel pushed a commit that referenced this pull request Sep 10, 2025
the original `AppCompatDelegate.setDefaultNightMode()` is a global setup. when changing the night mode, it will actually call HomeActivity's `onConfigurationChanged`. this pr tries to set night mode to current activity by using the `setLocalNightMode()`
gabrieldonadel pushed a commit that referenced this pull request Sep 23, 2025
the original `AppCompatDelegate.setDefaultNightMode()` is a global setup. when changing the night mode, it will actually call HomeActivity's `onConfigurationChanged`. this pr tries to set night mode to current activity by using the `setLocalNightMode()`
gabrieldonadel pushed a commit that referenced this pull request Sep 30, 2025
the original `AppCompatDelegate.setDefaultNightMode()` is a global setup. when changing the night mode, it will actually call HomeActivity's `onConfigurationChanged`. this pr tries to set night mode to current activity by using the `setLocalNightMode()`
gabrieldonadel pushed a commit that referenced this pull request Oct 8, 2025
the original `AppCompatDelegate.setDefaultNightMode()` is a global setup. when changing the night mode, it will actually call HomeActivity's `onConfigurationChanged`. this pr tries to set night mode to current activity by using the `setLocalNightMode()`
alanjhughes pushed a commit that referenced this pull request Oct 21, 2025
the original `AppCompatDelegate.setDefaultNightMode()` is a global setup. when changing the night mode, it will actually call HomeActivity's `onConfigurationChanged`. this pr tries to set night mode to current activity by using the `setLocalNightMode()`
gabrieldonadel pushed a commit that referenced this pull request Oct 21, 2025
the original `AppCompatDelegate.setDefaultNightMode()` is a global setup. when changing the night mode, it will actually call HomeActivity's `onConfigurationChanged`. this pr tries to set night mode to current activity by using the `setLocalNightMode()`
gabrieldonadel pushed a commit that referenced this pull request Dec 8, 2025
the original `AppCompatDelegate.setDefaultNightMode()` is a global setup. when changing the night mode, it will actually call HomeActivity's `onConfigurationChanged`. this pr tries to set night mode to current activity by using the `setLocalNightMode()`
gabrieldonadel pushed a commit that referenced this pull request Dec 11, 2025
the original `AppCompatDelegate.setDefaultNightMode()` is a global setup. when changing the night mode, it will actually call HomeActivity's `onConfigurationChanged`. this pr tries to set night mode to current activity by using the `setLocalNightMode()`
gabrieldonadel pushed a commit that referenced this pull request Dec 18, 2025
the original `AppCompatDelegate.setDefaultNightMode()` is a global setup. when changing the night mode, it will actually call HomeActivity's `onConfigurationChanged`. this pr tries to set night mode to current activity by using the `setLocalNightMode()`
gabrieldonadel pushed a commit that referenced this pull request Feb 10, 2026
the original `AppCompatDelegate.setDefaultNightMode()` is a global setup. when changing the night mode, it will actually call HomeActivity's `onConfigurationChanged`. this pr tries to set night mode to current activity by using the `setLocalNightMode()`
gabrieldonadel pushed a commit that referenced this pull request Feb 11, 2026
the original `AppCompatDelegate.setDefaultNightMode()` is a global setup. when changing the night mode, it will actually call HomeActivity's `onConfigurationChanged`. this pr tries to set night mode to current activity by using the `setLocalNightMode()`
gabrieldonadel pushed a commit that referenced this pull request Feb 11, 2026
the original `AppCompatDelegate.setDefaultNightMode()` is a global setup. when changing the night mode, it will actually call HomeActivity's `onConfigurationChanged`. this pr tries to set night mode to current activity by using the `setLocalNightMode()`
gabrieldonadel pushed a commit that referenced this pull request Feb 27, 2026
the original `AppCompatDelegate.setDefaultNightMode()` is a global setup. when changing the night mode, it will actually call HomeActivity's `onConfigurationChanged`. this pr tries to set night mode to current activity by using the `setLocalNightMode()`
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.

Appearance setColorScheme does not work on Android

2 participants