diff --git a/RetroBar/Program.cs b/RetroBar/Program.cs
index c79a631d..a00848b5 100644
--- a/RetroBar/Program.cs
+++ b/RetroBar/Program.cs
@@ -53,4 +53,4 @@ private static bool SingleInstanceCheck()
return false;
}
}
-}
+}
\ No newline at end of file
diff --git a/RetroBar/PropertiesWindow.xaml b/RetroBar/PropertiesWindow.xaml
index d4666fec..677cad30 100644
--- a/RetroBar/PropertiesWindow.xaml
+++ b/RetroBar/PropertiesWindow.xaml
@@ -239,6 +239,12 @@
+
+
+
+
+
+
diff --git a/RetroBar/Taskbar.xaml.cs b/RetroBar/Taskbar.xaml.cs
index 9882230e..9c393383 100644
--- a/RetroBar/Taskbar.xaml.cs
+++ b/RetroBar/Taskbar.xaml.cs
@@ -274,10 +274,18 @@ protected override void OnAutoHideAnimationBegin(bool isHiding)
// Prevent focus indicators and tooltips while hidden
ResetControlFocus();
- if (!isHiding && Opacity < 1)
+ if (!isHiding)
{
- Opacity = 1;
- OnPropertyChanged(nameof(Opacity));
+ if (Settings.Instance.DisableAnimations)
+ {
+ // Instantly snap to full opacity
+ Opacity = 1;
+ }
+ else if (Opacity < 1)
+ {
+ Opacity = 1;
+ OnPropertyChanged(nameof(Opacity));
+ }
}
}
@@ -285,9 +293,17 @@ protected override void OnAutoHideAnimationComplete(bool isHiding)
{
base.OnAutoHideAnimationComplete(isHiding);
- if (isHiding && Settings.Instance.AutoHideTransparent && AllowsTransparency && AllowAutoHide)
+ if (isHiding)
{
- Opacity = 0.01;
+ if (Settings.Instance.DisableAnimations)
+ {
+ Opacity = 0; // Instantly hide
+ }
+ else if (Settings.Instance.AutoHideTransparent && AllowsTransparency && AllowAutoHide)
+ {
+ Opacity = 0.01; // Subtle transparency
+ }
+
OnPropertyChanged(nameof(Opacity));
}
}
diff --git a/RetroBar/Utilities/HotkeyManager.cs b/RetroBar/Utilities/HotkeyManager.cs
index b1d05c94..de47fb03 100644
--- a/RetroBar/Utilities/HotkeyManager.cs
+++ b/RetroBar/Utilities/HotkeyManager.cs
@@ -2,6 +2,7 @@
using ManagedShell.Common.Logging;
using System;
using System.Collections.Generic;
+using System.Runtime.InteropServices;
using System.Windows.Forms;
using static ManagedShell.Interop.NativeMethods;
@@ -14,6 +15,7 @@ public class HotkeyManager : IDisposable
{
private readonly HotkeyListenerWindow _listenerWindow;
+ private const int TOGGLE_TASKBAR_HOTKEY_ID = 9999;
public HotkeyManager()
{
_listenerWindow = new HotkeyListenerWindow(this);
@@ -57,6 +59,15 @@ private void Settings_PropertyChanged(object sender, System.ComponentModel.Prope
_listenerWindow.UnregisterHotkeys();
}
}
+ if (Settings.Instance.EnableTaskbarToggleHotkey)
+ {
+ _listenerWindow.RegisterToggleAutoHide();
+ }
+ else if (!Settings.Instance.EnableTaskbarToggleHotkey)
+ {
+ _listenerWindow.UnregisterHotkeys();
+ ShellLogger.Debug("Alt+T toggle is disabled by settings.");
+ }
}
#endregion
@@ -81,6 +92,13 @@ protected override void WndProc(ref Message m)
if (m.Msg == (int)WM.HOTKEY)
{
int hotkeyId = m.WParam.ToInt32();
+ if (hotkeyId == TOGGLE_TASKBAR_HOTKEY_ID)
+ {
+ // Toggle built-in AutoHide setting
+ Settings.Instance.AutoHide = !Settings.Instance.AutoHide;
+ ShellLogger.Debug($"HotkeyManager: Alt+T toggled AutoHide to {Settings.Instance.AutoHide}");
+ return;
+ }
if (_registeredHotkeys.Contains(hotkeyId))
{
_manager.TaskbarHotkeyPressed?.Invoke(this, new TaskbarHotkeyEventArgs { index = hotkeyId });
@@ -124,6 +142,37 @@ public void RegisterHotkeys()
}
}
+ public void RegisterToggleAutoHide()
+ {
+ ShellLogger.Debug("HotkeyManager: Registering toggle autohide hotkey");
+ // Register Alt+T for toggling taskbar
+ bool altTRegistered = RegisterHotKey(
+ Handle,
+ TOGGLE_TASKBAR_HOTKEY_ID,
+ (uint)(MOD.ALT | MOD.NOREPEAT),
+ (uint)VK.KEY_T);
+
+ if (altTRegistered)
+ {
+ _registeredHotkeys.Add(TOGGLE_TASKBAR_HOTKEY_ID);
+ ShellLogger.Info("HotkeyManager: Registered Alt+T for AutoHide toggle");
+ }
+ else if (Settings.Instance.EnableTaskbarToggleHotkey)
+ {
+ ShellLogger.Info("HotkeyManager: Autohide toggled using Alt+T");
+ }
+ else
+ {
+ ShellLogger.Warning("HotkeyManager: FAILED to register Alt+T for AutoHide toggle");
+ }
+ }
+
+ public void UnregisterToggleAutoHide()
+ {
+ UnregisterHotKey(Handle, 9999);
+ ShellLogger.Info($"HotkeyManager: Unregistered Alt+T for AutoHide toggle");
+ }
+
private void LoadExplorerResources()
{
// Initialize with empty table as fallback
diff --git a/RetroBar/Utilities/Settings.cs b/RetroBar/Utilities/Settings.cs
index 67b93627..04939bf9 100644
--- a/RetroBar/Utilities/Settings.cs
+++ b/RetroBar/Utilities/Settings.cs
@@ -276,6 +276,20 @@ public bool AutoHide
set => Set(ref _autoHide, value);
}
+ private bool _enableTaskbarToggleHotkey = false;
+ public bool EnableTaskbarToggleHotkey
+ {
+ get => _enableTaskbarToggleHotkey;
+ set => Set(ref _enableTaskbarToggleHotkey, value);
+ }
+
+ private bool _disableAnimations = false;
+ public bool DisableAnimations
+ {
+ get => _disableAnimations;
+ set => Set(ref _disableAnimations, value);
+ }
+
private bool _lockTaskbar = false;
public bool LockTaskbar
{