OLD | NEW |
1 // Copyright 2012 The Chromium Authors. All rights reserved. | 1 // Copyright 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 #include "cc/resources/tile_manager.h" | 5 #include "cc/resources/tile_manager.h" |
6 | 6 |
7 #include <algorithm> | 7 #include <algorithm> |
8 #include <limits> | 8 #include <limits> |
9 #include <string> | 9 #include <string> |
10 | 10 |
11 #include "base/bind.h" | 11 #include "base/bind.h" |
12 #include "base/debug/trace_event_argument.h" | |
13 #include "base/json/json_writer.h" | 12 #include "base/json/json_writer.h" |
14 #include "base/logging.h" | 13 #include "base/logging.h" |
15 #include "base/metrics/histogram.h" | 14 #include "base/metrics/histogram.h" |
| 15 #include "base/trace_event/trace_event_argument.h" |
16 #include "cc/debug/devtools_instrumentation.h" | 16 #include "cc/debug/devtools_instrumentation.h" |
17 #include "cc/debug/frame_viewer_instrumentation.h" | 17 #include "cc/debug/frame_viewer_instrumentation.h" |
18 #include "cc/debug/traced_value.h" | 18 #include "cc/debug/traced_value.h" |
19 #include "cc/layers/picture_layer_impl.h" | 19 #include "cc/layers/picture_layer_impl.h" |
20 #include "cc/resources/raster_buffer.h" | 20 #include "cc/resources/raster_buffer.h" |
21 #include "cc/resources/rasterizer.h" | 21 #include "cc/resources/rasterizer.h" |
22 #include "cc/resources/tile.h" | 22 #include "cc/resources/tile.h" |
23 #include "cc/resources/tile_task_runner.h" | 23 #include "cc/resources/tile_task_runner.h" |
24 #include "ui/gfx/geometry/rect_conversions.h" | 24 #include "ui/gfx/geometry/rect_conversions.h" |
25 | 25 |
(...skipping 1017 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1043 result -= other; | 1043 result -= other; |
1044 return result; | 1044 return result; |
1045 } | 1045 } |
1046 | 1046 |
1047 bool TileManager::MemoryUsage::Exceeds(const MemoryUsage& limit) const { | 1047 bool TileManager::MemoryUsage::Exceeds(const MemoryUsage& limit) const { |
1048 return memory_bytes_ > limit.memory_bytes_ || | 1048 return memory_bytes_ > limit.memory_bytes_ || |
1049 resource_count_ > limit.resource_count_; | 1049 resource_count_ > limit.resource_count_; |
1050 } | 1050 } |
1051 | 1051 |
1052 } // namespace cc | 1052 } // namespace cc |
OLD | NEW |