Upstream version 9.38.198.0
[platform/framework/web/crosswalk.git] / src / third_party / WebKit / Source / core / svg / SVGTests.h
index 7df0e22..aeb20a1 100644 (file)
 #ifndef SVGTests_h
 #define SVGTests_h
 
-#include "core/svg/SVGStringList.h"
-#include "core/svg/properties/SVGAnimatedPropertyMacros.h"
+#include "core/svg/SVGStaticStringList.h"
 #include "wtf/HashSet.h"
 
-namespace WebCore {
+namespace blink {
 
-class Attribute;
 class QualifiedName;
 class SVGElement;
 
 class SVGTests {
 public:
-    SVGStringList& requiredFeatures();
-    SVGStringList& requiredExtensions();
-    SVGStringList& systemLanguage();
+    // JS API
+    SVGStringListTearOff* requiredFeatures() { return m_requiredFeatures->tearOff(); }
+    SVGStringListTearOff* requiredExtensions() { return m_requiredExtensions->tearOff(); }
+    SVGStringListTearOff* systemLanguage() { return m_systemLanguage->tearOff(); }
+    bool hasExtension(const String&);
 
-    bool hasExtension(const String&) const;
     bool isValid() const;
 
     bool parseAttribute(const QualifiedName&, const AtomicString&);
@@ -45,29 +44,15 @@ public:
 
     void addSupportedAttributes(HashSet<QualifiedName>&);
 
-    static SVGAttributeToPropertyMap& attributeToPropertyMap();
-
 protected:
-    SVGTests();
-
-    void synchronizeRequiredFeatures(SVGElement* contextElement);
-    void synchronizeRequiredExtensions(SVGElement* contextElement);
-    void synchronizeSystemLanguage(SVGElement* contextElement);
+    SVGTests(SVGElement* contextElement);
 
 private:
-    // Custom 'requiredFeatures' property
-    static const SVGPropertyInfo* requiredFeaturesPropertyInfo();
-    SVGSynchronizableAnimatedProperty<SVGStringList> m_requiredFeatures;
-
-    // Custom 'requiredExtensions' property
-    static const SVGPropertyInfo* requiredExtensionsPropertyInfo();
-    SVGSynchronizableAnimatedProperty<SVGStringList> m_requiredExtensions;
-
-    // Custom 'systemLanguage' property
-    static const SVGPropertyInfo* systemLanguagePropertyInfo();
-    SVGSynchronizableAnimatedProperty<SVGStringList> m_systemLanguage;
+    RefPtr<SVGStaticStringList> m_requiredFeatures;
+    RefPtr<SVGStaticStringList> m_requiredExtensions;
+    RefPtr<SVGStaticStringList> m_systemLanguage;
 };
 
-} // namespace WebCore
+} // namespace blink
 
 #endif // SVGTests_h