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

Side by Side Diff: pdf/paint_aggregator.cc

Issue 2270463003: Turn on enforce-in-pdf Clang plugin flag. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix win clang Created 4 years, 4 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 unified diff | Download patch
« no previous file with comments | « pdf/paint_aggregator.h ('k') | pdf/paint_manager.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 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 #include "pdf/paint_aggregator.h" 5 #include "pdf/paint_aggregator.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include <algorithm> 10 #include <algorithm>
(...skipping 16 matching lines...) Expand all
27 // rect, then we just treat the scroll rect as an invalidation rect. 27 // rect, then we just treat the scroll rect as an invalidation rect.
28 // 28 //
29 // For invalidations performed prior to scrolling and contained within the 29 // For invalidations performed prior to scrolling and contained within the
30 // scroll rect, we offset the invalidation rects to account for the fact that 30 // scroll rect, we offset the invalidation rects to account for the fact that
31 // the consumer will perform scrolling before painting. 31 // the consumer will perform scrolling before painting.
32 // 32 //
33 // We only support scrolling along one axis at a time. A diagonal scroll will 33 // We only support scrolling along one axis at a time. A diagonal scroll will
34 // therefore be treated as an invalidation. 34 // therefore be treated as an invalidation.
35 // ---------------------------------------------------------------------------- 35 // ----------------------------------------------------------------------------
36 36
37 PaintAggregator::PaintUpdate::PaintUpdate() { 37 PaintAggregator::PaintUpdate::PaintUpdate() = default;
38 }
39 38
40 PaintAggregator::PaintUpdate::~PaintUpdate() { 39 PaintAggregator::PaintUpdate::PaintUpdate(const PaintUpdate& that) = default;
41 } 40
41 PaintAggregator::PaintUpdate::~PaintUpdate() = default;
42 42
43 PaintAggregator::InternalPaintUpdate::InternalPaintUpdate() : 43 PaintAggregator::InternalPaintUpdate::InternalPaintUpdate() :
44 synthesized_scroll_damage_rect_(false) { 44 synthesized_scroll_damage_rect_(false) {
45 } 45 }
46 46
47 PaintAggregator::InternalPaintUpdate::~InternalPaintUpdate() { 47 PaintAggregator::InternalPaintUpdate::~InternalPaintUpdate() {
48 } 48 }
49 49
50 pp::Rect PaintAggregator::InternalPaintUpdate::GetScrollDamage() const { 50 pp::Rect PaintAggregator::InternalPaintUpdate::GetScrollDamage() const {
51 // Should only be scrolling in one direction at a time. 51 // Should only be scrolling in one direction at a time.
(...skipping 230 matching lines...) Expand 10 before | Expand all | Expand 10 after
282 } 282 }
283 283
284 // If the new paint overlaps with a scroll, then also invalidate the rect in 284 // If the new paint overlaps with a scroll, then also invalidate the rect in
285 // its new position. 285 // its new position.
286 if (check_scroll && 286 if (check_scroll &&
287 !update_.scroll_rect.IsEmpty() && 287 !update_.scroll_rect.IsEmpty() &&
288 update_.scroll_rect.Intersects(rect)) { 288 update_.scroll_rect.Intersects(rect)) {
289 InvalidateRectInternal(ScrollPaintRect(rect, update_.scroll_delta), false); 289 InvalidateRectInternal(ScrollPaintRect(rect, update_.scroll_delta), false);
290 } 290 }
291 } 291 }
OLDNEW
« no previous file with comments | « pdf/paint_aggregator.h ('k') | pdf/paint_manager.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698