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

Unified Diff: chrome/browser/ui/views/frame/minimize_button_metrics_win.cc

Issue 1992103002: Delay button bounds offset calculation until window is actually visible (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 7 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/views/frame/minimize_button_metrics_win.cc
diff --git a/chrome/browser/ui/views/frame/minimize_button_metrics_win.cc b/chrome/browser/ui/views/frame/minimize_button_metrics_win.cc
index 9d61b121780f56544126c3ea81a7a52b45809560..095f2574c83c9ed91b29b7ec8972c8022cbe5d8d 100644
--- a/chrome/browser/ui/views/frame/minimize_button_metrics_win.cc
+++ b/chrome/browser/ui/views/frame/minimize_button_metrics_win.cc
@@ -73,7 +73,7 @@ int MinimizeButtonMetrics::GetButtonBoundsPositionOffset(
const RECT& button_bounds,
const RECT& window_bounds) const {
if (button_bounds_position_offset_ == kInvalidOffset) {
- if (!was_activated_)
+ if (!was_activated_ || !IsWindowVisible(hwnd_))
return GetDefaultButtonBoundsOffset();
TITLEBARINFOEX info = {0};
info.cbSize = sizeof(info);
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698