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

Unified Diff: ui/views/widget/widget.cc

Issue 11567011: Conditionally call SchedulePaint() when activating and deactivating inactive rendering (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years 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 | « ui/views/widget/native_widget_win.cc ('k') | ui/views/window/non_client_view.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/views/widget/widget.cc
diff --git a/ui/views/widget/widget.cc b/ui/views/widget/widget.cc
index c18ac06426a3729b2f56708ecc621ae5a443f1f7..d64f650ed68ca4c6a2921ef6cffd4e2a001533e8 100644
--- a/ui/views/widget/widget.cc
+++ b/ui/views/widget/widget.cc
@@ -1283,10 +1283,10 @@ bool Widget::ShouldReleaseCaptureOnMouseReleased() const {
}
void Widget::SetInactiveRenderingDisabled(bool value) {
+ if (value == disable_inactive_rendering_)
+ return;
+
disable_inactive_rendering_ = value;
- // We need to always notify the NonClientView so that it can trigger a paint.
- // TODO: what's really needed is a way to know when either the active state
- // changes or |disable_inactive_rendering_| changes.
if (non_client_view_)
non_client_view_->SetInactiveRenderingDisabled(value);
native_widget_->SetInactiveRenderingDisabled(value);
« no previous file with comments | « ui/views/widget/native_widget_win.cc ('k') | ui/views/window/non_client_view.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698