From 215931daacfcd5acfc7ec87e4e5577baec309fae Mon Sep 17 00:00:00 2001 From: Aliaksandr Kalenik Date: Sun, 21 Jan 2024 13:44:08 +0100 Subject: [PATCH] LibWeb/WebGL: Make Context::activate() non-virtual This method is only relevant for AccelGfx so no reason to keep it virtual. --- Userland/Libraries/LibWeb/WebGL/OpenGLContext.cpp | 7 +------ Userland/Libraries/LibWeb/WebGL/OpenGLContext.h | 1 - 2 files changed, 1 insertion(+), 7 deletions(-) diff --git a/Userland/Libraries/LibWeb/WebGL/OpenGLContext.cpp b/Userland/Libraries/LibWeb/WebGL/OpenGLContext.cpp index 1b458f2f8f7..b695d5e03dc 100644 --- a/Userland/Libraries/LibWeb/WebGL/OpenGLContext.cpp +++ b/Userland/Libraries/LibWeb/WebGL/OpenGLContext.cpp @@ -20,7 +20,7 @@ namespace Web::WebGL { #ifdef HAS_ACCELERATED_GRAPHICS class AccelGfxContext : public OpenGLContext { public: - virtual void activate() override + void activate() { m_context->activate(); } @@ -172,11 +172,6 @@ private: #ifdef AK_OS_SERENITY class LibGLContext : public OpenGLContext { public: - virtual void activate() override - { - GL::make_context_current(m_context); - } - virtual void present(Gfx::Bitmap&) override { m_context->present(); diff --git a/Userland/Libraries/LibWeb/WebGL/OpenGLContext.h b/Userland/Libraries/LibWeb/WebGL/OpenGLContext.h index e3196576006..2d08a43d875 100644 --- a/Userland/Libraries/LibWeb/WebGL/OpenGLContext.h +++ b/Userland/Libraries/LibWeb/WebGL/OpenGLContext.h @@ -15,7 +15,6 @@ class OpenGLContext { public: static OwnPtr create(Gfx::Bitmap&); - virtual void activate() = 0; virtual void present(Gfx::Bitmap&) = 0; void clear_buffer_to_default_values();