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

Unified Diff: sky/engine/platform/fetcher/MojoFetcher.h

Issue 678683004: HTMLImportLoader should talk directly to mojo::NetworkService (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: address reviewer comments Created 6 years, 2 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 | « sky/engine/platform/DEPS ('k') | sky/engine/platform/fetcher/MojoFetcher.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sky/engine/platform/fetcher/MojoFetcher.h
diff --git a/sky/engine/platform/fetcher/MojoFetcher.h b/sky/engine/platform/fetcher/MojoFetcher.h
new file mode 100644
index 0000000000000000000000000000000000000000..d435c6bc97906176ee1d51ca6d7a3f77ff09a982
--- /dev/null
+++ b/sky/engine/platform/fetcher/MojoFetcher.h
@@ -0,0 +1,39 @@
+// Copyright 2014 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef SKY_ENGINE_PLATFORM_FETCHER_MOJO_FETCHER_H_
+#define SKY_ENGINE_PLATFORM_FETCHER_MOJO_FETCHER_H_
+
+#include "base/memory/weak_ptr.h"
+#include "mojo/services/public/interfaces/network/url_loader.mojom.h"
+
+namespace blink {
+class KURL;
+
+class MojoFetcher {
+ public:
+ class Client {
+ public:
+ virtual void OnReceivedResponse(mojo::URLResponsePtr) = 0;
+
+ protected:
+ virtual ~Client() { }
+ };
+
+ MojoFetcher(Client*, const KURL&);
+ ~MojoFetcher();
+
+ private:
+ void OnReceivedResponse(mojo::URLResponsePtr);
+
+ Client* client_;
+ mojo::URLLoaderPtr url_loader_;
+ base::WeakPtrFactory<MojoFetcher> weak_factory_;
+
+ DISALLOW_COPY_AND_ASSIGN(MojoFetcher);
+};
+
+} // namespace blink
+
+#endif // SKY_ENGINE_PLATFORM_FETCHER_MOJO_FETCHER_H_
« no previous file with comments | « sky/engine/platform/DEPS ('k') | sky/engine/platform/fetcher/MojoFetcher.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698