Skip to content
Merged
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
9 changes: 7 additions & 2 deletions src/ManagedShell.WindowsTasks/ApplicationWindow.cs
Original file line number Diff line number Diff line change
Expand Up @@ -376,7 +376,7 @@ private bool getShowInTaskbar()
StringBuilder cName = new StringBuilder(256);
NativeMethods.GetClassName(Handle, cName, cName.Capacity);
string className = cName.ToString();
if (className == "ApplicationFrameWindow" || className == "Windows.UI.Core.CoreWindow")
if (className == "ApplicationFrameWindow" || className == "Windows.UI.Core.CoreWindow" || className == "StartMenuSizingFrame")
{
if ((ExtendedWindowStyles & (int)NativeMethods.ExtendedWindowStyles.WS_EX_WINDOWEDGE) == 0)
{
Expand Down Expand Up @@ -587,7 +587,12 @@ public void BringToFront()
}
else
{
NativeMethods.ShowWindow(Handle, NativeMethods.WindowShowStyle.Show);
// If the window is maximized, use ShowMaximize so that it doesn't un-maximize
if (GetWindowShowStyle(Handle) != NativeMethods.WindowShowStyle.ShowMaximized ||
!NativeMethods.ShowWindow(Handle, NativeMethods.WindowShowStyle.ShowMaximized))
{
NativeMethods.ShowWindow(Handle, NativeMethods.WindowShowStyle.Show);
}
makeForeground();

if (State == WindowState.Flashing) State = WindowState.Active; // some stubborn windows (Outlook) start flashing while already active, this lets us stop
Expand Down