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

Unified Diff: Source/modules/crypto/AesCbcParams.cpp

Issue 18475002: WebCrypto: Add framework for AlgorithmIdentifier normalization. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 7 years, 6 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/crypto/AesCbcParams.cpp
diff --git a/Source/core/html/ime/Composition.cpp b/Source/modules/crypto/AesCbcParams.cpp
similarity index 81%
copy from Source/core/html/ime/Composition.cpp
copy to Source/modules/crypto/AesCbcParams.cpp
index e74501bcd8637afa85872dae701e91f04827e1ee..76c0841d784e83d1c111bd9f623f0cac2334b594 100644
--- a/Source/core/html/ime/Composition.cpp
+++ b/Source/modules/crypto/AesCbcParams.cpp
@@ -29,25 +29,20 @@
*/
#include "config.h"
-#include "core/html/ime/Composition.h"
+#include "modules/crypto/AesCbcParams.h"
-#include "core/dom/Node.h"
-#include "core/dom/Range.h"
+#include "public/platform/WebCryptoAlgorithmParams.h"
namespace WebCore {
-Composition::~Composition()
+PassRefPtr<Uint8Array> AesCbcParams::iv()
{
+ if (!m_iv)
+ m_iv = Uint8Array::create(m_algorithm.getAesCbcParams()->iv(), m_algorithm.getAesCbcParams()->ivSize());
+ return m_iv;
}
-PassRefPtr<Composition> Composition::create(Node* text, Range* caret)
-{
- return adoptRef(new Composition(text, caret));
-}
-
-Composition::Composition(Node* text, Range* caret)
- : m_text(text)
- , m_caret(caret)
+AesCbcParams::AesCbcParams(const WebKit::WebCryptoAlgorithm& algorithm) : Algorithm(algorithm)
abarth-chromium 2013/07/02 06:46:36 ": Algorithm(algorithm)" should be on it's own lin
eroman 2013/07/02 08:12:27 Done.
{
ScriptWrappable::init(this);
}

Powered by Google App Engine
This is Rietveld 408576698