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

Unified Diff: mojo/examples/html_viewer/html_viewer.cc

Issue 373373002: Mojo: Refactor URLLoader interface. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fixes per review Created 6 years, 5 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 | « mojo/examples/html_viewer/html_document_view.cc ('k') | mojo/examples/html_viewer/weburlloader_impl.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: mojo/examples/html_viewer/html_viewer.cc
diff --git a/mojo/examples/html_viewer/html_viewer.cc b/mojo/examples/html_viewer/html_viewer.cc
index 235d4ab28629656a58f65661eeb4d83f811c9f9a..9a947f41bc788567a95e4dc91e9ff54dfef28848 100644
--- a/mojo/examples/html_viewer/html_viewer.cc
+++ b/mojo/examples/html_viewer/html_viewer.cc
@@ -47,11 +47,9 @@ class HTMLViewer : public ApplicationDelegate,
blink::shutdown();
}
- void Load(URLResponsePtr response,
- ScopedDataPipeConsumerHandle response_body_stream) {
+ void Load(URLResponsePtr response) {
// Need to wait for OnRootAdded.
response_ = response.Pass();
- response_body_stream_ = response_body_stream.Pass();
MaybeLoad();
}
@@ -82,7 +80,7 @@ class HTMLViewer : public ApplicationDelegate,
void MaybeLoad() {
if (document_view_ && response_.get())
- document_view_->Load(response_.Pass(), response_body_stream_.Pass());
+ document_view_->Load(response_.Pass());
}
scoped_ptr<BlinkPlatformImpl> blink_platform_impl_;
@@ -91,7 +89,6 @@ class HTMLViewer : public ApplicationDelegate,
// TODO(darin): Figure out proper ownership of this instance.
HTMLDocumentView* document_view_;
URLResponsePtr response_;
- ScopedDataPipeConsumerHandle response_body_stream_;
DISALLOW_COPY_AND_ASSIGN(HTMLViewer);
};
@@ -102,8 +99,7 @@ void NavigatorImpl::Navigate(
navigation::ResponseDetailsPtr response_details) {
printf("In HTMLViewer, rendering url: %s\n",
response_details->response->url.data());
- viewer_->Load(response_details->response.Pass(),
- response_details->response_body_stream.Pass());
+ viewer_->Load(response_details->response.Pass());
}
}
« no previous file with comments | « mojo/examples/html_viewer/html_document_view.cc ('k') | mojo/examples/html_viewer/weburlloader_impl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698