Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(113)

Side by Side Diff: Source/core/rendering/svg/RenderSVGResourceContainer.h

Issue 23785014: [SVG] Resources should be laid out in dependecy order. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 7 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
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 54 matching lines...) Expand 10 before | Expand all | Expand 10 after
65 void addClient(RenderObject*); 65 void addClient(RenderObject*);
66 void removeClient(RenderObject*); 66 void removeClient(RenderObject*);
67 67
68 private: 68 private:
69 virtual void willBeDestroyed() OVERRIDE FINAL; 69 virtual void willBeDestroyed() OVERRIDE FINAL;
70 void registerResource(); 70 void registerResource();
71 71
72 AtomicString m_id; 72 AtomicString m_id;
73 bool m_registered : 1; 73 bool m_registered : 1;
74 bool m_isInvalidating : 1; 74 bool m_isInvalidating : 1;
75 bool m_isInLayout;
75 HashSet<RenderObject*> m_clients; 76 HashSet<RenderObject*> m_clients;
76 HashSet<RenderLayer*> m_clientLayers; 77 HashSet<RenderLayer*> m_clientLayers;
77 }; 78 };
78 79
79 inline RenderSVGResourceContainer* getRenderSVGResourceContainerById(Document& d ocument, const AtomicString& id) 80 inline RenderSVGResourceContainer* getRenderSVGResourceContainerById(Document& d ocument, const AtomicString& id)
80 { 81 {
81 if (id.isEmpty()) 82 if (id.isEmpty())
82 return 0; 83 return 0;
83 84
84 if (RenderSVGResourceContainer* renderResource = document.accessSVGExtension s()->resourceById(id)) 85 if (RenderSVGResourceContainer* renderResource = document.accessSVGExtension s()->resourceById(id))
85 return renderResource; 86 return renderResource;
86 87
87 return 0; 88 return 0;
88 } 89 }
89 90
90 template<typename Renderer> 91 template<typename Renderer>
91 Renderer* getRenderSVGResourceById(Document& document, const AtomicString& id) 92 Renderer* getRenderSVGResourceById(Document& document, const AtomicString& id)
92 { 93 {
93 if (RenderSVGResourceContainer* container = getRenderSVGResourceContainerByI d(document, id)) 94 if (RenderSVGResourceContainer* container = getRenderSVGResourceContainerByI d(document, id))
94 return container->cast<Renderer>(); 95 return container->cast<Renderer>();
95 96
96 return 0; 97 return 0;
97 } 98 }
98 99
99 } 100 }
100 101
101 #endif 102 #endif
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698