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/layers/layer_impl.h" | 5 #include "cc/layers/layer_impl.h" |
6 | 6 |
7 #include "base/debug/trace_event.h" | 7 #include "base/debug/trace_event.h" |
8 #include "base/json/json_reader.h" | 8 #include "base/json/json_reader.h" |
9 #include "base/strings/stringprintf.h" | 9 #include "base/strings/stringprintf.h" |
10 #include "cc/animation/animation_registrar.h" | 10 #include "cc/animation/animation_registrar.h" |
(...skipping 1484 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1495 bool converted_to_dictionary = | 1495 bool converted_to_dictionary = |
1496 debug_info_value->GetAsDictionary(&dictionary_value); | 1496 debug_info_value->GetAsDictionary(&dictionary_value); |
1497 DCHECK(converted_to_dictionary); | 1497 DCHECK(converted_to_dictionary); |
1498 state->MergeDictionary(dictionary_value); | 1498 state->MergeDictionary(dictionary_value); |
1499 } else { | 1499 } else { |
1500 NOTREACHED(); | 1500 NOTREACHED(); |
1501 } | 1501 } |
1502 } | 1502 } |
1503 } | 1503 } |
1504 | 1504 |
| 1505 bool LayerImpl::is_render_surface_list_member() const { |
| 1506 return draw_properties_.last_valid_render_surface_list_id == |
| 1507 layer_tree_impl_->current_render_surface_list_id(); |
| 1508 } |
| 1509 |
1505 size_t LayerImpl::GPUMemoryUsageInBytes() const { return 0; } | 1510 size_t LayerImpl::GPUMemoryUsageInBytes() const { return 0; } |
1506 | 1511 |
1507 scoped_ptr<base::Value> LayerImpl::AsValue() const { | 1512 scoped_ptr<base::Value> LayerImpl::AsValue() const { |
1508 scoped_ptr<base::DictionaryValue> state(new base::DictionaryValue()); | 1513 scoped_ptr<base::DictionaryValue> state(new base::DictionaryValue()); |
1509 AsValueInto(state.get()); | 1514 AsValueInto(state.get()); |
1510 return state.PassAs<base::Value>(); | 1515 return state.PassAs<base::Value>(); |
1511 } | 1516 } |
1512 | 1517 |
1513 void LayerImpl::RunMicroBenchmark(MicroBenchmarkImpl* benchmark) { | 1518 void LayerImpl::RunMicroBenchmark(MicroBenchmarkImpl* benchmark) { |
1514 benchmark->RunOnLayer(this); | 1519 benchmark->RunOnLayer(this); |
1515 } | 1520 } |
1516 } // namespace cc | 1521 } // namespace cc |
OLD | NEW |