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

Side by Side Diff: content/renderer/fetchers/resource_fetcher_impl.h

Issue 1873783003: Convert //content/renderer from scoped_ptr to std::unique_ptr (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 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
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 #ifndef CONTENT_RENDERER_FETCHERS_RESOURCE_FETCHER_IMPL_H_ 5 #ifndef CONTENT_RENDERER_FETCHERS_RESOURCE_FETCHER_IMPL_H_
6 #define CONTENT_RENDERER_FETCHERS_RESOURCE_FETCHER_IMPL_H_ 6 #define CONTENT_RENDERER_FETCHERS_RESOURCE_FETCHER_IMPL_H_
7 7
8 #include <memory>
8 #include <string> 9 #include <string>
9 10
10 #include "base/callback.h" 11 #include "base/callback.h"
11 #include "base/compiler_specific.h" 12 #include "base/compiler_specific.h"
12 #include "base/macros.h" 13 #include "base/macros.h"
13 #include "base/memory/scoped_ptr.h"
14 #include "base/timer/timer.h" 14 #include "base/timer/timer.h"
15 #include "content/public/renderer/resource_fetcher.h" 15 #include "content/public/renderer/resource_fetcher.h"
16 #include "content/renderer/fetchers/web_url_loader_client_impl.h" 16 #include "content/renderer/fetchers/web_url_loader_client_impl.h"
17 #include "third_party/WebKit/public/platform/WebURLRequest.h" 17 #include "third_party/WebKit/public/platform/WebURLRequest.h"
18 #include "third_party/WebKit/public/platform/WebURLResponse.h" 18 #include "third_party/WebKit/public/platform/WebURLResponse.h"
19 #include "third_party/WebKit/public/web/WebURLLoaderOptions.h" 19 #include "third_party/WebKit/public/web/WebURLLoaderOptions.h"
20 20
21 class GURL; 21 class GURL;
22 22
23 namespace blink { 23 namespace blink {
(...skipping 29 matching lines...) Expand all
53 ~ResourceFetcherImpl() override; 53 ~ResourceFetcherImpl() override;
54 54
55 // Callback for timer that limits how long we wait for the server. If this 55 // Callback for timer that limits how long we wait for the server. If this
56 // timer fires and the request hasn't completed, we kill the request. 56 // timer fires and the request hasn't completed, we kill the request.
57 void TimeoutFired(); 57 void TimeoutFired();
58 58
59 // WebURLLoaderClientImpl methods: 59 // WebURLLoaderClientImpl methods:
60 void OnLoadComplete() override; 60 void OnLoadComplete() override;
61 void Cancel() override; 61 void Cancel() override;
62 62
63 scoped_ptr<blink::WebURLLoader> loader_; 63 std::unique_ptr<blink::WebURLLoader> loader_;
64 64
65 // Options to send to the loader. 65 // Options to send to the loader.
66 blink::WebURLLoaderOptions options_; 66 blink::WebURLLoaderOptions options_;
67 67
68 // Request to send. Released once Start() is called. 68 // Request to send. Released once Start() is called.
69 blink::WebURLRequest request_; 69 blink::WebURLRequest request_;
70 70
71 // Callback when we're done. 71 // Callback when we're done.
72 Callback callback_; 72 Callback callback_;
73 73
74 // Limit how long to wait for the server. 74 // Limit how long to wait for the server.
75 base::OneShotTimer timeout_timer_; 75 base::OneShotTimer timeout_timer_;
76 76
77 DISALLOW_COPY_AND_ASSIGN(ResourceFetcherImpl); 77 DISALLOW_COPY_AND_ASSIGN(ResourceFetcherImpl);
78 }; 78 };
79 79
80 } // namespace content 80 } // namespace content
81 81
82 #endif // CONTENT_RENDERER_FETCHERS_RESOURCE_FETCHER_IMPL_H_ 82 #endif // CONTENT_RENDERER_FETCHERS_RESOURCE_FETCHER_IMPL_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698