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

Unified Diff: third_party/WebKit/Source/modules/webusb/USBIsochronousInTransferResult.h

Issue 1964183004: Revert of Move DOMArrayBuffer, DOMArrayBufferViews and DataView to the heap. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 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
Index: third_party/WebKit/Source/modules/webusb/USBIsochronousInTransferResult.h
diff --git a/third_party/WebKit/Source/modules/webusb/USBIsochronousInTransferResult.h b/third_party/WebKit/Source/modules/webusb/USBIsochronousInTransferResult.h
index c24d2dc1cee98223e4c53db292cd17825a374443..fad2470ad4f035a432c87dc717885b4bd6e96ce2 100644
--- a/third_party/WebKit/Source/modules/webusb/USBIsochronousInTransferResult.h
+++ b/third_party/WebKit/Source/modules/webusb/USBIsochronousInTransferResult.h
@@ -17,12 +17,12 @@
class USBIsochronousInTransferResult final : public GarbageCollectedFinalized<USBIsochronousInTransferResult>, public ScriptWrappable {
DEFINE_WRAPPERTYPEINFO();
public:
- static USBIsochronousInTransferResult* create(DOMArrayBuffer* data, const HeapVector<Member<USBIsochronousInTransferPacket>>& packets)
+ static USBIsochronousInTransferResult* create(PassRefPtr<DOMArrayBuffer> data, const HeapVector<Member<USBIsochronousInTransferPacket>>& packets)
{
return new USBIsochronousInTransferResult(data, packets);
}
- USBIsochronousInTransferResult(DOMArrayBuffer* data, const HeapVector<Member<USBIsochronousInTransferPacket>>& packets)
+ USBIsochronousInTransferResult(PassRefPtr<DOMArrayBuffer> data, const HeapVector<Member<USBIsochronousInTransferPacket>>& packets)
: m_packets(packets)
{
unsigned byteLength = data->byteLength();
@@ -31,20 +31,16 @@
virtual ~USBIsochronousInTransferResult() {}
- DOMDataView* data() const { return m_data; }
+ PassRefPtr<DOMDataView> data() const { return m_data; }
const HeapVector<Member<USBIsochronousInTransferPacket>>& packets() const
{
return m_packets;
}
- DEFINE_INLINE_TRACE()
- {
- visitor->trace(m_data);
- visitor->trace(m_packets);
- }
+ DEFINE_INLINE_TRACE() { visitor->trace(m_packets); }
private:
- Member<DOMDataView> m_data;
+ RefPtr<DOMDataView> m_data;
const HeapVector<Member<USBIsochronousInTransferPacket>> m_packets;
};

Powered by Google App Engine
This is Rietveld 408576698