Skip to content
This repository has been archived by the owner on Sep 2, 2021. It is now read-only.

Add a fix for Surface Pro users who auto hide their taskbar #479

Merged
merged 1 commit into from
Oct 23, 2014
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
5 changes: 4 additions & 1 deletion appshell/cef_dark_aero_window.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -155,7 +155,10 @@ namespace WindowsTaskBar
RECT tbOther;
BOOL intersection = ::IntersectRect(&tbOther, &info.rcMonitor, &bar.rc);

return ((dwStyle & WS_EX_TOPMOST) && intersection);
// Short-circuit if there's only 1 monitor and assume it intersects
bool singleMonitor = (::GetSystemMetrics(SM_CMONITORS) == 1);

return ((dwStyle & WS_EX_TOPMOST) && (singleMonitor || intersection));
}

// API
Expand Down