Chromium Code Reviews| Index: ash/common/system/locale/locale_notification_controller.h |
| diff --git a/ash/common/system/locale/locale_notification_controller.h b/ash/common/system/locale/locale_notification_controller.h |
| index 24f27a6fdb2cee220aa9be3d90e615a40de7c93a..0d74b4998b6bd455b577881c40a7d3b8d9cb8c2d 100644 |
| --- a/ash/common/system/locale/locale_notification_controller.h |
| +++ b/ash/common/system/locale/locale_notification_controller.h |
| @@ -7,28 +7,36 @@ |
| #include <string> |
| -#include "ash/common/system/locale/locale_observer.h" |
| +#include "ash/public/interfaces/locale.mojom.h" |
| #include "base/macros.h" |
| +#include "mojo/public/cpp/bindings/binding_set.h" |
| namespace ash { |
| // Observes the locale change and creates rich notification for the change. |
| -class LocaleNotificationController : public LocaleObserver { |
| +class LocaleNotificationController |
| + : public mojom::LocaleNotificationController { |
| public: |
| LocaleNotificationController(); |
| ~LocaleNotificationController() override; |
| + void BindRequest(mojom::LocaleNotificationControllerRequest request); |
|
msw
2016/10/14 01:46:29
nit: comment (copy from ShelfController or similar
|
| + |
| private: |
| - // Overridden from LocaleObserver. |
| - void OnLocaleChanged(LocaleObserver::Delegate* delegate, |
| - const std::string& cur_locale, |
| - const std::string& from_locale, |
| - const std::string& to_locale) override; |
| + // Overridden from mojom::LocaleNotificationController: |
| + void NotifyLocaleChanged( |
|
msw
2016/10/14 01:46:29
Keep the name as OnLocaleChanged (it's a handler t
|
| + const std::string& cur_locale, |
| + const std::string& from_locale, |
| + const std::string& to_locale, |
| + const NotifyLocaleChangedCallback& callback) override; |
| std::string cur_locale_; |
| std::string from_locale_; |
| std::string to_locale_; |
| + // Bindings for the LocaleNotificationController interface. |
| + mojo::BindingSet<mojom::LocaleNotificationController> bindings_; |
| + |
| DISALLOW_COPY_AND_ASSIGN(LocaleNotificationController); |
| }; |