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

Unified Diff: Source/core/svg/properties/SVGAnimatedProperty.h

Issue 18707002: Reduce number of header includes in SVG (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Add Samsung copyright Created 7 years, 5 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « Source/core/svg/SVGZoomAndPan.h ('k') | Source/core/svg/properties/SVGAnimatedProperty.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/svg/properties/SVGAnimatedProperty.h
diff --git a/Source/core/svg/properties/SVGAnimatedProperty.h b/Source/core/svg/properties/SVGAnimatedProperty.h
index 39c956eb5afc4768731bb4e477e1836900ac817f..efdc5b20977f4b4e690e49bae01edc41c71a3dc2 100644
--- a/Source/core/svg/properties/SVGAnimatedProperty.h
+++ b/Source/core/svg/properties/SVGAnimatedProperty.h
@@ -1,5 +1,6 @@
/*
* Copyright (C) Research In Motion Limited 2010. All rights reserved.
+ * Copyright (C) 2013 Samsung Electronics. All rights reserved.
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Library General Public
@@ -20,7 +21,6 @@
#ifndef SVGAnimatedProperty_h
#define SVGAnimatedProperty_h
-#include "core/svg/SVGElement.h"
#include "core/svg/properties/SVGAnimatedPropertyDescription.h"
#include "core/svg/properties/SVGPropertyInfo.h"
#include <wtf/RefCounted.h>
@@ -38,34 +38,14 @@ public:
bool isReadOnly() const { return m_isReadOnly; }
void setIsReadOnly() { m_isReadOnly = true; }
- void commitChange()
- {
- ASSERT(m_contextElement);
- ASSERT(!m_contextElement->m_deletionHasBegun);
- m_contextElement->invalidateSVGAttributes();
- m_contextElement->svgAttributeChanged(m_attributeName);
- }
+ void commitChange();
virtual bool isAnimatedListTearOff() const { return false; }
// Caching facilities.
typedef HashMap<SVGAnimatedPropertyDescription, SVGAnimatedProperty*, SVGAnimatedPropertyDescriptionHash, SVGAnimatedPropertyDescriptionHashTraits> Cache;
- virtual ~SVGAnimatedProperty()
- {
- // Remove wrapper from cache.
- Cache* cache = animatedPropertyCache();
- const Cache::const_iterator end = cache->end();
- for (Cache::const_iterator it = cache->begin(); it != end; ++it) {
- if (it->value == this) {
- cache->remove(it->key);
- break;
- }
- }
-
- // Assure that animationEnded() was called, if animationStarted() was called before.
- ASSERT(!m_isAnimating);
- }
+ virtual ~SVGAnimatedProperty();
template<typename OwnerType, typename TearOffType, typename PropertyType>
static PassRefPtr<TearOffType> lookupOrCreateWrapper(OwnerType* element, const SVGPropertyInfo* info, PropertyType& property)
@@ -97,21 +77,10 @@ public:
}
protected:
- SVGAnimatedProperty(SVGElement* contextElement, const QualifiedName& attributeName, AnimatedPropertyType animatedPropertyType)
- : m_contextElement(contextElement)
- , m_attributeName(attributeName)
- , m_animatedPropertyType(animatedPropertyType)
- , m_isAnimating(false)
- , m_isReadOnly(false)
- {
- }
+ SVGAnimatedProperty(SVGElement*, const QualifiedName&, AnimatedPropertyType);
private:
- static Cache* animatedPropertyCache()
- {
- static Cache* s_cache = new Cache;
- return s_cache;
- }
+ static Cache* animatedPropertyCache();
RefPtr<SVGElement> m_contextElement;
const QualifiedName& m_attributeName;
« no previous file with comments | « Source/core/svg/SVGZoomAndPan.h ('k') | Source/core/svg/properties/SVGAnimatedProperty.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698