Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(3247)

Unified Diff: chrome/views/widget_win.cc

Issue 28150: Task manager stays on top, even when "opened" multiple times. (Closed) Base URL: http://src.chromium.org/svn/trunk/src/
Patch Set: '' Created 11 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « AUTHORS ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/views/widget_win.cc
===================================================================
--- chrome/views/widget_win.cc (revision 10469)
+++ chrome/views/widget_win.cc (working copy)
@@ -241,7 +241,15 @@
if (!should_activate) {
flags |= SWP_NOACTIVATE;
}
- SetWindowPos(HWND_NOTOPMOST, 0, 0, 0, 0, flags);
+
+ // Check if the window is topmost.
+ WINDOWINFO wi;
+ wi.cbSize = sizeof(WINDOWINFO);
+ GetWindowInfo(GetHWND(), &wi);
+ if ((wi.dwExStyle & WS_EX_TOPMOST) > 0)
+ SetWindowPos(HWND_TOPMOST, 0, 0, 0, 0, flags);
+ else
+ SetWindowPos(HWND_NOTOPMOST, 0, 0, 0, 0, flags);
}
HWND WidgetWin::GetHWND() const {
« no previous file with comments | « AUTHORS ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698