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

Side by Side Diff: third_party/WebKit/Source/modules/presentation/PresentationConnection.cpp

Issue 2777403002: [Presentation API] Change PresentationConnection's default binaryType to ArrayBuffer (Closed)
Patch Set: Created 3 years, 8 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 unified diff | Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "modules/presentation/PresentationConnection.h" 5 #include "modules/presentation/PresentationConnection.h"
6 6
7 #include "bindings/core/v8/ScriptPromiseResolver.h" 7 #include "bindings/core/v8/ScriptPromiseResolver.h"
8 #include "core/dom/DOMArrayBuffer.h" 8 #include "core/dom/DOMArrayBuffer.h"
9 #include "core/dom/DOMArrayBufferView.h" 9 #include "core/dom/DOMArrayBufferView.h"
10 #include "core/dom/Document.h" 10 #include "core/dom/Document.h"
(...skipping 134 matching lines...) Expand 10 before | Expand all | Expand 10 after
145 std::unique_ptr<FileReaderLoader> m_loader; 145 std::unique_ptr<FileReaderLoader> m_loader;
146 }; 146 };
147 147
148 PresentationConnection::PresentationConnection(LocalFrame* frame, 148 PresentationConnection::PresentationConnection(LocalFrame* frame,
149 const String& id, 149 const String& id,
150 const KURL& url) 150 const KURL& url)
151 : ContextClient(frame), 151 : ContextClient(frame),
152 m_id(id), 152 m_id(id),
153 m_url(url), 153 m_url(url),
154 m_state(WebPresentationConnectionState::Connecting), 154 m_state(WebPresentationConnectionState::Connecting),
155 m_binaryType(BinaryTypeBlob), 155 m_binaryType(BinaryTypeArrayBuffer),
156 m_proxy(nullptr) {} 156 m_proxy(nullptr) {}
157 157
158 PresentationConnection::~PresentationConnection() { 158 PresentationConnection::~PresentationConnection() {
159 ASSERT(!m_blobLoader); 159 ASSERT(!m_blobLoader);
160 } 160 }
161 161
162 void PresentationConnection::bindProxy( 162 void PresentationConnection::bindProxy(
163 std::unique_ptr<WebPresentationConnectionProxy> proxy) { 163 std::unique_ptr<WebPresentationConnectionProxy> proxy) {
164 DCHECK(proxy); 164 DCHECK(proxy);
165 m_proxy = std::move(proxy); 165 m_proxy = std::move(proxy);
(...skipping 350 matching lines...) Expand 10 before | Expand all | Expand 10 after
516 void PresentationConnection::tearDown() { 516 void PresentationConnection::tearDown() {
517 // Cancel current Blob loading if any. 517 // Cancel current Blob loading if any.
518 if (m_blobLoader) { 518 if (m_blobLoader) {
519 m_blobLoader->cancel(); 519 m_blobLoader->cancel();
520 m_blobLoader.clear(); 520 m_blobLoader.clear();
521 } 521 }
522 m_messages.clear(); 522 m_messages.clear();
523 } 523 }
524 524
525 } // namespace blink 525 } // namespace blink
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698