diff --git a/FluentFlyoutWPF/Controls/TaskbarWidgetControl.xaml.cs b/FluentFlyoutWPF/Controls/TaskbarWidgetControl.xaml.cs
index bc9bcaf1..823c666e 100644
--- a/FluentFlyoutWPF/Controls/TaskbarWidgetControl.xaml.cs
+++ b/FluentFlyoutWPF/Controls/TaskbarWidgetControl.xaml.cs
@@ -103,7 +103,7 @@ public void ApplyWindowsTheme()
private void Grid_MouseEnter(object sender, MouseEventArgs e)
{
- if (string.IsNullOrEmpty(SongTitle.Text + SongArtist.Text)) return;
+ if (!SettingsManager.Current.TaskbarWidgetClickable || (string.IsNullOrEmpty(SongTitle.Text) && string.IsNullOrEmpty(SongArtist.Text))) return;
SolidColorBrush targetBackgroundBrush;
// hover effects with animations, hard-coded colors because I can't find the resource brushes
@@ -146,7 +146,7 @@ private void Grid_MouseEnter(object sender, MouseEventArgs e)
private void Grid_MouseLeave(object sender, MouseEventArgs e)
{
- if (string.IsNullOrEmpty(SongTitle.Text + SongArtist.Text)) return;
+ if (!SettingsManager.Current.TaskbarWidgetClickable || (string.IsNullOrEmpty(SongTitle.Text) && string.IsNullOrEmpty(SongArtist.Text))) return;
// Animate back to transparent
var backgroundAnimation = new ColorAnimation
@@ -171,7 +171,7 @@ private void Grid_MouseLeave(object sender, MouseEventArgs e)
private void Grid_MouseLeftButtonUp(object sender, MouseButtonEventArgs e)
{
- if (_mainWindow == null) return;
+ if (!SettingsManager.Current.TaskbarWidgetClickable || _mainWindow == null) return;
// toggle main flyout when clicked
_mainWindow.ShowMediaFlyout(toggleMode: true, forceShow: true);
diff --git a/FluentFlyoutWPF/Pages/MediaFlyoutPage.xaml b/FluentFlyoutWPF/Pages/MediaFlyoutPage.xaml
index 6b3523f9..6b323f65 100644
--- a/FluentFlyoutWPF/Pages/MediaFlyoutPage.xaml
+++ b/FluentFlyoutWPF/Pages/MediaFlyoutPage.xaml
@@ -33,6 +33,7 @@
+
@@ -42,7 +43,7 @@
-
+
@@ -51,7 +52,16 @@
-
+
+
+
+
+
+
+
+
+
+
@@ -65,7 +75,7 @@
-
+
@@ -74,7 +84,7 @@
-
+
@@ -83,7 +93,7 @@
-
+
@@ -98,7 +108,7 @@
-
+
@@ -110,7 +120,7 @@
-
+
@@ -121,7 +131,7 @@
-
+
@@ -130,7 +140,7 @@
-
+
@@ -138,7 +148,7 @@
-
+
@@ -147,7 +157,7 @@
-
+
@@ -156,7 +166,7 @@
-
+
@@ -165,8 +175,8 @@
-
-
+
+
@@ -175,7 +185,7 @@
-
+
diff --git a/FluentFlyoutWPF/Pages/TaskbarWidgetPage.xaml b/FluentFlyoutWPF/Pages/TaskbarWidgetPage.xaml
index e2fda5fc..a6845678 100644
--- a/FluentFlyoutWPF/Pages/TaskbarWidgetPage.xaml
+++ b/FluentFlyoutWPF/Pages/TaskbarWidgetPage.xaml
@@ -31,7 +31,6 @@
-
@@ -189,7 +188,7 @@
-
+
@@ -198,7 +197,7 @@
-
+
@@ -207,7 +206,7 @@
-
+
@@ -216,7 +215,7 @@
-
+
@@ -225,7 +224,7 @@
-
+
@@ -237,7 +236,7 @@
-
+
diff --git a/FluentFlyoutWPF/Resources/Localization/Dictionary-en-US.xaml b/FluentFlyoutWPF/Resources/Localization/Dictionary-en-US.xaml
index ea471f7f..4dac8343 100644
--- a/FluentFlyoutWPF/Resources/Localization/Dictionary-en-US.xaml
+++ b/FluentFlyoutWPF/Resources/Localization/Dictionary-en-US.xaml
@@ -5,7 +5,7 @@
Disabled
Media Flyout
When listening to media, press any media or volume key (play/pause, volume up/down, etc.) on your keyboard to display the flyout. Displays media info, along with playback controls and more.
- Enable Media Flyout
+ Enable Media Flyout on Media Key
Display a flyout when you press a media key
Exclude Volume Keys
Do not display the flyout when pressing volume up/down/mute
@@ -58,6 +58,8 @@ hides repeat, shuffle and player info
Turn this feature on if you have Windows Widgets enabled
Custom Padding
Add extra padding (default: 0px)
+ Enable Media Flyout on Taskbar Widget
+ Display a flyout when you press the taskbar widget and media is Present
Background Blur
Add background blur effect to the taskbar widget
Hide Completely When No Media Is Present
diff --git a/FluentFlyoutWPF/ViewModels/UserSettings.cs b/FluentFlyoutWPF/ViewModels/UserSettings.cs
index 21d1d108..1b9f9c3c 100644
--- a/FluentFlyoutWPF/ViewModels/UserSettings.cs
+++ b/FluentFlyoutWPF/ViewModels/UserSettings.cs
@@ -390,6 +390,12 @@ public string TaskbarWidgetManualPaddingText
}
}
+ ///
+ /// Gets or sets a value indicating whether the taskbar widget is clickable
+ ///
+ [ObservableProperty]
+ public partial bool TaskbarWidgetClickable { get; set; }
+
///
/// Gets or sets a value indication whether the taskbar widget background should have a blur effect
///
@@ -573,6 +579,7 @@ public UserSettings()
TaskbarWidgetPosition = 0;
TaskbarWidgetPadding = true;
TaskbarWidgetManualPadding = 0;
+ TaskbarWidgetClickable = true;
TaskbarWidgetBackgroundBlur = false;
TaskbarWidgetHideCompletely = false;
TaskbarWidgetControlsEnabled = false;
@@ -663,6 +670,12 @@ partial void OnTaskbarWidgetManualPaddingChanged(int oldValue, int newValue)
UpdateTaskbar();
}
+ partial void OnTaskbarWidgetClickableChanged(bool oldValue, bool newValue)
+ {
+ if (oldValue == newValue || _initializing) return;
+ UpdateTaskbar();
+ }
+
partial void OnTaskbarWidgetBackgroundBlurChanged(bool oldValue, bool newValue)
{
if (oldValue == newValue || _initializing) return;