| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2009 Apple Inc. All rights reserved. | 2 * Copyright (C) 2009 Apple Inc. All rights reserved. |
| 3 * | 3 * |
| 4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
| 5 * modification, are permitted provided that the following conditions | 5 * modification, are permitted provided that the following conditions |
| 6 * are met: | 6 * are met: |
| 7 * 1. Redistributions of source code must retain the above copyright | 7 * 1. Redistributions of source code must retain the above copyright |
| 8 * notice, this list of conditions and the following disclaimer. | 8 * notice, this list of conditions and the following disclaimer. |
| 9 * 2. Redistributions in binary form must reproduce the above copyright | 9 * 2. Redistributions in binary form must reproduce the above copyright |
| 10 * notice, this list of conditions and the following disclaimer in the | 10 * notice, this list of conditions and the following disclaimer in the |
| (...skipping 71 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 82 | 82 |
| 83 typedef HashMap<const GraphicsLayer*, Vector<PaintInvalidationInfo>> PaintInvali
dationTrackingMap; | 83 typedef HashMap<const GraphicsLayer*, Vector<PaintInvalidationInfo>> PaintInvali
dationTrackingMap; |
| 84 static PaintInvalidationTrackingMap& paintInvalidationTrackingMap() | 84 static PaintInvalidationTrackingMap& paintInvalidationTrackingMap() |
| 85 { | 85 { |
| 86 DEFINE_STATIC_LOCAL(PaintInvalidationTrackingMap, map, ()); | 86 DEFINE_STATIC_LOCAL(PaintInvalidationTrackingMap, map, ()); |
| 87 return map; | 87 return map; |
| 88 } | 88 } |
| 89 | 89 |
| 90 PassOwnPtr<GraphicsLayer> GraphicsLayer::create(GraphicsLayerClient* client) | 90 PassOwnPtr<GraphicsLayer> GraphicsLayer::create(GraphicsLayerClient* client) |
| 91 { | 91 { |
| 92 OwnPtr<GraphicsLayer> layer = adoptPtr(new GraphicsLayer(client)); | 92 return adoptPtr(new GraphicsLayer(client)); |
| 93 return layer.release(); | |
| 94 } | 93 } |
| 95 | 94 |
| 96 GraphicsLayer::GraphicsLayer(GraphicsLayerClient* client) | 95 GraphicsLayer::GraphicsLayer(GraphicsLayerClient* client) |
| 97 : m_client(client) | 96 : m_client(client) |
| 98 , m_backgroundColor(Color::transparent) | 97 , m_backgroundColor(Color::transparent) |
| 99 , m_opacity(1) | 98 , m_opacity(1) |
| 100 , m_blendMode(WebBlendModeNormal) | 99 , m_blendMode(WebBlendModeNormal) |
| 101 , m_hasTransformOrigin(false) | 100 , m_hasTransformOrigin(false) |
| 102 , m_contentsOpaque(false) | 101 , m_contentsOpaque(false) |
| 103 , m_shouldFlattenTransform(true) | 102 , m_shouldFlattenTransform(true) |
| (...skipping 1120 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1224 { | 1223 { |
| 1225 if (!layer) { | 1224 if (!layer) { |
| 1226 fprintf(stderr, "Cannot showGraphicsLayerTree for (nil).\n"); | 1225 fprintf(stderr, "Cannot showGraphicsLayerTree for (nil).\n"); |
| 1227 return; | 1226 return; |
| 1228 } | 1227 } |
| 1229 | 1228 |
| 1230 String output = layer->layerTreeAsText(blink::LayerTreeIncludesDebugInfo); | 1229 String output = layer->layerTreeAsText(blink::LayerTreeIncludesDebugInfo); |
| 1231 fprintf(stderr, "%s\n", output.utf8().data()); | 1230 fprintf(stderr, "%s\n", output.utf8().data()); |
| 1232 } | 1231 } |
| 1233 #endif | 1232 #endif |
| OLD | NEW |