| OLD | NEW |
| 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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_BROWSER_CHROMEOS_LOGIN_USER_VIEW_H_ | 5 #ifndef CHROME_BROWSER_CHROMEOS_LOGIN_USER_VIEW_H_ |
| 6 #define CHROME_BROWSER_CHROMEOS_LOGIN_USER_VIEW_H_ | 6 #define CHROME_BROWSER_CHROMEOS_LOGIN_USER_VIEW_H_ |
| 7 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include <string> | 9 #include <string> |
| 10 | 10 |
| (...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 49 // view::View overrides. | 49 // view::View overrides. |
| 50 virtual gfx::Size GetPreferredSize(); | 50 virtual gfx::Size GetPreferredSize(); |
| 51 virtual void OnLocaleChanged(); | 51 virtual void OnLocaleChanged(); |
| 52 | 52 |
| 53 // Sets the user's image. | 53 // Sets the user's image. |
| 54 void SetImage(const SkBitmap& image, const SkBitmap& image_hot); | 54 void SetImage(const SkBitmap& image, const SkBitmap& image_hot); |
| 55 | 55 |
| 56 // Sets tooltip over the image. | 56 // Sets tooltip over the image. |
| 57 void SetTooltipText(const std::wstring& text); | 57 void SetTooltipText(const std::wstring& text); |
| 58 | 58 |
| 59 // Start/Stop throbber. | |
| 60 void StartThrobber(); | |
| 61 void StopThrobber(); | |
| 62 | |
| 63 // Show/Hide remove button. | 59 // Show/Hide remove button. |
| 64 void SetRemoveButtonVisible(bool flag); | 60 void SetRemoveButtonVisible(bool flag); |
| 65 | 61 |
| 66 // Enable/Disable sign-out button. | 62 // Enable/Disable sign-out button. |
| 67 void SetSignoutEnabled(bool enabled); | 63 void SetSignoutEnabled(bool enabled); |
| 68 | 64 |
| 69 // Implements LinkController. | 65 // Implements LinkController. |
| 70 // Called when a signout link is clicked. | 66 // Called when a signout link is clicked. |
| 71 virtual void LinkActivated(views::Link* source, int event_flags); | 67 virtual void LinkActivated(views::Link* source, int event_flags); |
| 72 | 68 |
| 73 // Overridden from views::ButtonListener. | 69 // Overridden from views::ButtonListener. |
| 74 virtual void ButtonPressed(views::Button* sender, const views::Event& event); | 70 virtual void ButtonPressed(views::Button* sender, const views::Event& event); |
| 75 | 71 |
| 76 private: | 72 private: |
| 77 void Init(bool need_background); | 73 void Init(bool need_background); |
| 78 | 74 |
| 79 Delegate* delegate_; | 75 Delegate* delegate_; |
| 80 | 76 |
| 81 SignoutView* signout_view_; | 77 SignoutView* signout_view_; |
| 82 PodImageView* image_view_; | 78 PodImageView* image_view_; |
| 83 | 79 |
| 84 views::Throbber* throbber_; | |
| 85 | |
| 86 views::TextButton* remove_button_; | 80 views::TextButton* remove_button_; |
| 87 | 81 |
| 88 DISALLOW_COPY_AND_ASSIGN(UserView); | 82 DISALLOW_COPY_AND_ASSIGN(UserView); |
| 89 }; | 83 }; |
| 90 | 84 |
| 91 } // chromeos | 85 } // chromeos |
| 92 | 86 |
| 93 #endif // CHROME_BROWSER_CHROMEOS_LOGIN_USER_VIEW_H_ | 87 #endif // CHROME_BROWSER_CHROMEOS_LOGIN_USER_VIEW_H_ |
| OLD | NEW |