| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2004, 2005, 2006 Nikolas Zimmermann <zimmermann@kde.org> | 2 * Copyright (C) 2004, 2005, 2006 Nikolas Zimmermann <zimmermann@kde.org> |
| 3 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2010 Rob Buis <buis@kde.org> | 3 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2010 Rob Buis <buis@kde.org> |
| 4 * Copyright (C) 2007 Apple Inc. All rights reserved. | 4 * Copyright (C) 2007 Apple Inc. All rights reserved. |
| 5 * Copyright (C) 2014 Google, Inc. | 5 * Copyright (C) 2014 Google, Inc. |
| 6 * | 6 * |
| 7 * This library is free software; you can redistribute it and/or | 7 * This library is free software; you can redistribute it and/or |
| 8 * modify it under the terms of the GNU Library General Public | 8 * modify it under the terms of the GNU Library General Public |
| 9 * License as published by the Free Software Foundation; either | 9 * License as published by the Free Software Foundation; either |
| 10 * version 2 of the License, or (at your option) any later version. | 10 * version 2 of the License, or (at your option) any later version. |
| (...skipping 486 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 497 if (root_parent->GetDocument().IsXMLDocument()) | 497 if (root_parent->GetDocument().IsXMLDocument()) |
| 498 UseCounter::Count(GetDocument(), UseCounter::kSVGSVGElementInXMLDocument); | 498 UseCounter::Count(GetDocument(), UseCounter::kSVGSVGElementInXMLDocument); |
| 499 | 499 |
| 500 if (RuntimeEnabledFeatures::smilEnabled()) { | 500 if (RuntimeEnabledFeatures::smilEnabled()) { |
| 501 GetDocument().AccessSVGExtensions().AddTimeContainer(this); | 501 GetDocument().AccessSVGExtensions().AddTimeContainer(this); |
| 502 | 502 |
| 503 // Animations are started at the end of document parsing and after firing | 503 // Animations are started at the end of document parsing and after firing |
| 504 // the load event, but if we miss that train (deferred programmatic | 504 // the load event, but if we miss that train (deferred programmatic |
| 505 // element insertion for example) we need to initialize the time container | 505 // element insertion for example) we need to initialize the time container |
| 506 // here. | 506 // here. |
| 507 if (!GetDocument().Parsing() && !GetDocument().ProcessingLoadEvent() && | 507 if (!GetDocument().Parsing() && GetDocument().LoadEventFinished() && |
| 508 GetDocument().LoadEventFinished() && !TimeContainer()->IsStarted()) | 508 !TimeContainer()->IsStarted()) |
| 509 TimeContainer()->Start(); | 509 TimeContainer()->Start(); |
| 510 } | 510 } |
| 511 } | 511 } |
| 512 return SVGGraphicsElement::InsertedInto(root_parent); | 512 return SVGGraphicsElement::InsertedInto(root_parent); |
| 513 } | 513 } |
| 514 | 514 |
| 515 void SVGSVGElement::RemovedFrom(ContainerNode* root_parent) { | 515 void SVGSVGElement::RemovedFrom(ContainerNode* root_parent) { |
| 516 if (root_parent->isConnected()) { | 516 if (root_parent->isConnected()) { |
| 517 SVGDocumentExtensions& svg_extensions = GetDocument().AccessSVGExtensions(); | 517 SVGDocumentExtensions& svg_extensions = GetDocument().AccessSVGExtensions(); |
| 518 svg_extensions.RemoveTimeContainer(this); | 518 svg_extensions.RemoveTimeContainer(this); |
| (...skipping 213 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 732 visitor->Trace(width_); | 732 visitor->Trace(width_); |
| 733 visitor->Trace(height_); | 733 visitor->Trace(height_); |
| 734 visitor->Trace(translation_); | 734 visitor->Trace(translation_); |
| 735 visitor->Trace(time_container_); | 735 visitor->Trace(time_container_); |
| 736 visitor->Trace(view_spec_); | 736 visitor->Trace(view_spec_); |
| 737 SVGGraphicsElement::Trace(visitor); | 737 SVGGraphicsElement::Trace(visitor); |
| 738 SVGFitToViewBox::Trace(visitor); | 738 SVGFitToViewBox::Trace(visitor); |
| 739 } | 739 } |
| 740 | 740 |
| 741 } // namespace blink | 741 } // namespace blink |
| OLD | NEW |