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

Side by Side Diff: Source/modules/mediastream/MediaConstraintsImpl.cpp

Issue 18548003: Rename ExceptionCode constants to use the names in the spec (2/3) (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 7 years, 5 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 | Annotate | Revision Log
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2012 Google Inc. All rights reserved. 2 * Copyright (C) 2012 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 7 *
8 * 1. Redistributions of source code must retain the above copyright 8 * 1. Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * 2. Redistributions in binary form must reproduce the above copyright 10 * 2. Redistributions in binary form must reproduce the above copyright
(...skipping 25 matching lines...) Expand all
36 #include "bindings/v8/Dictionary.h" 36 #include "bindings/v8/Dictionary.h"
37 #include "core/dom/ExceptionCode.h" 37 #include "core/dom/ExceptionCode.h"
38 #include "wtf/HashMap.h" 38 #include "wtf/HashMap.h"
39 39
40 namespace WebCore { 40 namespace WebCore {
41 41
42 PassRefPtr<MediaConstraintsImpl> MediaConstraintsImpl::create(const Dictionary& constraints, ExceptionCode& ec) 42 PassRefPtr<MediaConstraintsImpl> MediaConstraintsImpl::create(const Dictionary& constraints, ExceptionCode& ec)
43 { 43 {
44 RefPtr<MediaConstraintsImpl> object = adoptRef(new MediaConstraintsImpl()); 44 RefPtr<MediaConstraintsImpl> object = adoptRef(new MediaConstraintsImpl());
45 if (!object->initialize(constraints)) { 45 if (!object->initialize(constraints)) {
46 ec = TYPE_MISMATCH_ERR; 46 ec = TypeMismatchError;
47 return 0; 47 return 0;
48 } 48 }
49 return object.release(); 49 return object.release();
50 } 50 }
51 51
52 PassRefPtr<MediaConstraintsImpl> MediaConstraintsImpl::create() 52 PassRefPtr<MediaConstraintsImpl> MediaConstraintsImpl::create()
53 { 53 {
54 return adoptRef(new MediaConstraintsImpl()); 54 return adoptRef(new MediaConstraintsImpl());
55 } 55 }
56 56
(...skipping 91 matching lines...) Expand 10 before | Expand all | Expand 10 after
148 if (i->m_name == name) { 148 if (i->m_name == name) {
149 value = i->m_value; 149 value = i->m_value;
150 return true; 150 return true;
151 } 151 }
152 } 152 }
153 153
154 return false; 154 return false;
155 } 155 }
156 156
157 } // namespace WebCore 157 } // namespace WebCore
OLDNEW
« no previous file with comments | « Source/modules/mediasource/WebKitSourceBuffer.cpp ('k') | Source/modules/mediastream/MediaStream.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698