OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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_UI_WEBUI_CHROMEOS_LOGIN_USER_IMAGE_SCREEN_HANDLER_H_ | 5 #ifndef CHROME_BROWSER_UI_WEBUI_CHROMEOS_LOGIN_USER_IMAGE_SCREEN_HANDLER_H_ |
6 #define CHROME_BROWSER_UI_WEBUI_CHROMEOS_LOGIN_USER_IMAGE_SCREEN_HANDLER_H_ | 6 #define CHROME_BROWSER_UI_WEBUI_CHROMEOS_LOGIN_USER_IMAGE_SCREEN_HANDLER_H_ |
7 | 7 |
8 #include "base/memory/weak_ptr.h" | 8 #include "base/memory/weak_ptr.h" |
9 #include "base/time.h" | 9 #include "base/time.h" |
10 #include "chrome/browser/chromeos/login/user_image_screen_actor.h" | 10 #include "chrome/browser/chromeos/login/user_image_screen_actor.h" |
(...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
56 // TakePhotoDialog::Delegate implementation. | 56 // TakePhotoDialog::Delegate implementation. |
57 virtual void OnPhotoAccepted(const gfx::ImageSkia& photo) OVERRIDE; | 57 virtual void OnPhotoAccepted(const gfx::ImageSkia& photo) OVERRIDE; |
58 | 58 |
59 private: | 59 private: |
60 // Sends profile image as a data URL to the page. | 60 // Sends profile image as a data URL to the page. |
61 void SendProfileImage(const std::string& data_url); | 61 void SendProfileImage(const std::string& data_url); |
62 | 62 |
63 // Opens the camera capture dialog. | 63 // Opens the camera capture dialog. |
64 void HandleTakePhoto(const base::ListValue* args); | 64 void HandleTakePhoto(const base::ListValue* args); |
65 | 65 |
| 66 // Handles photo taken with WebRTC UI. |
| 67 void HandlePhotoTaken(const base::ListValue* args); |
| 68 |
66 // Handles clicking on default user image. | 69 // Handles clicking on default user image. |
67 void HandleSelectImage(const base::ListValue* args); | 70 void HandleSelectImage(const base::ListValue* args); |
68 | 71 |
69 // Called when user accept the image closing the screen. | 72 // Called when user accept the image closing the screen. |
70 void HandleImageAccepted(const base::ListValue* args); | 73 void HandleImageAccepted(const base::ListValue* args); |
71 | 74 |
72 // Called when the user image screen has been loaded and shown. | 75 // Called when the user image screen has been loaded and shown. |
73 void HandleScreenShown(const base::ListValue* args); | 76 void HandleScreenShown(const base::ListValue* args); |
74 | 77 |
75 // Called when the camera presence check has been completed. | 78 // Called when the camera presence check has been completed. |
(...skipping 22 matching lines...) Expand all Loading... |
98 base::WeakPtrFactory<UserImageScreenHandler> weak_factory_; | 101 base::WeakPtrFactory<UserImageScreenHandler> weak_factory_; |
99 | 102 |
100 base::Time screen_show_time_; | 103 base::Time screen_show_time_; |
101 | 104 |
102 DISALLOW_COPY_AND_ASSIGN(UserImageScreenHandler); | 105 DISALLOW_COPY_AND_ASSIGN(UserImageScreenHandler); |
103 }; | 106 }; |
104 | 107 |
105 } // namespace chromeos | 108 } // namespace chromeos |
106 | 109 |
107 #endif // CHROME_BROWSER_UI_WEBUI_CHROMEOS_LOGIN_USER_IMAGE_SCREEN_HANDLER_H_ | 110 #endif // CHROME_BROWSER_UI_WEBUI_CHROMEOS_LOGIN_USER_IMAGE_SCREEN_HANDLER_H_ |
OLD | NEW |