OLD | NEW |
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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_POLICY_REMOTE_COMMANDS_DEVICE_COMMAND_SCREENSHOT
_JOB_H_ | 5 #ifndef CHROME_BROWSER_CHROMEOS_POLICY_REMOTE_COMMANDS_DEVICE_COMMAND_SCREENSHOT
_JOB_H_ |
6 #define CHROME_BROWSER_CHROMEOS_POLICY_REMOTE_COMMANDS_DEVICE_COMMAND_SCREENSHOT
_JOB_H_ | 6 #define CHROME_BROWSER_CHROMEOS_POLICY_REMOTE_COMMANDS_DEVICE_COMMAND_SCREENSHOT
_JOB_H_ |
7 | 7 |
8 #include <list> | 8 #include <list> |
9 #include <map> | 9 #include <map> |
10 #include <string> | 10 #include <string> |
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
46 // Failed to acquire screenshots, e.g. no attached screens. | 46 // Failed to acquire screenshots, e.g. no attached screens. |
47 FAILURE_SCREENSHOT_ACQUISITION = 2, | 47 FAILURE_SCREENSHOT_ACQUISITION = 2, |
48 | 48 |
49 // Failed to authenticate to the remote server. | 49 // Failed to authenticate to the remote server. |
50 FAILURE_AUTHENTICATION = 3, | 50 FAILURE_AUTHENTICATION = 3, |
51 | 51 |
52 // Failed due to an internal server error. | 52 // Failed due to an internal server error. |
53 FAILURE_SERVER = 4, | 53 FAILURE_SERVER = 4, |
54 | 54 |
55 // Failed due to a client-side error. | 55 // Failed due to a client-side error. |
56 FAILURE_CLIENT = 5 | 56 FAILURE_CLIENT = 5, |
| 57 |
| 58 // Failed due to an invalid upload url. |
| 59 FAILURE_INVALID_URL = 6 |
57 }; | 60 }; |
58 | 61 |
59 // A delegate interface used by DeviceCommandScreenshotJob to retrieve its | 62 // A delegate interface used by DeviceCommandScreenshotJob to retrieve its |
60 // dependencies. | 63 // dependencies. |
61 class Delegate { | 64 class Delegate { |
62 public: | 65 public: |
63 virtual ~Delegate() {} | 66 virtual ~Delegate() {} |
64 | 67 |
65 // Acquires a snapshot of |source_rect| in |window| and invokes |callback| | 68 // Acquires a snapshot of |source_rect| in |window| and invokes |callback| |
66 // with the PNG data. The passed-in callback will not be invoked after the | 69 // with the PNG data. The passed-in callback will not be invoked after the |
(...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
124 scoped_ptr<UploadJob> upload_job_; | 127 scoped_ptr<UploadJob> upload_job_; |
125 | 128 |
126 base::WeakPtrFactory<DeviceCommandScreenshotJob> weak_ptr_factory_; | 129 base::WeakPtrFactory<DeviceCommandScreenshotJob> weak_ptr_factory_; |
127 | 130 |
128 DISALLOW_COPY_AND_ASSIGN(DeviceCommandScreenshotJob); | 131 DISALLOW_COPY_AND_ASSIGN(DeviceCommandScreenshotJob); |
129 }; | 132 }; |
130 | 133 |
131 } // namespace policy | 134 } // namespace policy |
132 | 135 |
133 #endif // CHROME_BROWSER_CHROMEOS_POLICY_REMOTE_COMMANDS_DEVICE_COMMAND_SCREENS
HOT_JOB_H_ | 136 #endif // CHROME_BROWSER_CHROMEOS_POLICY_REMOTE_COMMANDS_DEVICE_COMMAND_SCREENS
HOT_JOB_H_ |
OLD | NEW |