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

Side by Side Diff: chrome/browser/ui/webui/settings/downloads_handler.h

Issue 2713343003: MD Settings: Add "Auto Open" setting to Downloads page UI. (Closed)
Patch Set: format Created 3 years, 9 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) 2015 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2015 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_UI_WEBUI_SETTINGS_DOWNLOADS_HANDLER_H_ 5 #ifndef CHROME_BROWSER_UI_WEBUI_SETTINGS_DOWNLOADS_HANDLER_H_
6 #define CHROME_BROWSER_UI_WEBUI_SETTINGS_DOWNLOADS_HANDLER_H_ 6 #define CHROME_BROWSER_UI_WEBUI_SETTINGS_DOWNLOADS_HANDLER_H_
7 7
8 #include <memory> 8 #include <memory>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 21 matching lines...) Expand all
32 private: 32 private:
33 friend class DownloadsHandlerTest; 33 friend class DownloadsHandlerTest;
34 FRIEND_TEST_ALL_PREFIXES(DownloadsHandlerTest, AutoOpenDownloads); 34 FRIEND_TEST_ALL_PREFIXES(DownloadsHandlerTest, AutoOpenDownloads);
35 35
36 // Callback for the "initializeDownloads" message. This starts observers and 36 // Callback for the "initializeDownloads" message. This starts observers and
37 // retrieves the current browser state. 37 // retrieves the current browser state.
38 void HandleInitialize(const base::ListValue* args); 38 void HandleInitialize(const base::ListValue* args);
39 39
40 void SendAutoOpenDownloadsToJavascript(); 40 void SendAutoOpenDownloadsToJavascript();
41 41
42 // Resets the list of filetypes that are auto-opened after download.
43 void HandleResetAutoOpenFileTypes(const base::ListValue* args);
44
42 // Callback for the "selectDownloadLocation" message. This will prompt the 45 // Callback for the "selectDownloadLocation" message. This will prompt the
43 // user for a destination folder using platform-specific APIs. 46 // user for a destination folder using platform-specific APIs.
44 void HandleSelectDownloadLocation(const base::ListValue* args); 47 void HandleSelectDownloadLocation(const base::ListValue* args);
45 48
46 // SelectFileDialog::Listener implementation. 49 // SelectFileDialog::Listener implementation.
47 void FileSelected(const base::FilePath& path, 50 void FileSelected(const base::FilePath& path,
48 int index, 51 int index,
49 void* params) override; 52 void* params) override;
50 53
51 Profile* profile_; 54 Profile* profile_;
52 55
53 PrefChangeRegistrar pref_registrar_; 56 PrefChangeRegistrar pref_registrar_;
54 57
55 scoped_refptr<ui::SelectFileDialog> select_folder_dialog_; 58 scoped_refptr<ui::SelectFileDialog> select_folder_dialog_;
56 59
57 DISALLOW_COPY_AND_ASSIGN(DownloadsHandler); 60 DISALLOW_COPY_AND_ASSIGN(DownloadsHandler);
58 }; 61 };
59 62
60 } // namespace settings 63 } // namespace settings
61 64
62 #endif // CHROME_BROWSER_UI_WEBUI_SETTINGS_DOWNLOADS_HANDLER_H_ 65 #endif // CHROME_BROWSER_UI_WEBUI_SETTINGS_DOWNLOADS_HANDLER_H_
OLDNEW
« no previous file with comments | « chrome/browser/resources/settings/settings_resources.grd ('k') | chrome/browser/ui/webui/settings/downloads_handler.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698