ozone: evdev: Sync caps lock LED state to evdev
[chromium-blink-merge.git] / chrome / browser / chromeos / extensions / file_manager / private_api_dialog.h
blob40ccd9729b850c46e5d7c8527cb7a0a3fee63440
1 // Copyright 2013 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 // This file provides API functions for the file manager to act as the file
6 // dialog for opening and saving files.
8 #ifndef CHROME_BROWSER_CHROMEOS_EXTENSIONS_FILE_MANAGER_PRIVATE_API_DIALOG_H_
9 #define CHROME_BROWSER_CHROMEOS_EXTENSIONS_FILE_MANAGER_PRIVATE_API_DIALOG_H_
11 #include <vector>
13 #include "chrome/browser/chromeos/extensions/file_manager/private_api_base.h"
15 namespace ui {
16 struct SelectedFileInfo;
19 namespace extensions {
21 // Cancel file selection Dialog. Closes the dialog window.
22 class FileManagerPrivateCancelDialogFunction
23 : public LoggedAsyncExtensionFunction {
24 public:
25 DECLARE_EXTENSION_FUNCTION("fileManagerPrivate.cancelDialog",
26 FILEMANAGERPRIVATE_CANCELDIALOG)
28 protected:
29 ~FileManagerPrivateCancelDialogFunction() override {}
31 // AsyncExtensionFunction overrides.
32 bool RunAsync() override;
35 class FileManagerPrivateSelectFileFunction
36 : public LoggedAsyncExtensionFunction {
37 public:
38 DECLARE_EXTENSION_FUNCTION("fileManagerPrivate.selectFile",
39 FILEMANAGERPRIVATE_SELECTFILE)
41 protected:
42 ~FileManagerPrivateSelectFileFunction() override {}
44 // AsyncExtensionFunction overrides.
45 bool RunAsync() override;
47 private:
48 // A callback method to handle the result of GetSelectedFileInfo.
49 void GetSelectedFileInfoResponse(
50 int index,
51 const std::vector<ui::SelectedFileInfo>& files);
54 // Select multiple files. Closes the dialog window.
55 class FileManagerPrivateSelectFilesFunction
56 : public LoggedAsyncExtensionFunction {
57 public:
58 DECLARE_EXTENSION_FUNCTION("fileManagerPrivate.selectFiles",
59 FILEMANAGERPRIVATE_SELECTFILES)
61 protected:
62 ~FileManagerPrivateSelectFilesFunction() override {}
64 // AsyncExtensionFunction overrides.
65 bool RunAsync() override;
67 private:
68 // A callback method to handle the result of GetSelectedFileInfo.
69 void GetSelectedFileInfoResponse(
70 const std::vector<ui::SelectedFileInfo>& files);
73 } // namespace extensions
75 #endif // CHROME_BROWSER_CHROMEOS_EXTENSIONS_FILE_MANAGER_PRIVATE_API_DIALOG_H_