[PR #2988] [MERGED] [PM-5913] Fix for MAUI not reporting the correct Theme when resuming an iOS App #97317

Closed
opened 2026-05-30 22:04:23 -05:00 by GiteaMirror · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/bitwarden/android/pull/2988
Author: @dinisvieira
Created: 2/8/2024
Status: Merged
Merged: 2/9/2024
Merged by: @dinisvieira

Base: mainHead: feature/PM-5913-fix-for-ios-theme-when-resuming-2


📝 Commits (2)

  • 410b285 PM-5913 Fix for incorrect iOS Theme when resuming iOS app. Also added minor DeviceInfo change and InvokeOnMainThread is on ThemeManager even though it can be moved elsewhere.
  • 59c4a7b PM-5913 removed redundant iOS check and changed #elif to #else

📊 Changes

1 file changed (+36 additions, -9 deletions)

View changed files

📝 src/Core/Utilities/ThemeManager.cs (+36 -9)

📄 Description

Type of change

  • Bug fix
  • New feature development
  • Tech debt (refactoring, code cleanup, dependency upgrades, etc)
  • Build/deploy pipeline (DevOps)
  • Other

Objective

We want to implement a fix/workaround for MAUI not reporting the correct Theme when resuming an iOS App.

Code changes

  • ThemeManager.cs: Added iOS/Android specific implementations for OsDarkModeEnabled() so that we can directly fetch the Theme on the iOS API for the iOS implementation.

Before you submit

  • Please check for formatting errors (dotnet format --verify-no-changes) (required)
  • Please add unit tests where it makes sense to do so (encouraged but not required)
  • If this change requires a documentation update - notify the documentation team
  • If this change has particular deployment requirements - notify the DevOps team

🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/bitwarden/android/pull/2988 **Author:** [@dinisvieira](https://github.com/dinisvieira) **Created:** 2/8/2024 **Status:** ✅ Merged **Merged:** 2/9/2024 **Merged by:** [@dinisvieira](https://github.com/dinisvieira) **Base:** `main` ← **Head:** `feature/PM-5913-fix-for-ios-theme-when-resuming-2` --- ### 📝 Commits (2) - [`410b285`](https://github.com/bitwarden/android/commit/410b2855bdd43781093e8c2234fb70b253a71920) PM-5913 Fix for incorrect iOS Theme when resuming iOS app. Also added minor DeviceInfo change and InvokeOnMainThread is on ThemeManager even though it can be moved elsewhere. - [`59c4a7b`](https://github.com/bitwarden/android/commit/59c4a7bcf1e3657e54b936c01c504f2b6675657f) PM-5913 removed redundant iOS check and changed #elif to #else ### 📊 Changes **1 file changed** (+36 additions, -9 deletions) <details> <summary>View changed files</summary> 📝 `src/Core/Utilities/ThemeManager.cs` (+36 -9) </details> ### 📄 Description ## Type of change - [x] Bug fix - [ ] New feature development - [ ] Tech debt (refactoring, code cleanup, dependency upgrades, etc) - [ ] Build/deploy pipeline (DevOps) - [ ] Other ## Objective We want to implement a fix/workaround for MAUI not reporting the correct Theme when resuming an iOS App. ## Code changes * **ThemeManager.cs:** Added iOS/Android specific implementations for OsDarkModeEnabled() so that we can directly fetch the Theme on the iOS API for the iOS implementation. ## Before you submit - Please check for formatting errors (`dotnet format --verify-no-changes`) (required) - Please add **unit tests** where it makes sense to do so (encouraged but not required) - If this change requires a **documentation update** - notify the documentation team - If this change has particular **deployment requirements** - notify the DevOps team --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
GiteaMirror added the pull-request label 2026-05-30 22:04:23 -05:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/android#97317