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

Unified Diff: ui/views/window/non_client_view.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/widget.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/views/window/non_client_view.cc
diff --git a/ui/views/window/non_client_view.cc b/ui/views/window/non_client_view.cc
index d6ee959f7b07812296700e5fa96e4a5d8252ae6f..5dcfdd530c3cb3a77c4c2435a54855ff55b22a2e 100644
--- a/ui/views/window/non_client_view.cc
+++ b/ui/views/window/non_client_view.cc
@@ -194,8 +194,9 @@ views::View* NonClientView::GetEventHandlerForPoint(const gfx::Point& point) {
// NonClientFrameView, public:
void NonClientFrameView::SetInactiveRenderingDisabled(bool disable) {
- // See comment in Widget::SetInactiveRenderingDisabled as to why we don't
- // conditionally invoke ShouldPaintAsActiveChanged.
+ if (paint_as_active_ == disable)
+ return;
+
paint_as_active_ = disable;
ShouldPaintAsActiveChanged();
}
@@ -266,8 +267,7 @@ bool NonClientFrameView::ShouldPaintAsActive() const {
}
void NonClientFrameView::ShouldPaintAsActiveChanged() {
- if (!paint_as_active_)
- SchedulePaint();
+ SchedulePaint();
}
void NonClientFrameView::GetAccessibleState(ui::AccessibleViewState* state) {
« no previous file with comments | « ui/views/widget/widget.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698