Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1529)

Side by Side Diff: third_party/WebKit/Source/modules/imagecapture/PhotoCapabilities.cpp

Issue 2877273002: Image Capture: reject setOptions()/applyConstraints() if any argument is unsupported (Closed)
Patch Set: reverted renaming bc it breaks patching Created 3 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « third_party/WebKit/Source/modules/imagecapture/PhotoCapabilities.h ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 27 matching lines...) Expand all
38 case media::mojom::blink::RedEyeReduction::ALWAYS: 38 case media::mojom::blink::RedEyeReduction::ALWAYS:
39 return "always"; 39 return "always";
40 case media::mojom::blink::RedEyeReduction::CONTROLLABLE: 40 case media::mojom::blink::RedEyeReduction::CONTROLLABLE:
41 return "controllable"; 41 return "controllable";
42 default: 42 default:
43 NOTREACHED(); 43 NOTREACHED();
44 } 44 }
45 return ""; 45 return "";
46 } 46 }
47 47
48 bool PhotoCapabilities::IsRedEyeReductionControllable() const {
49 return red_eye_reduction_ ==
50 media::mojom::blink::RedEyeReduction::CONTROLLABLE;
51 }
52
48 DEFINE_TRACE(PhotoCapabilities) { 53 DEFINE_TRACE(PhotoCapabilities) {
49 visitor->Trace(image_height_); 54 visitor->Trace(image_height_);
50 visitor->Trace(image_width_); 55 visitor->Trace(image_width_);
51 } 56 }
52 57
53 } // namespace blink 58 } // namespace blink
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/modules/imagecapture/PhotoCapabilities.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698