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

Unified Diff: Source/core/dom/ResourceProgressEvent.idl

Issue 14773025: Create ResourceProgressEvent, expose as Chromium API (Closed) Base URL: https://chromium.googlesource.com/chromium/blink@master
Patch Set: merge Created 7 years, 7 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/dom/ResourceProgressEvent.cpp ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/dom/ResourceProgressEvent.idl
diff --git a/Source/wtf/ArrayBufferDeallocationObserver.h b/Source/core/dom/ResourceProgressEvent.idl
similarity index 68%
copy from Source/wtf/ArrayBufferDeallocationObserver.h
copy to Source/core/dom/ResourceProgressEvent.idl
index f75d729c14eccb4a683378b6d95235a1ca701e30..c08192a0a34a8819ab9dd8ae274d62ea244d6505 100644
--- a/Source/wtf/ArrayBufferDeallocationObserver.h
+++ b/Source/core/dom/ResourceProgressEvent.idl
@@ -1,5 +1,4 @@
/*
- * Copyright (C) 2009 Apple Inc. All rights reserved.
* Copyright (C) 2013 Google Inc. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@@ -21,21 +20,19 @@
* PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
* OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
- * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
-#ifndef ArrayBufferDeallocationObserver_h
-#define ArrayBufferDeallocationObserver_h
-
-namespace WTF {
-
-// The current implementation assumes that the instance of this class is a
-// singleton living for the entire process's lifetime.
-class ArrayBufferDeallocationObserver {
-public:
- virtual void ArrayBufferDeallocated(unsigned sizeInBytes) = 0;
+// ResourceProgressEvent is a non-standard class that is simply a ProgressEvent
+// with an additional read-only "url" property containing a string URL. This is
+// used by the Chromium NaCl integration to indicate to which resource the
+// event applies. This is useful because the NaCl integration will download
+// (and translate in the case of PNaCl) multiple binary files. It is not
+// constructable by web content at all, and so does not provide the usual
+// EventInit pattern for Event construction.
+[
+ NoInterfaceObject,
+] interface ResourceProgressEvent : ProgressEvent {
+ readonly attribute DOMString url;
};
-} // namespace WTF
-
-#endif // ArrayBufferDeallocationObserver_h
« no previous file with comments | « Source/core/dom/ResourceProgressEvent.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698