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

Side by Side Diff: ui/views/view.h

Issue 1461673002: Moved parent_->SchedulePaint() to Views::SetFillsBoundsOpaquely() and Views::SchedulePaint(). (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Changed View to schedule a parent paint only when paint to layer, or fills bounds opaquely changed. Created 5 years, 1 month 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 unified diff | Download patch
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef UI_VIEWS_VIEW_H_ 5 #ifndef UI_VIEWS_VIEW_H_
6 #define UI_VIEWS_VIEW_H_ 6 #define UI_VIEWS_VIEW_H_
7 7
8 #include <algorithm> 8 #include <algorithm>
9 #include <map> 9 #include <map>
10 #include <set> 10 #include <set>
(...skipping 1213 matching lines...) Expand 10 before | Expand all | Expand 10 after
1224 SCHEDULE_PAINT_SIZE_SAME, 1224 SCHEDULE_PAINT_SIZE_SAME,
1225 1225
1226 // Indicates the size changed (and possibly the origin). 1226 // Indicates the size changed (and possibly the origin).
1227 SCHEDULE_PAINT_SIZE_CHANGED 1227 SCHEDULE_PAINT_SIZE_CHANGED
1228 }; 1228 };
1229 1229
1230 // Invoked before and after the bounds change to schedule painting the old and 1230 // Invoked before and after the bounds change to schedule painting the old and
1231 // new bounds. 1231 // new bounds.
1232 void SchedulePaintBoundsChanged(SchedulePaintType type); 1232 void SchedulePaintBoundsChanged(SchedulePaintType type);
1233 1233
1234 // Schedules a paint on the parent View if it exists.
1235 void SchedulePaintOnParent();
1236
1234 // Tree operations ----------------------------------------------------------- 1237 // Tree operations -----------------------------------------------------------
1235 1238
1236 // Removes |view| from the hierarchy tree. If |update_focus_cycle| is true, 1239 // Removes |view| from the hierarchy tree. If |update_focus_cycle| is true,
1237 // the next and previous focusable views of views pointing to this view are 1240 // the next and previous focusable views of views pointing to this view are
1238 // updated. If |update_tool_tip| is true, the tooltip is updated. If 1241 // updated. If |update_tool_tip| is true, the tooltip is updated. If
1239 // |delete_removed_view| is true, the view is also deleted (if it is parent 1242 // |delete_removed_view| is true, the view is also deleted (if it is parent
1240 // owned). If |new_parent| is not NULL, the remove is the result of 1243 // owned). If |new_parent| is not NULL, the remove is the result of
1241 // AddChildView() to a new parent. For this case, |new_parent| is the View 1244 // AddChildView() to a new parent. For this case, |new_parent| is the View
1242 // that |view| is going to be added to after the remove completes. 1245 // that |view| is going to be added to after the remove completes.
1243 void DoRemoveChildView(View* view, 1246 void DoRemoveChildView(View* view,
(...skipping 318 matching lines...) Expand 10 before | Expand all | Expand 10 after
1562 // Belongs to this view, but it's reference-counted on some platforms 1565 // Belongs to this view, but it's reference-counted on some platforms
1563 // so we can't use a scoped_ptr. It's dereferenced in the destructor. 1566 // so we can't use a scoped_ptr. It's dereferenced in the destructor.
1564 NativeViewAccessibility* native_view_accessibility_; 1567 NativeViewAccessibility* native_view_accessibility_;
1565 1568
1566 DISALLOW_COPY_AND_ASSIGN(View); 1569 DISALLOW_COPY_AND_ASSIGN(View);
1567 }; 1570 };
1568 1571
1569 } // namespace views 1572 } // namespace views
1570 1573
1571 #endif // UI_VIEWS_VIEW_H_ 1574 #endif // UI_VIEWS_VIEW_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698