| 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 #include <vector> | 10 #include <vector> |
| (...skipping 12 matching lines...) Expand all Loading... |
| 23 namespace ash { | 23 namespace ash { |
| 24 | 24 |
| 25 class LinkHandlerModel; | 25 class LinkHandlerModel; |
| 26 | 26 |
| 27 } // namespace ash | 27 } // namespace ash |
| 28 | 28 |
| 29 namespace arc { | 29 namespace arc { |
| 30 | 30 |
| 31 class ActivityIconLoader; | 31 class ActivityIconLoader; |
| 32 class ArcBridgeService; | 32 class ArcBridgeService; |
| 33 class IntentFilter; | |
| 34 class LocalActivityResolver; | 33 class LocalActivityResolver; |
| 35 | 34 |
| 36 // Receives intents from ARC. | 35 // Receives intents from ARC. |
| 37 class ArcIntentHelperBridge | 36 class ArcIntentHelperBridge |
| 38 : public ArcService, | 37 : public ArcService, |
| 39 public InstanceHolder<mojom::IntentHelperInstance>::Observer, | 38 public InstanceHolder<mojom::IntentHelperInstance>::Observer, |
| 40 public mojom::IntentHelperHost, | 39 public mojom::IntentHelperHost, |
| 41 public ash::LinkHandlerModelFactory { | 40 public ash::LinkHandlerModelFactory { |
| 42 public: | 41 public: |
| 43 enum class GetResult { | 42 enum class GetResult { |
| (...skipping 14 matching lines...) Expand all Loading... |
| 58 void AddObserver(ArcIntentHelperObserver* observer); | 57 void AddObserver(ArcIntentHelperObserver* observer); |
| 59 void RemoveObserver(ArcIntentHelperObserver* observer); | 58 void RemoveObserver(ArcIntentHelperObserver* observer); |
| 60 | 59 |
| 61 // InstanceHolder<mojom::IntentHelperInstance>::Observer | 60 // InstanceHolder<mojom::IntentHelperInstance>::Observer |
| 62 void OnInstanceReady() override; | 61 void OnInstanceReady() override; |
| 63 void OnInstanceClosed() override; | 62 void OnInstanceClosed() override; |
| 64 | 63 |
| 65 // mojom::IntentHelperHost | 64 // mojom::IntentHelperHost |
| 66 void OnIconInvalidated(const std::string& package_name) override; | 65 void OnIconInvalidated(const std::string& package_name) override; |
| 67 void OnIntentFiltersUpdated( | 66 void OnIntentFiltersUpdated( |
| 68 std::vector<IntentFilter> intent_filters) override; | 67 std::vector<mojom::IntentFilterPtr> intent_filters) override; |
| 69 void OnOpenDownloads() override; | 68 void OnOpenDownloads() override; |
| 70 void OnOpenUrl(const std::string& url) override; | 69 void OnOpenUrl(const std::string& url) override; |
| 71 void OpenWallpaperPicker() override; | 70 void OpenWallpaperPicker() override; |
| 72 void SetWallpaperDeprecated(const std::vector<uint8_t>& jpeg_data) override; | 71 void SetWallpaperDeprecated(const std::vector<uint8_t>& jpeg_data) override; |
| 73 | 72 |
| 74 // ash::LinkHandlerModelFactory | 73 // ash::LinkHandlerModelFactory |
| 75 std::unique_ptr<ash::LinkHandlerModel> CreateModel(const GURL& url) override; | 74 std::unique_ptr<ash::LinkHandlerModel> CreateModel(const GURL& url) override; |
| 76 | 75 |
| 77 // Returns false if |package_name| is for the intent_helper apk. | 76 // Returns false if |package_name| is for the intent_helper apk. |
| 78 static bool IsIntentHelperPackage(const std::string& package_name); | 77 static bool IsIntentHelperPackage(const std::string& package_name); |
| (...skipping 25 matching lines...) Expand all Loading... |
| 104 base::ThreadChecker thread_checker_; | 103 base::ThreadChecker thread_checker_; |
| 105 | 104 |
| 106 base::ObserverList<ArcIntentHelperObserver> observer_list_; | 105 base::ObserverList<ArcIntentHelperObserver> observer_list_; |
| 107 | 106 |
| 108 DISALLOW_COPY_AND_ASSIGN(ArcIntentHelperBridge); | 107 DISALLOW_COPY_AND_ASSIGN(ArcIntentHelperBridge); |
| 109 }; | 108 }; |
| 110 | 109 |
| 111 } // namespace arc | 110 } // namespace arc |
| 112 | 111 |
| 113 #endif // COMPONENTS_ARC_INTENT_HELPER_ARC_INTENT_HELPER_BRIDGE_H_ | 112 #endif // COMPONENTS_ARC_INTENT_HELPER_ARC_INTENT_HELPER_BRIDGE_H_ |
| OLD | NEW |