Add advanced animation and trigger options for Next Up and taskbar widget#233
Add advanced animation and trigger options for Next Up and taskbar widget#233FunnyTHEWorld wants to merge 5 commits intounchihugo:masterfrom
Conversation
…dget Introduces a new advanced animation option for the Next Up window, including a new animation sequence and UI controls. Refactors the taskbar widget trigger from a boolean clickable property to a multi-option trigger type (None, OnHover, Click), updates related UI and localization, and adjusts default durations and settings for improved user experience.
There was a problem hiding this comment.
Pull request overview
This PR introduces advanced animation capabilities for the "Next Up" window and refactors the taskbar widget interaction model from a simple boolean toggle to a three-option trigger system (None, OnHover, Click). The changes enhance user customization and visual polish while updating default durations and localization strings across multiple languages.
- Added a sophisticated entrance animation system for the Next Up window with configurable blur effects, transforms, and storyboard sequences
- Refactored taskbar widget trigger from boolean
TaskbarWidgetClickableto integer-basedTaskbarWidgetTriggerTypewith three interaction modes - Introduced
ImageHelperclass for extracting dominant colors from album artwork to enhance UI theming
Reviewed changes
Copilot reviewed 9 out of 9 changed files in this pull request and generated 22 comments.
Show a summary per file
| File | Description |
|---|---|
| FluentFlyoutWPF/Windows/TaskbarWindow.xaml.cs | Refactored click handler to support three trigger types (None, OnHover, Click) and updated brush usage to use theme resources |
| FluentFlyoutWPF/Windows/NextUpWindow.xaml.cs | Added complex entrance animation logic with configurable duration ratios and integrated ImageHelper for dominant color extraction |
| FluentFlyoutWPF/Windows/NextUpWindow.xaml | Restructured XAML to support advanced animations with blur effects, transforms, and gradient backgrounds |
| FluentFlyoutWPF/ViewModels/UserSettings.cs | Added IsNextUpAdvancedAnimationEnabled property, changed TaskbarWidgetClickable to TaskbarWidgetTriggerType, and updated default NextUpDuration to 2500ms |
| FluentFlyoutWPF/SettingsWindow.xaml | Replaced ToggleSwitch with ComboBox for taskbar widget trigger selection and added new CardControl for animation toggle |
| FluentFlyoutWPF/Resources/Localization/Dictionary-zh-TW.xaml | Updated default NextUpDuration description from 2000ms to 2500ms |
| FluentFlyoutWPF/Resources/Localization/Dictionary-zh-CN.xaml | Added localization for advanced animation settings and updated trigger option descriptions |
| FluentFlyoutWPF/Resources/Localization/Dictionary-en-US.xaml | Added localization strings for trigger types and advanced animation feature with updated descriptions |
| FluentFlyoutWPF/Classes/ImageHelper.cs | New helper class for extracting dominant colors from images with fallback logic for near-white/black images |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| var startTimePoint1 = 0; | ||
| AddAnim("TitleBlur", "Radius", 8, 0, 0.5, startTimePoint1*durationRatio, new CubicEase { EasingMode = EasingMode.EaseOut }); | ||
|
|
||
| // Background | ||
| AddAnim("BackgroundTranslate", "Y", 20, 0, 0.6, 0, new CubicEase { EasingMode = EasingMode.EaseOut }); | ||
| AddAnim("BackgroundScale", "ScaleX", 0, 1, 0.8, 0, new CubicEase { EasingMode = EasingMode.EaseOut }); | ||
| AddAnim("BackgroundScale", "ScaleY", 0, 1, 0.8, 0, new CubicEase { EasingMode = EasingMode.EaseOut }); | ||
| AddAnim("BackgroundBorder", "Opacity", 0, 1, 0.8, 0); | ||
| var startTimePoint2 = 0.5*durationRatio; | ||
| AddAnim("BackgroundBorder", "Opacity", null, 0, 2, startTimePoint2); // fade out | ||
| AddAnim("BackgroundTranslate", "X", 0, backgroundTranslateXTo, 1.2,startTimePoint2, new CubicEase { EasingMode = EasingMode.EaseIn }); | ||
|
|
||
| var startTimePoint3 = 0.6 * durationRatio; | ||
| // Title scale back | ||
| AddAnim("TitleScale", "ScaleX", null, 1, 0.5, startTimePoint3, new CubicEase { EasingMode = EasingMode.EaseOut }); | ||
| AddAnim("TitleScale", "ScaleY", null, 1, 0.5, startTimePoint3, new CubicEase { EasingMode = EasingMode.EaseOut }); | ||
|
|
||
| // Title Y back to 0 | ||
| AddAnim("TitleTranslate", "Y", null, 0, 1, startTimePoint3, new CubicEase { EasingMode = EasingMode.EaseInOut }); | ||
|
|
||
| // Note: Original had TitleTranslate.X animation with no From/To → skip (no effect) | ||
| AddAnim("TitleTranslate", "X", 0, titleTranslateXTo, 1.1, startTimePoint3, new CubicEase { EasingMode = EasingMode.EaseInOut }); |
There was a problem hiding this comment.
Inconsistent time calculation. The beginSec parameter is multiplied by durationRatio in lines 138, 145, and others, but the multiplication happens inconsistently. For example, line 138 uses startTimePoint1*durationRatio while line 145 uses startTimePoint2 directly (where startTimePoint2 was already computed as 0.5*durationRatio). This creates confusion about whether the time points should be pre-multiplied or multiplied at usage time. Consider either pre-multiplying all time points or multiplying all at usage time for consistency.
Basically, when existing users update to this version, their interaction preference will be reset since the TaskbarWidgetClickable has been removed. By migrating the setting to the new variable when starting the app (assigning TaskbarWidgetClickable = false to TaskbarWidgetTriggerType = 0, and TaskbarWidgetClickable = true to TaskbarWidgetTriggerType = 2) we can prevent the migration issue. On top of that, let's make TaskbarWidgetTriggerType default to 2. Copilot worded it nicely as well:
|
TaskbarWidgetTriggerType = 1 --> 2;
Got it! my bad, I 've updated and resolved conflicts |
|
I hope you merge this PR @unchihugo . 😭 this looks fantastic. |

This pull request introduces a new advanced animation option for the "Next Up" window, improves the dominant color extraction for images, and enhances user configurability and localization for the taskbar widget and "Next Up" features. The most significant changes include the addition of a customizable animation for the "Next Up" window, a new helper class for image color analysis, and refactoring of the taskbar widget trigger logic and settings.
Key changes:
"Next Up" Window Enhancements
Image Processing
ImageHelperclass with methods to extract the dominant color from aBitmapSource, including handling for near-white/black images and accent color extraction.Taskbar Widget Configuration Improvements
ComboBox, and adjusted related property names and logic. [1] [2] [3] [4] [5] [6]UI and Settings
Topmost="True".These changes collectively improve user experience by providing more customization, a visually enhanced "Next Up" window, and better handling of image colors for UI theming.
Introduces a new advanced animation option for the Next Up window, including a new animation sequence and UI controls. Refactors the taskbar widget trigger from a boolean clickable property to a multi-option trigger type (None, OnHover, Click), updates related UI and localization, and adjusts default durations and settings for improved user experience.
Readjusted animation duration to 1700ms and default window duration was set to 2500ms(Animations will be strange if quicker),and animations are already binded to duration of settings
Added
I still not quite get it,TaskbarWidgetClickable was replaced by TaskbarWidgetTriggerType (int, 0 -> flase, 1 -> OnHover, 2 -> true(Click)) and showed in a combobox
QQ20251222-16485-HD.mp4