Index: Source/platform/graphics/ColorSpaceTransform.h |
diff --git a/Source/modules/crypto/AesKeyAlgorithm.h b/Source/platform/graphics/ColorSpaceTransform.h |
similarity index 62% |
copy from Source/modules/crypto/AesKeyAlgorithm.h |
copy to Source/platform/graphics/ColorSpaceTransform.h |
index be51a8d22e3d9a969aebf1b23ce5effcdec2d750..3ea15871a5f84887897422a08234897fba9e8691 100644 |
--- a/Source/modules/crypto/AesKeyAlgorithm.h |
+++ b/Source/platform/graphics/ColorSpaceTransform.h |
@@ -28,31 +28,64 @@ |
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
*/ |
-#ifndef AesKeyAlgorithm_h |
-#define AesKeyAlgorithm_h |
+#ifndef ColorSpaceTransform_h |
+#define ColorSpaceTransform_h |
-#include "bindings/v8/ScriptWrappable.h" |
-#include "modules/crypto/KeyAlgorithm.h" |
-#include "platform/heap/Handle.h" |
-#include "wtf/Forward.h" |
+#include "wtf/PassRefPtr.h" |
#include "wtf/RefCounted.h" |
+#if USE(QCMSLIB) |
+#include "qcms.h" |
+#include "wtf/ThreadSafeRefCounted.h" |
+#endif |
+ |
namespace WebCore { |
-class AesKeyAlgorithm : public KeyAlgorithm { |
+#if USE(QCMSLIB) |
+ |
+class ColorSpaceTransform : public ThreadSafeRefCounted<ColorSpaceTransform> { |
public: |
- static AesKeyAlgorithm* create(const blink::WebCryptoKeyAlgorithm&); |
+ static PassRefPtr<ColorSpaceTransform> create(qcms_transform* transform) |
+ { |
+ return adoptRef(new ColorSpaceTransform(transform)); |
+ } |
+ |
+ qcms_transform* transform() { return m_transform; } |
- unsigned short length(); |
+ ~ColorSpaceTransform() |
+ { |
+ if (m_transform) |
+ qcms_transform_release(m_transform); |
- virtual void trace(Visitor*) OVERRIDE; |
+ m_transform = 0; |
+ } |
private: |
- explicit AesKeyAlgorithm(const blink::WebCryptoKeyAlgorithm&); |
+ explicit ColorSpaceTransform(qcms_transform* transform) |
+ : m_transform(transform) |
+ { |
+ } |
+ |
+ qcms_transform* m_transform; |
}; |
-DEFINE_KEY_ALGORITHM_TYPE_CASTS(AesKeyAlgorithm); |
+#else |
-} // namespace WebCore |
+class ColorSpaceTransform : public RefCounted<ColorSpaceTransform> { |
+public: |
+ static PassRefPtr<ColorSpaceTransform> create(void*) |
+ { |
+ return nullptr; |
+ } |
+ |
+private: |
+ ColorSpaceTransform() |
+ { |
+ } |
+}; |
#endif |
+ |
+} // namespace WebCore |
+ |
+#endif // ColorSpaceTransform_h |