OLD | NEW |
1 // Copyright 2016 The Chromium Authors. All rights reserved. | 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 | 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 #include "modules/imagecapture/PhotoCapabilities.h" | 5 #include "modules/imagecapture/PhotoCapabilities.h" |
6 | 6 |
7 namespace blink { | 7 namespace blink { |
8 | 8 |
9 // static | 9 // static |
10 PhotoCapabilities* PhotoCapabilities::create() { | 10 PhotoCapabilities* PhotoCapabilities::create() { |
(...skipping 14 matching lines...) Expand all Loading... |
25 fillLightModes.push_back("flash"); | 25 fillLightModes.push_back("flash"); |
26 break; | 26 break; |
27 default: | 27 default: |
28 NOTREACHED(); | 28 NOTREACHED(); |
29 } | 29 } |
30 } | 30 } |
31 return fillLightModes; | 31 return fillLightModes; |
32 } | 32 } |
33 | 33 |
34 String PhotoCapabilities::redEyeReduction() const { | 34 String PhotoCapabilities::redEyeReduction() const { |
35 return m_redEyeReduction ? "controllable" : "never"; | 35 switch (m_redEyeReduction) { |
| 36 case media::mojom::blink::RedEyeReduction::NEVER: |
| 37 return "never"; |
| 38 case media::mojom::blink::RedEyeReduction::ALWAYS: |
| 39 return "always"; |
| 40 case media::mojom::blink::RedEyeReduction::CONTROLLABLE: |
| 41 return "controllable"; |
| 42 default: |
| 43 NOTREACHED(); |
| 44 } |
| 45 return ""; |
36 } | 46 } |
37 | 47 |
38 DEFINE_TRACE(PhotoCapabilities) { | 48 DEFINE_TRACE(PhotoCapabilities) { |
39 visitor->trace(m_imageHeight); | 49 visitor->trace(m_imageHeight); |
40 visitor->trace(m_imageWidth); | 50 visitor->trace(m_imageWidth); |
41 } | 51 } |
42 | 52 |
43 } // namespace blink | 53 } // namespace blink |
OLD | NEW |