Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
1.0.0
1.0.1
2 changes: 1 addition & 1 deletion bootstrap/payload/SlipperyContext.Diagnostics.cs
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ private void CopyDiagnostics()
{
StringBuilder b = new StringBuilder();
b.AppendLine("Slippery Taskbar C# diagnostics");
b.AppendLine("Build: 1.0.0");
b.AppendLine("Build: 1.0.1");
b.AppendLine("Runtime: " + Environment.Version);
b.AppendLine("OS: " + Environment.OSVersion);
b.AppendLine("Executable: " + Application.ExecutablePath);
Expand Down
10 changes: 4 additions & 6 deletions bootstrap/payload/TaskbarController.Core.cs
Original file line number Diff line number Diff line change
Expand Up @@ -72,12 +72,6 @@ public void ApplyVisibility(bool show)
foreach (IntPtr h in _taskbars)
{
if (!NativeMethods.IsWindow(h)) continue;

// Match Buttery Taskbar's least-invasive visibility model: one
// synchronous ShowWindow call, with Explorer left in control of the
// taskbar's own auto-hide/XAML animation and position. Do not pair
// this with SetWindowPos or force the bar back onto the monitor; those
// operations can fight Explorer mid-animation and create a flash.
NativeMethods.ShowWindow(h, show ? NativeMethods.SW_SHOWNOACTIVATE : NativeMethods.SW_HIDE);
}
}
Expand Down Expand Up @@ -131,8 +125,12 @@ public uint GetAppbarState()

private void SetAppbarState(uint state)
{
IntPtr primaryTaskbar = NativeMethods.FindWindow("Shell_TrayWnd", null);
if (primaryTaskbar == IntPtr.Zero) return;

NativeMethods.APPBARDATA data = new NativeMethods.APPBARDATA();
data.cbSize = (uint)Marshal.SizeOf(typeof(NativeMethods.APPBARDATA));
data.hWnd = primaryTaskbar;
data.lParam = new IntPtr((long)state);
NativeMethods.SHAppBarMessage(NativeMethods.ABM_SETSTATE, ref data);
}
Expand Down
2 changes: 1 addition & 1 deletion src/SlipperyContext.Diagnostics.cs
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ private void CopyDiagnostics()
{
StringBuilder b = new StringBuilder();
b.AppendLine("Slippery Taskbar C# diagnostics");
b.AppendLine("Build: 1.0.0");
b.AppendLine("Build: 1.0.1");
b.AppendLine("Runtime: " + Environment.Version);
b.AppendLine("OS: " + Environment.OSVersion);
b.AppendLine("Executable: " + Application.ExecutablePath);
Expand Down
4 changes: 2 additions & 2 deletions src/SlipperyTaskbar.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@
<PublishSingleFile>true</PublishSingleFile>
<IncludeNativeLibrariesForSelfExtract>true</IncludeNativeLibrariesForSelfExtract>
<PublishTrimmed>false</PublishTrimmed>
<Version>1.0.0</Version>
<FileVersion>1.0.0.0</FileVersion>
<Version>1.0.1</Version>
<FileVersion>1.0.1.0</FileVersion>
<Product>Slippery Taskbar</Product>
<Description>Hide the Windows 11 taskbar until the Windows key or shell UI intentionally reveals it.</Description>
</PropertyGroup>
Expand Down
9 changes: 4 additions & 5 deletions src/TaskbarController.Core.cs
Original file line number Diff line number Diff line change
Expand Up @@ -73,11 +73,6 @@ public void ApplyVisibility(bool show)
{
if (!NativeMethods.IsWindow(h)) continue;

// Match Buttery Taskbar's least-invasive visibility model: one
// synchronous ShowWindow call, with Explorer left in control of the
// taskbar's own auto-hide/XAML animation and position. Do not pair
// this with SetWindowPos or force the bar back onto the monitor; those
// operations can fight Explorer mid-animation and create a flash.
NativeMethods.ShowWindow(h, show ? NativeMethods.SW_SHOWNOACTIVATE : NativeMethods.SW_HIDE);
}
}
Expand Down Expand Up @@ -131,8 +126,12 @@ public uint GetAppbarState()

private void SetAppbarState(uint state)
{
IntPtr primaryTaskbar = NativeMethods.FindWindow("Shell_TrayWnd", null);
if (primaryTaskbar == IntPtr.Zero) return;

NativeMethods.APPBARDATA data = new NativeMethods.APPBARDATA();
data.cbSize = (uint)Marshal.SizeOf(typeof(NativeMethods.APPBARDATA));
data.hWnd = primaryTaskbar;
data.lParam = new IntPtr((long)state);
NativeMethods.SHAppBarMessage(NativeMethods.ABM_SETSTATE, ref data);
}
Expand Down
Loading