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

Side by Side Diff: chrome/browser/offline_pages/background_loader_offliner.h

Issue 2857063002: Add a way to send the resource percentage signal to the RC. (Closed)
Patch Set: CR Feedback per Dimich, BMcQuade, and CSHarrison Created 3 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 unified diff | Download patch
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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 CHROME_BROWSER_OFFLINE_PAGES_BACKGROUND_LOADER_OFFLINER_H_ 5 #ifndef CHROME_BROWSER_OFFLINE_PAGES_BACKGROUND_LOADER_OFFLINER_H_
6 #define CHROME_BROWSER_OFFLINE_PAGES_BACKGROUND_LOADER_OFFLINER_H_ 6 #define CHROME_BROWSER_OFFLINE_PAGES_BACKGROUND_LOADER_OFFLINER_H_
7 7
8 #include <memory> 8 #include <memory>
9 9
10 #include "base/android/application_status_listener.h" 10 #include "base/android/application_status_listener.h"
(...skipping 28 matching lines...) Expand all
39 39
40 static BackgroundLoaderOffliner* FromWebContents( 40 static BackgroundLoaderOffliner* FromWebContents(
41 content::WebContents* contents); 41 content::WebContents* contents);
42 42
43 // Offliner implementation. 43 // Offliner implementation.
44 bool LoadAndSave(const SavePageRequest& request, 44 bool LoadAndSave(const SavePageRequest& request,
45 const CompletionCallback& completion_callback, 45 const CompletionCallback& completion_callback,
46 const ProgressCallback& progress_callback) override; 46 const ProgressCallback& progress_callback) override;
47 bool Cancel(const CancelCallback& callback) override; 47 bool Cancel(const CancelCallback& callback) override;
48 bool HandleTimeout(int64_t request_id) override; 48 bool HandleTimeout(int64_t request_id) override;
49 void ObserveResourceTracking(const Offliner::ResourceDataType type,
50 int64_t started_count,
51 int64_t completed_count) override;
49 52
50 // WebContentsObserver implementation. 53 // WebContentsObserver implementation.
51 void DocumentAvailableInMainFrame() override; 54 void DocumentAvailableInMainFrame() override;
52 void DocumentOnLoadCompletedInMainFrame() override; 55 void DocumentOnLoadCompletedInMainFrame() override;
53 void RenderProcessGone(base::TerminationStatus status) override; 56 void RenderProcessGone(base::TerminationStatus status) override;
54 void WebContentsDestroyed() override; 57 void WebContentsDestroyed() override;
55 void DidFinishNavigation( 58 void DidFinishNavigation(
56 content::NavigationHandle* navigation_handle) override; 59 content::NavigationHandle* navigation_handle) override;
57 60
58 // SnapshotController::Client implementation. 61 // SnapshotController::Client implementation.
(...skipping 75 matching lines...) Expand 10 before | Expand all | Expand 10 after
134 137
135 // Callback for cancel. 138 // Callback for cancel.
136 CancelCallback cancel_callback_; 139 CancelCallback cancel_callback_;
137 140
138 base::WeakPtrFactory<BackgroundLoaderOffliner> weak_ptr_factory_; 141 base::WeakPtrFactory<BackgroundLoaderOffliner> weak_ptr_factory_;
139 DISALLOW_COPY_AND_ASSIGN(BackgroundLoaderOffliner); 142 DISALLOW_COPY_AND_ASSIGN(BackgroundLoaderOffliner);
140 }; 143 };
141 144
142 } // namespace offline_pages 145 } // namespace offline_pages
143 #endif // CHROME_BROWSER_OFFLINE_PAGES_BACKGROUND_LOADER_OFFLINER_H_ 146 #endif // CHROME_BROWSER_OFFLINE_PAGES_BACKGROUND_LOADER_OFFLINER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698