OLD | NEW |
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_UTILITY_SHELL_HANDLER_IMPL_WIN_H_ | 5 #ifndef CHROME_UTILITY_SHELL_HANDLER_IMPL_WIN_H_ |
6 #define CHROME_UTILITY_SHELL_HANDLER_IMPL_WIN_H_ | 6 #define CHROME_UTILITY_SHELL_HANDLER_IMPL_WIN_H_ |
7 | 7 |
| 8 #include <tuple> |
| 9 #include <vector> |
| 10 |
8 #include "base/macros.h" | 11 #include "base/macros.h" |
9 #include "chrome/common/shell_handler_win.mojom.h" | 12 #include "chrome/common/shell_handler_win.mojom.h" |
10 #include "mojo/public/cpp/bindings/strong_binding.h" | 13 #include "mojo/public/cpp/bindings/strong_binding.h" |
11 | 14 |
12 // Implements the ShellHandler mojo interface. | 15 // Implements the ShellHandler mojo interface. |
13 class ShellHandlerImpl : public mojom::ShellHandler { | 16 class ShellHandlerImpl : public mojom::ShellHandler { |
14 public: | 17 public: |
15 static void Create(mojom::ShellHandlerRequest request); | 18 static void Create(mojom::ShellHandlerRequest request); |
16 | 19 |
17 private: | 20 private: |
18 explicit ShellHandlerImpl(mojom::ShellHandlerRequest request); | 21 explicit ShellHandlerImpl(mojom::ShellHandlerRequest request); |
19 ~ShellHandlerImpl() override; | 22 ~ShellHandlerImpl() override; |
20 | 23 |
21 // mojom::ShellHandler: | 24 // mojom::ShellHandler: |
22 void IsPinnedToTaskbar(const IsPinnedToTaskbarCallback& callback) override; | 25 void IsPinnedToTaskbar(const IsPinnedToTaskbarCallback& callback) override; |
23 | 26 |
| 27 void DoGetOpenFileName( |
| 28 uint32_t owner, |
| 29 uint32_t flags, |
| 30 const std::vector<std::tuple<base::string16, base::string16>>& filters, |
| 31 const base::FilePath& initial_directory, |
| 32 const base::FilePath& filename, |
| 33 const DoGetOpenFileNameCallback& callback) override; |
| 34 |
| 35 void DoGetSaveFileName( |
| 36 uint32_t owner, |
| 37 uint32_t flags, |
| 38 const std::vector<std::tuple<base::string16, base::string16>>& filters, |
| 39 uint32_t one_based_filter_index, |
| 40 const base::FilePath& initial_directory, |
| 41 const base::FilePath& suggested_filename, |
| 42 const base::FilePath& default_extension, |
| 43 const DoGetSaveFileNameCallback& callback) override; |
| 44 |
24 mojo::StrongBinding<ShellHandler> binding_; | 45 mojo::StrongBinding<ShellHandler> binding_; |
25 | 46 |
26 DISALLOW_COPY_AND_ASSIGN(ShellHandlerImpl); | 47 DISALLOW_COPY_AND_ASSIGN(ShellHandlerImpl); |
27 }; | 48 }; |
28 | 49 |
29 #endif // CHROME_UTILITY_SHELL_HANDLER_IMPL_WIN_H_ | 50 #endif // CHROME_UTILITY_SHELL_HANDLER_IMPL_WIN_H_ |
OLD | NEW |