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

Unified Diff: Source/modules/credentialmanager/LocalCredential.cpp

Issue 645023005: Credential Manager: Add a 'formData' property to LocalCredential. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git/+/reordering-arguments
Patch Set: Ugh. Created 6 years, 2 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 side-by-side diff with in-line comments
Download patch
Index: Source/modules/credentialmanager/LocalCredential.cpp
diff --git a/Source/modules/credentialmanager/LocalCredential.cpp b/Source/modules/credentialmanager/LocalCredential.cpp
index 3dc28eb6b34f476a65331dfbab081e34a0b9f639..a0079d26166037ea2b5d0cbf4ebe93ba70932973 100644
--- a/Source/modules/credentialmanager/LocalCredential.cpp
+++ b/Source/modules/credentialmanager/LocalCredential.cpp
@@ -6,6 +6,7 @@
#include "modules/credentialmanager/LocalCredential.h"
#include "bindings/core/v8/ExceptionState.h"
+#include "core/html/DOMFormData.h"
#include "platform/credentialmanager/PlatformLocalCredential.h"
#include "public/platform/WebCredential.h"
#include "public/platform/WebLocalCredential.h"
@@ -32,7 +33,10 @@ LocalCredential::LocalCredential(WebLocalCredential* webLocalCredential)
LocalCredential::LocalCredential(const String& id, const String& password, const String& name, const KURL& avatar)
: Credential(PlatformLocalCredential::create(id, password, name, avatar))
+ , m_formData(DOMFormData::create())
{
+ m_formData->append("username", id);
+ m_formData->append("password", password);
}
const String& LocalCredential::password() const
@@ -40,4 +44,10 @@ const String& LocalCredential::password() const
return static_cast<PlatformLocalCredential*>(m_platformCredential.get())->password();
}
+void LocalCredential::trace(Visitor* visitor)
+{
+ visitor->trace(m_formData);
+ Credential::trace(visitor);
+}
+
} // namespace blink
« no previous file with comments | « Source/modules/credentialmanager/LocalCredential.h ('k') | Source/modules/credentialmanager/LocalCredential.idl » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698