feat: add Windows title bar theme synchronization#2005
Closed
ChouChiu wants to merge 1 commit into
Closed
Conversation
Owner
|
为什么移除了 window_manager 的使用,改为了自定义实现, window_manager 有什么问题吗 |
Owner
|
在 #1961 的早期实现中,window_manager 表现的很好 |
Contributor
Author
|
我尝试让 AI 回退到 |
Owner
|
我在周末尝试一下 |
Contributor
Author
|
有进展吗 |
Owner
|
我还没找到比较好的解决方案 |
Contributor
Author
|
这个 PR 是否是一个可用的 workaround |
Owner
|
此外我刚刚看了一下这个PR的实现,Qwen3.6 Plus 明显是个比 GLM5.1 更糟糕的模型,它假设 menthodChannel 会失败并在失败时回退到 windowManager 意义不明 如果最近 coding plan 涨价与断货没有太好的选择的话,可以试试 opencode go |
Contributor
Author
emm,我有看过,等现在的到期了我试试。 |
Owner
|
这个PR本身的实现思路我个人不是很认可,并且 Qwen 在具体的实施过程中代码也有问题 所以很抱歉我不能接受这个PR,如果没有你对这方面不是很熟悉,并且也没有比较厉害的模型帮助你的话,也许我们可以换个问题看看 这个问题留给我来解决 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
由 Qwen 3.6 Plus 生成, fix #1757
Copilot's Summary:
This pull request introduces a new mechanism for synchronizing the Windows title bar theme with the app's theme, using a native Windows API via a custom Flutter MethodChannel. This replaces the previous approach that relied on the
window_managerplugin, ensuring more reliable and immediate updates to the title bar appearance when the app theme changes or when the system brightness changes. The changes also clean up redundant or now-unnecessary code related to the old approach.Windows Title Bar Theme Synchronization:
com.predidit.kazumi/titlebar) to the Windows runner, usingDwmSetWindowAttributeto set immersive dark mode for the title bar, bypassing registry checks and system-wide theme dependencies. (windows/runner/flutter_window.cpp,windows/runner/flutter_window.h) [1] [2] [3] [4]lib/app_widget.dart) to use the new MethodChannel for syncing the Windows title bar theme on app startup, theme changes, and platform brightness changes. Falls back to the old plugin if the native call fails. [1] [2] [3] [4]Code Cleanup and Refactoring:
window_manager.setBrightnessfrom theme settings and theme change handlers, as these responsibilities are now handled by the new native channel. (lib/pages/settings/theme_settings_page.dart) [1] [2]