| 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 COMPONENTS_ARC_INTENT_HELPER_ARC_INTENT_HELPER_BRIDGE_H_ | 5 #ifndef COMPONENTS_ARC_INTENT_HELPER_ARC_INTENT_HELPER_BRIDGE_H_ |
| 6 #define COMPONENTS_ARC_INTENT_HELPER_ARC_INTENT_HELPER_BRIDGE_H_ | 6 #define COMPONENTS_ARC_INTENT_HELPER_ARC_INTENT_HELPER_BRIDGE_H_ |
| 7 | 7 |
| 8 #include <memory> | 8 #include <memory> |
| 9 #include <string> | 9 #include <string> |
| 10 | 10 |
| (...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 47 void OnInstanceReady() override; | 47 void OnInstanceReady() override; |
| 48 void OnInstanceClosed() override; | 48 void OnInstanceClosed() override; |
| 49 | 49 |
| 50 // arc::mojom::IntentHelperHost | 50 // arc::mojom::IntentHelperHost |
| 51 void OnIconInvalidated(const mojo::String& package_name) override; | 51 void OnIconInvalidated(const mojo::String& package_name) override; |
| 52 void OnIntentFiltersUpdated( | 52 void OnIntentFiltersUpdated( |
| 53 mojo::Array<mojom::IntentFilterPtr> intent_filters) override; | 53 mojo::Array<mojom::IntentFilterPtr> intent_filters) override; |
| 54 void OnOpenDownloads() override; | 54 void OnOpenDownloads() override; |
| 55 void OnOpenUrl(const mojo::String& url) override; | 55 void OnOpenUrl(const mojo::String& url) override; |
| 56 void OpenWallpaperPicker() override; | 56 void OpenWallpaperPicker() override; |
| 57 void SetWallpaper(mojo::Array<uint8_t> jpeg_data) override; | |
| 58 | 57 |
| 59 // ash::LinkHandlerModelFactory | 58 // ash::LinkHandlerModelFactory |
| 60 std::unique_ptr<ash::LinkHandlerModel> CreateModel(const GURL& url) override; | 59 std::unique_ptr<ash::LinkHandlerModel> CreateModel(const GURL& url) override; |
| 61 | 60 |
| 62 // Returns false if |package_name| is for the intent_helper apk. | 61 // Returns false if |package_name| is for the intent_helper apk. |
| 63 static bool IsIntentHelperPackage(const std::string& package_name); | 62 static bool IsIntentHelperPackage(const std::string& package_name); |
| 64 | 63 |
| 65 // Filters out handlers that belong to the intent_helper apk and returns | 64 // Filters out handlers that belong to the intent_helper apk and returns |
| 66 // a new array. | 65 // a new array. |
| 67 static mojo::Array<mojom::UrlHandlerInfoPtr> FilterOutIntentHelper( | 66 static mojo::Array<mojom::UrlHandlerInfoPtr> FilterOutIntentHelper( |
| 68 mojo::Array<mojom::UrlHandlerInfoPtr> handlers); | 67 mojo::Array<mojom::UrlHandlerInfoPtr> handlers); |
| 69 | 68 |
| 70 private: | 69 private: |
| 71 mojo::Binding<mojom::IntentHelperHost> binding_; | 70 mojo::Binding<mojom::IntentHelperHost> binding_; |
| 72 scoped_refptr<ActivityIconLoader> icon_loader_; | 71 scoped_refptr<ActivityIconLoader> icon_loader_; |
| 73 scoped_refptr<LocalActivityResolver> activity_resolver_; | 72 scoped_refptr<LocalActivityResolver> activity_resolver_; |
| 74 | 73 |
| 75 base::ThreadChecker thread_checker_; | 74 base::ThreadChecker thread_checker_; |
| 76 | 75 |
| 77 DISALLOW_COPY_AND_ASSIGN(ArcIntentHelperBridge); | 76 DISALLOW_COPY_AND_ASSIGN(ArcIntentHelperBridge); |
| 78 }; | 77 }; |
| 79 | 78 |
| 80 } // namespace arc | 79 } // namespace arc |
| 81 | 80 |
| 82 #endif // COMPONENTS_ARC_INTENT_HELPER_ARC_INTENT_HELPER_BRIDGE_H_ | 81 #endif // COMPONENTS_ARC_INTENT_HELPER_ARC_INTENT_HELPER_BRIDGE_H_ |
| OLD | NEW |