| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) Research In Motion Limited 2010. All rights reserved. | 2 * Copyright (C) Research In Motion Limited 2010. 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 57 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 68 virtual void willBeDestroyed() OVERRIDE FINAL; | 68 virtual void willBeDestroyed() OVERRIDE FINAL; |
| 69 void registerResource(); | 69 void registerResource(); |
| 70 | 70 |
| 71 AtomicString m_id; | 71 AtomicString m_id; |
| 72 bool m_registered : 1; | 72 bool m_registered : 1; |
| 73 bool m_isInvalidating : 1; | 73 bool m_isInvalidating : 1; |
| 74 HashSet<RenderObject*> m_clients; | 74 HashSet<RenderObject*> m_clients; |
| 75 HashSet<RenderLayer*> m_clientLayers; | 75 HashSet<RenderLayer*> m_clientLayers; |
| 76 }; | 76 }; |
| 77 | 77 |
| 78 inline RenderSVGResourceContainer* getRenderSVGResourceContainerById(Document* d
ocument, const AtomicString& id) | 78 inline RenderSVGResourceContainer* getRenderSVGResourceContainerById(Document& d
ocument, const AtomicString& id) |
| 79 { | 79 { |
| 80 if (id.isEmpty()) | 80 if (id.isEmpty()) |
| 81 return 0; | 81 return 0; |
| 82 | 82 |
| 83 if (RenderSVGResourceContainer* renderResource = document->accessSVGExtensio
ns()->resourceById(id)) | 83 if (RenderSVGResourceContainer* renderResource = document.accessSVGExtension
s()->resourceById(id)) |
| 84 return renderResource; | 84 return renderResource; |
| 85 | 85 |
| 86 return 0; | 86 return 0; |
| 87 } | 87 } |
| 88 | 88 |
| 89 template<typename Renderer> | 89 template<typename Renderer> |
| 90 Renderer* getRenderSVGResourceById(Document* document, const AtomicString& id) | 90 Renderer* getRenderSVGResourceById(Document& document, const AtomicString& id) |
| 91 { | 91 { |
| 92 if (RenderSVGResourceContainer* container = getRenderSVGResourceContainerByI
d(document, id)) | 92 if (RenderSVGResourceContainer* container = getRenderSVGResourceContainerByI
d(document, id)) |
| 93 return container->cast<Renderer>(); | 93 return container->cast<Renderer>(); |
| 94 | 94 |
| 95 return 0; | 95 return 0; |
| 96 } | 96 } |
| 97 | 97 |
| 98 } | 98 } |
| 99 | 99 |
| 100 #endif | 100 #endif |
| OLD | NEW |