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

Side by Side Diff: ios/chrome/browser/ui/downloads/download_manager_controller.h

Issue 2588713002: Upstream Chrome on iOS source code [4/11]. (Closed)
Patch Set: Created 4 years 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
(Empty)
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
3 // found in the LICENSE file.
4
5 #ifndef IOS_CHROME_BROWSER_UI_DOWNLOADS_DOWNLOAD_MANAGER_CONTROLLER_H_
6 #define IOS_CHROME_BROWSER_UI_DOWNLOADS_DOWNLOAD_MANAGER_CONTROLLER_H_
7
8 #import <UIKit/UIKit.h>
9
10 #import "ios/chrome/browser/ui/native_content_controller.h"
11
12 @protocol StoreKitLauncher;
13
14 namespace net {
15 class URLRequestContextGetter;
16 }
17
18 // This controller shows the native download manager. It shows the user basic
19 // information about the file (namely its type, size, and name), and gives them
20 // the option to download it and open it in another app. This controller is
21 // displayed when a URL is loaded that contains a file type that UIWebView
22 // cannot display itself.
23 @interface DownloadManagerController
24 : NativeContentController<UIDocumentInteractionControllerDelegate>
25
26 // Initializes a controller for content from |url|, using
27 // |requestContextGetter| for all requests necessary to download the file.
28 // |storeLauncher| is used to open a controller that allows the user to
29 // install Google Drive if they don't have it installed.
30 - (id)initWithURL:(const GURL&)url
31 requestContextGetter:(net::URLRequestContextGetter*)requestContextGetter
32 storeKitLauncher:(id<StoreKitLauncher>)storeLauncher;
33
34 // Starts loading the data for the file at the url passed into the
35 // initializer. This should only be called once, immediately after
36 // initialization.
37 - (void)start;
38
39 // Deletes the directory in which downloaded files are saved. It should only be
40 // called on the UI thread.
41 + (void)clearDownloadsDirectory;
42
43 @end
44
45 #endif // IOS_CHROME_BROWSER_UI_DOWNLOADS_DOWNLOAD_MANAGER_CONTROLLER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698