| OLD | NEW |
| (Empty) | |
| 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 |
| 3 // found in the LICENSE file. |
| 4 |
| 5 #ifndef MASH_LOGIN_UI_H_ |
| 6 #define MASH_LOGIN_UI_H_ |
| 7 |
| 8 #include <map> |
| 9 |
| 10 #include "base/macros.h" |
| 11 #include "base/memory/scoped_ptr.h" |
| 12 #include "components/mus/public/interfaces/user_access_manager.mojom.h" |
| 13 #include "ui/views/controls/button/label_button.h" |
| 14 #include "ui/views/widget/widget_delegate.h" |
| 15 |
| 16 namespace mojo { |
| 17 class Connection; |
| 18 class Connector; |
| 19 } |
| 20 |
| 21 namespace views { |
| 22 class AuraInit; |
| 23 } |
| 24 |
| 25 namespace mash { |
| 26 namespace login { |
| 27 |
| 28 class LoginController; |
| 29 |
| 30 class UI : public views::WidgetDelegateView, |
| 31 public views::ButtonListener { |
| 32 public: |
| 33 static void Show(mojo::Connector* connector, |
| 34 LoginController* login_controller); |
| 35 |
| 36 private: |
| 37 UI(LoginController* login_controller, mojo::Connector* connector); |
| 38 ~UI() override; |
| 39 |
| 40 // Overridden from views::WidgetDelegate: |
| 41 views::View* GetContentsView() override; |
| 42 base::string16 GetWindowTitle() const override; |
| 43 void DeleteDelegate() override; |
| 44 |
| 45 // Overridden from views::View: |
| 46 void Layout() override; |
| 47 |
| 48 // Overridden from views::ButtonListener: |
| 49 void ButtonPressed(views::Button* sender, const ui::Event& event) override; |
| 50 |
| 51 void StartWindowManager(); |
| 52 |
| 53 static bool is_showing_; |
| 54 LoginController* login_controller_; |
| 55 mojo::Connector* connector_; |
| 56 const std::string user_id_1_; |
| 57 const std::string user_id_2_; |
| 58 views::LabelButton* login_button_1_; |
| 59 views::LabelButton* login_button_2_; |
| 60 mus::mojom::UserAccessManagerPtr user_access_manager_; |
| 61 scoped_ptr<mojo::Connection> window_manager_connection_; |
| 62 |
| 63 DISALLOW_COPY_AND_ASSIGN(UI); |
| 64 }; |
| 65 |
| 66 } // namespace login |
| 67 } // namespace mash |
| 68 |
| 69 #endif // MASH_LOGIN_UI_H_ |
| OLD | NEW |