| 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_IMAGE_VIEW_H_ | 5 #ifndef CHROME_BROWSER_CHROMEOS_LOGIN_USER_IMAGE_VIEW_H_ |
| 6 #define CHROME_BROWSER_CHROMEOS_LOGIN_USER_IMAGE_VIEW_H_ | 6 #define CHROME_BROWSER_CHROMEOS_LOGIN_USER_IMAGE_VIEW_H_ |
| 7 | 7 |
| 8 #include "views/controls/button/button.h" | 8 #include "views/controls/button/button.h" |
| 9 #include "views/view.h" | 9 #include "views/view.h" |
| 10 | 10 |
| (...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 53 | 53 |
| 54 // Overridden from views::View: | 54 // Overridden from views::View: |
| 55 virtual gfx::Size GetPreferredSize(); | 55 virtual gfx::Size GetPreferredSize(); |
| 56 virtual void Layout(); | 56 virtual void Layout(); |
| 57 | 57 |
| 58 // Overridden from views::ButtonListener. | 58 // Overridden from views::ButtonListener. |
| 59 virtual void ButtonPressed(views::Button* sender, const views::Event& event); | 59 virtual void ButtonPressed(views::Button* sender, const views::Event& event); |
| 60 | 60 |
| 61 protected: | 61 protected: |
| 62 // views::View overrides: | 62 // views::View overrides: |
| 63 virtual void LocaleChanged(); | 63 virtual void OnLocaleChanged(); |
| 64 | 64 |
| 65 private: | 65 private: |
| 66 // Delete and recreate native controls that fail to update preferred size | 66 // Delete and recreate native controls that fail to update preferred size |
| 67 // after string update. | 67 // after string update. |
| 68 void RecreateNativeControls(); | 68 void RecreateNativeControls(); |
| 69 | 69 |
| 70 views::Label* title_label_; | 70 views::Label* title_label_; |
| 71 views::NativeButton* ok_button_; | 71 views::NativeButton* ok_button_; |
| 72 views::NativeButton* cancel_button_; | 72 views::NativeButton* cancel_button_; |
| 73 views::ImageButton* video_button_; | 73 views::ImageButton* video_button_; |
| 74 views::ImageView* selected_image_; | 74 views::ImageView* selected_image_; |
| 75 | 75 |
| 76 // Notifications receiver. | 76 // Notifications receiver. |
| 77 Delegate* delegate_; | 77 Delegate* delegate_; |
| 78 | 78 |
| 79 // Indicates that some image was selected and OK can be pressed. | 79 // Indicates that some image was selected and OK can be pressed. |
| 80 bool image_selected_; | 80 bool image_selected_; |
| 81 | 81 |
| 82 // Last frame that was received from the camera in its original resolution. | 82 // Last frame that was received from the camera in its original resolution. |
| 83 scoped_ptr<SkBitmap> last_frame_; | 83 scoped_ptr<SkBitmap> last_frame_; |
| 84 | 84 |
| 85 DISALLOW_COPY_AND_ASSIGN(UserImageView); | 85 DISALLOW_COPY_AND_ASSIGN(UserImageView); |
| 86 }; | 86 }; |
| 87 | 87 |
| 88 } // namespace chromeos | 88 } // namespace chromeos |
| 89 | 89 |
| 90 #endif // CHROME_BROWSER_CHROMEOS_LOGIN_USER_IMAGE_VIEW_H_ | 90 #endif // CHROME_BROWSER_CHROMEOS_LOGIN_USER_IMAGE_VIEW_H_ |
| 91 | 91 |
| OLD | NEW |