summaryrefslogtreecommitdiff
path: root/Source/WebCore/html/canvas/WebGLShader.h
diff options
context:
space:
mode:
Diffstat (limited to 'Source/WebCore/html/canvas/WebGLShader.h')
-rw-r--r--Source/WebCore/html/canvas/WebGLShader.h24
1 files changed, 8 insertions, 16 deletions
diff --git a/Source/WebCore/html/canvas/WebGLShader.h b/Source/WebCore/html/canvas/WebGLShader.h
index 7ed00e321..952cdcc65 100644
--- a/Source/WebCore/html/canvas/WebGLShader.h
+++ b/Source/WebCore/html/canvas/WebGLShader.h
@@ -1,5 +1,5 @@
/*
- * Copyright (C) 2009, 2013 Apple Inc. All rights reserved.
+ * Copyright (C) 2009-2017 Apple Inc. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
@@ -10,10 +10,10 @@
* notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution.
*
- * THIS SOFTWARE IS PROVIDED BY APPLE COMPUTER, INC. ``AS IS'' AND ANY
+ * THIS SOFTWARE IS PROVIDED BY APPLE INC. ``AS IS'' AND ANY
* EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
- * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE COMPUTER, INC. OR
+ * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR
* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
* EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
* PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
@@ -23,21 +23,17 @@
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
-#ifndef WebGLShader_h
-#define WebGLShader_h
+#pragma once
#include "WebGLSharedObject.h"
-#include <wtf/PassRefPtr.h>
-
namespace WebCore {
-class WebGLShader : public WebGLSharedObject {
+class WebGLShader final : public WebGLSharedObject {
public:
+ static Ref<WebGLShader> create(WebGLRenderingContextBase&, GC3Denum);
virtual ~WebGLShader();
- static PassRefPtr<WebGLShader> create(WebGLRenderingContext*, GC3Denum);
-
GC3Denum getType() const { return m_type; }
const String& getSource() const { return m_source; }
@@ -47,11 +43,9 @@ public:
void setValid(bool valid) { m_isValid = valid; }
private:
- WebGLShader(WebGLRenderingContext*, GC3Denum);
+ WebGLShader(WebGLRenderingContextBase&, GC3Denum);
- virtual void deleteObjectImpl(GraphicsContext3D*, Platform3DObject) override;
-
- virtual bool isShader() const override { return true; }
+ void deleteObjectImpl(GraphicsContext3D*, Platform3DObject) final;
GC3Denum m_type;
String m_source;
@@ -59,5 +53,3 @@ private:
};
} // namespace WebCore
-
-#endif // WebGLShader_h