Hacktoberfest 2026:メンテナが10月に向けて印を付けた、オープンで初心者向けの issue。 Hacktoberfest の issue を見る

Dynamic Colors doesn't update

オープン
#560 コメント 4 件 リアクション 0 件 担当者 0 名 GitHub で見る

メンテナーはふだん 1 日以内に返信

まだ誰も着手していません。

評価

難易度
4/5
見積もり時間
3〜5日
初心者へのやさしさ
63/100
issue の種類
バグ
明瞭さ
おおむね明確
活発さ
活発
技術スタック
android, kotlin
領域
mobile-dev

調査の方向性

Start by reading latin/common/Colors.kt and the KeyboardSwitcher.updateKeyboardThemeAndContextThemeWrapper() path called from onStartInputView; compare how the settings screen and keyboard obtain their contexts and check colors. Reproduce the reported palette change, then verify that opening the keyboard picks up the new colors without force-stopping LeanType.

索引モデルが issue の本文から書いたものです。

説明

bug

As said by claude
Describe the bug
When the system Material You palette changes while LeanType is running, the keyboard with the Dynamic colors theme keeps showing the old colors. LeanType's settings screen updates to the new palette right away, but the keyboard doesn't update until LeanType is force-stopped.

To Reproduce

  1. Select the Dynamic colors keyboard theme.
  2. Change the system Material You palette. In my case, ColorBlendr (Shizuku mode) re-applies colors each time Paperize sets a new static wallpaper. Changing colors manually in ColorBlendr gives the same result.
  3. Open LeanType settings: the new colors are shown correctly.
  4. Open the keyboard in any text field: it still shows the previous palette.
  5. Force-stop LeanType and open the keyboard again: the new colors appear.

Expected behavior
The keyboard picks up the new system palette the next time it's shown, like the settings screen does.

Screenshots
N/A

App version & Flavor
[version, e.g. v4.2.x] / standard

Device Info

  • Model: Samsung Galaxy Z Fold 6
  • OS version: [Android version] / One UI [version]

Additional context (possible cause)
From reading the source, this might be the cause (unconfirmed):

  • DynamicColors (latin/common/Colors.kt) reads system_accent* / system_neutral* once in its constructor.
  • KeyboardSwitcher.updateKeyboardThemeAndContextThemeWrapper() checks mColors.haveColorsChanged(context) on onStartInputView, but the context passed in is displayContext, which is created once in onInitializeInterface() and reused.
  • If that long-lived context keeps returning the old system_* values after the theme overlay changes, haveColorsChanged() returns false and the theme never reloads. The settings activity gets a fresh context, so it isn't affected.

Workaround: force-stopping LeanType loads the current colors.

主要言語
Kotlin
スター
1k
フォーク
59
平均マージ
13時間 21分
マージ済み PR(30日)
48

環境構築

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

LeanBitLab/LeanType のほかの issue

LeanBitLab/LeanType の issue をすべて見る

似ている issue

Kotlin の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。