Avi Drissman | 4a8573c | 2022-09-09 19:35:54 | [diff] [blame] | 1 | // Copyright 2018 The Chromium Authors |
Finnur Thorarinsson | 658449a | 2018-10-09 11:18:26 | [diff] [blame] | 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 CHROME_BROWSER_FILE_SELECT_HELPER_CONTACTS_ANDROID_H_ |
| 6 | #define CHROME_BROWSER_FILE_SELECT_HELPER_CONTACTS_ANDROID_H_ |
| 7 | |
| 8 | #include "chrome/browser/file_select_helper.h" |
| 9 | |
| 10 | class FileSelectHelperContactsAndroid : public FileSelectHelper { |
| 11 | public: |
Peter Boström | fadb175 | 2021-09-30 19:17:01 | [diff] [blame] | 12 | FileSelectHelperContactsAndroid(const FileSelectHelperContactsAndroid&) = |
| 13 | delete; |
| 14 | FileSelectHelperContactsAndroid& operator=( |
| 15 | const FileSelectHelperContactsAndroid&) = delete; |
| 16 | |
Finnur Thorarinsson | 658449a | 2018-10-09 11:18:26 | [diff] [blame] | 17 | // A SelectFileDialog::Listener override. |file| and |index| are unused in |
| 18 | // this override, since the file contents are passed in as string to |params|. |
| 19 | void FileSelectedWithExtraInfo(const ui::SelectedFileInfo& file, |
| 20 | int index, |
| 21 | void* params) override; |
| 22 | |
| 23 | private: |
| 24 | friend class FileSelectHelper; |
| 25 | |
| 26 | explicit FileSelectHelperContactsAndroid(Profile* profile); |
| 27 | ~FileSelectHelperContactsAndroid() override = default; |
| 28 | |
| 29 | void ProcessContactsForAndroid(const std::string& contacts); |
| 30 | void ProcessContactsForAndroidOnUIThread(const base::FilePath& temp_file); |
Finnur Thorarinsson | 658449a | 2018-10-09 11:18:26 | [diff] [blame] | 31 | }; |
| 32 | |
| 33 | #endif // CHROME_BROWSER_FILE_SELECT_HELPER_CONTACTS_ANDROID_H_ |