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

Side by Side Diff: Source/modules/credentialmanager/Credential.cpp

Issue 540283003: bindings: Retires ScriptWrappable::init, etc. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Addressed a review comment. Created 6 years, 3 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 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 "config.h" 5 #include "config.h"
6 #include "modules/credentialmanager/Credential.h" 6 #include "modules/credentialmanager/Credential.h"
7 7
8 #include "bindings/core/v8/ExceptionState.h" 8 #include "bindings/core/v8/ExceptionState.h"
9 #include "core/dom/ExceptionCode.h" 9 #include "core/dom/ExceptionCode.h"
10 10
(...skipping 13 matching lines...) Expand all
24 } 24 }
25 25
26 Credential::Credential(PlatformCredential* credential) 26 Credential::Credential(PlatformCredential* credential)
27 : m_platformCredential(credential) 27 : m_platformCredential(credential)
28 { 28 {
29 } 29 }
30 30
31 Credential::Credential(const String& id, const String& name, const KURL& avatar) 31 Credential::Credential(const String& id, const String& name, const KURL& avatar)
32 : m_platformCredential(PlatformCredential::create(id, name, avatar)) 32 : m_platformCredential(PlatformCredential::create(id, name, avatar))
33 { 33 {
34 ScriptWrappable::init(this);
35 } 34 }
36 35
37 KURL Credential::parseStringAsURL(const String& url, ExceptionState& exceptionSt ate) 36 KURL Credential::parseStringAsURL(const String& url, ExceptionState& exceptionSt ate)
38 { 37 {
39 KURL parsedURL = KURL(KURL(), url); 38 KURL parsedURL = KURL(KURL(), url);
40 if (!parsedURL.isValid()) 39 if (!parsedURL.isValid())
41 exceptionState.throwDOMException(SyntaxError, "'" + url + "' is not a va lid URL."); 40 exceptionState.throwDOMException(SyntaxError, "'" + url + "' is not a va lid URL.");
42 return parsedURL; 41 return parsedURL;
43 } 42 }
44 43
45 void Credential::trace(Visitor* visitor) 44 void Credential::trace(Visitor* visitor)
46 { 45 {
47 visitor->trace(m_platformCredential); 46 visitor->trace(m_platformCredential);
48 } 47 }
49 48
50 } // namespace blink 49 } // namespace blink
OLDNEW
« no previous file with comments | « Source/modules/battery/BatteryManager.cpp ('k') | Source/modules/credentialmanager/CredentialsContainer.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698