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

Side by Side Diff: third_party/WebKit/Source/core/layout/svg/SVGResources.cpp

Issue 2940933003: DO NOT SUBMIT results of new clang-format (Closed)
Patch Set: Created 3 years, 6 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
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 147 matching lines...) Expand 10 before | Expand all | Expand 10 after
158 const AtomicString& id, 158 const AtomicString& id,
159 SVGElement& element) { 159 SVGElement& element) {
160 if (LayoutSVGResourceContainer* container = 160 if (LayoutSVGResourceContainer* container =
161 tree_scope_resources.ResourceById(id)) { 161 tree_scope_resources.ResourceById(id)) {
162 if (IsResourceOfType<ContainerType>(container)) 162 if (IsResourceOfType<ContainerType>(container))
163 return static_cast<ContainerType*>(container); 163 return static_cast<ContainerType*>(container);
164 } 164 }
165 tree_scope_resources.AddPendingResource(id, element); 165 tree_scope_resources.AddPendingResource(id, element);
166 return nullptr; 166 return nullptr;
167 } 167 }
168 } 168 } // namespace
169 169
170 bool SVGResources::HasResourceData() const { 170 bool SVGResources::HasResourceData() const {
171 return clipper_filter_masker_data_ || marker_data_ || fill_stroke_data_ || 171 return clipper_filter_masker_data_ || marker_data_ || fill_stroke_data_ ||
172 linked_resource_; 172 linked_resource_;
173 } 173 }
174 174
175 static inline SVGResources& EnsureResources( 175 static inline SVGResources& EnsureResources(
176 std::unique_ptr<SVGResources>& resources) { 176 std::unique_ptr<SVGResources>& resources) {
177 if (!resources) 177 if (!resources)
178 resources = WTF::WrapUnique(new SVGResources); 178 resources = WTF::WrapUnique(new SVGResources);
(...skipping 475 matching lines...) Expand 10 before | Expand all | Expand 10 after
654 stroke->GetElement()); 654 stroke->GetElement());
655 } 655 }
656 656
657 if (linked_resource_) 657 if (linked_resource_)
658 fprintf(stderr, " |-> xlink:href : %p (node=%p)\n", linked_resource_, 658 fprintf(stderr, " |-> xlink:href : %p (node=%p)\n", linked_resource_,
659 linked_resource_->GetElement()); 659 linked_resource_->GetElement());
660 } 660 }
661 #endif 661 #endif
662 662
663 } // namespace blink 663 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698