Upstream version 11.39.266.0
[platform/framework/web/crosswalk.git] / src / third_party / WebKit / Source / core / xml / XMLHttpRequestProgressEvent.h
index c6ab4a4..615c699 100644 (file)
 #define XMLHttpRequestProgressEvent_h
 
 #include "core/events/ProgressEvent.h"
-#include "core/events/ThreadLocalEventNames.h"
 
-namespace WebCore {
+namespace blink {
 
-class XMLHttpRequestProgressEvent : public ProgressEvent {
+class XMLHttpRequestProgressEvent FINAL : public ProgressEvent {
+    DEFINE_WRAPPERTYPEINFO();
 public:
-    static PassRefPtr<XMLHttpRequestProgressEvent> create()
+    static PassRefPtrWillBeRawPtr<XMLHttpRequestProgressEvent> create()
     {
-        return adoptRef(new XMLHttpRequestProgressEvent);
+        return adoptRefWillBeNoop(new XMLHttpRequestProgressEvent);
     }
-    static PassRefPtr<XMLHttpRequestProgressEvent> create(const AtomicString& type, bool lengthComputable = false, unsigned long long loaded = 0, unsigned long long total = 0)
+    static PassRefPtrWillBeRawPtr<XMLHttpRequestProgressEvent> create(const AtomicString& type, bool lengthComputable = false, unsigned long long loaded = 0, unsigned long long total = 0)
     {
-        return adoptRef(new XMLHttpRequestProgressEvent(type, lengthComputable, loaded, total));
+        return adoptRefWillBeNoop(new XMLHttpRequestProgressEvent(type, lengthComputable, loaded, total));
     }
 
     // Those 2 synonyms are included for compatibility with Firefox.
     unsigned long long position() const { return loaded(); }
     unsigned long long totalSize() const { return total(); }
 
-    virtual const AtomicString& interfaceName() const { return EventNames::XMLHttpRequestProgressEvent; }
+    virtual const AtomicString& interfaceName() const OVERRIDE { return EventNames::XMLHttpRequestProgressEvent; }
+
+    virtual void trace(Visitor* visitor) OVERRIDE { ProgressEvent::trace(visitor); }
 
 private:
-    XMLHttpRequestProgressEvent()
-    {
-        ScriptWrappable::init(this);
-    }
+    XMLHttpRequestProgressEvent() { }
 
     XMLHttpRequestProgressEvent(const AtomicString& type, bool lengthComputable, unsigned long long loaded, unsigned long long total)
-        : ProgressEvent(type, lengthComputable, loaded, total)
-    {
-        ScriptWrappable::init(this);
-    }
+        : ProgressEvent(type, lengthComputable, loaded, total) { }
 };
 
-} // namespace WebCore
+} // namespace blink
 
 #endif // XMLHttpRequestProgressEvent_h