| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2014 Google Inc. All rights reserved. | 2 * Copyright (C) 2014 Google Inc. All rights reserved. |
| 3 * | 3 * |
| 4 * This library is free software; you can redistribute it and/or | 4 * This library is free software; you can redistribute it and/or |
| 5 * modify it under the terms of the GNU Library General Public | 5 * modify it under the terms of the GNU Library General Public |
| 6 * License as published by the Free Software Foundation; either | 6 * License as published by the Free Software Foundation; either |
| 7 * version 2 of the License, or (at your option) any later version. | 7 * version 2 of the License, or (at your option) any later version. |
| 8 * | 8 * |
| 9 * This library is distributed in the hope that it will be useful, | 9 * This library is distributed in the hope that it will be useful, |
| 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of | 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of |
| (...skipping 14 matching lines...) Expand all Loading... |
| 25 | 25 |
| 26 GraphicsLayerDebugInfo::GraphicsLayerDebugInfo() | 26 GraphicsLayerDebugInfo::GraphicsLayerDebugInfo() |
| 27 : m_compositingReasons(CompositingReasonNone) | 27 : m_compositingReasons(CompositingReasonNone) |
| 28 , m_squashingDisallowedReasons(SquashingDisallowedReasonsNone) | 28 , m_squashingDisallowedReasons(SquashingDisallowedReasonsNone) |
| 29 , m_ownerNodeId(0) | 29 , m_ownerNodeId(0) |
| 30 { | 30 { |
| 31 } | 31 } |
| 32 | 32 |
| 33 GraphicsLayerDebugInfo::~GraphicsLayerDebugInfo() { } | 33 GraphicsLayerDebugInfo::~GraphicsLayerDebugInfo() { } |
| 34 | 34 |
| 35 scoped_refptr<base::trace_event::TracedValue> GraphicsLayerDebugInfo::asTracedVa
lue() const | 35 scoped_ptr<base::trace_event::TracedValue> GraphicsLayerDebugInfo::asTracedValue
() const |
| 36 { | 36 { |
| 37 scoped_refptr<base::trace_event::TracedValue> tracedValue = new base::trace_
event::TracedValue; | 37 scoped_ptr<base::trace_event::TracedValue> tracedValue( |
| 38 new base::trace_event::TracedValue()); |
| 38 appendAnnotatedInvalidateRects(tracedValue.get()); | 39 appendAnnotatedInvalidateRects(tracedValue.get()); |
| 39 appendCompositingReasons(tracedValue.get()); | 40 appendCompositingReasons(tracedValue.get()); |
| 40 appendSquashingDisallowedReasons(tracedValue.get()); | 41 appendSquashingDisallowedReasons(tracedValue.get()); |
| 41 appendOwnerNodeId(tracedValue.get()); | 42 appendOwnerNodeId(tracedValue.get()); |
| 42 return tracedValue; | 43 return tracedValue; |
| 43 } | 44 } |
| 44 | 45 |
| 45 void GraphicsLayerDebugInfo::appendAnnotatedInvalidateRects(base::trace_event::T
racedValue* tracedValue) const | 46 void GraphicsLayerDebugInfo::appendAnnotatedInvalidateRects(base::trace_event::T
racedValue* tracedValue) const |
| 46 { | 47 { |
| 47 tracedValue->BeginArray("annotated_invalidation_rects"); | 48 tracedValue->BeginArray("annotated_invalidation_rects"); |
| (...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 99 m_invalidations.append(annotatedRect); | 100 m_invalidations.append(annotatedRect); |
| 100 } | 101 } |
| 101 | 102 |
| 102 void GraphicsLayerDebugInfo::clearAnnotatedInvalidateRects() | 103 void GraphicsLayerDebugInfo::clearAnnotatedInvalidateRects() |
| 103 { | 104 { |
| 104 m_previousInvalidations.clear(); | 105 m_previousInvalidations.clear(); |
| 105 m_previousInvalidations.swap(m_invalidations); | 106 m_previousInvalidations.swap(m_invalidations); |
| 106 } | 107 } |
| 107 | 108 |
| 108 } // namespace blink | 109 } // namespace blink |
| OLD | NEW |