diff options
Diffstat (limited to 'WebCore/xml/XMLHttpRequestProgressEvent.h')
-rw-r--r-- | WebCore/xml/XMLHttpRequestProgressEvent.h | 50 |
1 files changed, 25 insertions, 25 deletions
diff --git a/WebCore/xml/XMLHttpRequestProgressEvent.h b/WebCore/xml/XMLHttpRequestProgressEvent.h index 009f1c0..27f3b8c 100644 --- a/WebCore/xml/XMLHttpRequestProgressEvent.h +++ b/WebCore/xml/XMLHttpRequestProgressEvent.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008, 2010 Apple Inc. All rights reserved. + * Copyright (C) 2008 Apple Inc. All rights reserved. * Copyright (C) 2008 Julien Chaffraix <jchaffraix@webkit.org>. All rights reserved. * * Redistribution and use in source and binary forms, with or without @@ -31,30 +31,30 @@ namespace WebCore { -class XMLHttpRequestProgressEvent : public ProgressEvent { -public: - static PassRefPtr<XMLHttpRequestProgressEvent> create() - { - return adoptRef(new XMLHttpRequestProgressEvent); - } - static PassRefPtr<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)); - } - - // Those 2 synonyms are included for compatibility with Firefox. - unsigned long long position() const { return loaded(); } - unsigned long long totalSize() const { return total(); } - -private: - virtual bool isXMLHttpRequestProgressEvent() const { return true; } - - XMLHttpRequestProgressEvent() { } - XMLHttpRequestProgressEvent(const AtomicString& type, bool lengthComputable, unsigned long long loaded, unsigned long long total) - : ProgressEvent(type, lengthComputable, loaded, total) - { - } -}; + class XMLHttpRequestProgressEvent : public ProgressEvent { + public: + static PassRefPtr<XMLHttpRequestProgressEvent> create() + { + return adoptRef(new XMLHttpRequestProgressEvent); + } + static PassRefPtr<XMLHttpRequestProgressEvent> create(const AtomicString& type, bool lengthComputable = false, unsigned loaded = 0, unsigned total = 0) + { + return adoptRef(new XMLHttpRequestProgressEvent(type, lengthComputable, loaded, total)); + } + + virtual bool isXMLHttpRequestProgressEvent() const { return true; } + + // Those 2 methods are to be compatible with Firefox and are only a wrapper on top of the real implementation. + unsigned position() const { return loaded(); } + unsigned totalSize() const { return total(); } + + private: + XMLHttpRequestProgressEvent() { } + XMLHttpRequestProgressEvent(const AtomicString& type, bool lengthComputable, unsigned loaded, unsigned total) + : ProgressEvent(type, lengthComputable, loaded, total) + { + } + }; } // namespace WebCore |