mirror of
https://github.com/fergalmoran/ladybird.git
synced 2026-02-24 00:24:38 +00:00
LibWeb/WebGL: Add stub class for WebGLQuery
This is a WebGL 2.0 class
This commit is contained in:
committed by
Alexander Kalenik
parent
d8ccd6b87c
commit
69e4adbd98
34
Libraries/LibWeb/WebGL/WebGLQuery.cpp
Normal file
34
Libraries/LibWeb/WebGL/WebGLQuery.cpp
Normal file
@@ -0,0 +1,34 @@
|
||||
/*
|
||||
* Copyright (c) 2024, Andrew Kaster <andrew@ladybird.org>
|
||||
*
|
||||
* SPDX-License-Identifier: BSD-2-Clause
|
||||
*/
|
||||
|
||||
#include <LibJS/Runtime/Realm.h>
|
||||
#include <LibWeb/Bindings/Intrinsics.h>
|
||||
#include <LibWeb/Bindings/WebGLQueryPrototype.h>
|
||||
#include <LibWeb/WebGL/WebGLQuery.h>
|
||||
|
||||
namespace Web::WebGL {
|
||||
|
||||
GC_DEFINE_ALLOCATOR(WebGLQuery);
|
||||
|
||||
GC::Ref<WebGLQuery> WebGLQuery::create(JS::Realm& realm, GLuint handle)
|
||||
{
|
||||
return realm.create<WebGLQuery>(realm, handle);
|
||||
}
|
||||
|
||||
WebGLQuery::WebGLQuery(JS::Realm& realm, GLuint handle)
|
||||
: WebGLObject(realm, handle)
|
||||
{
|
||||
}
|
||||
|
||||
WebGLQuery::~WebGLQuery() = default;
|
||||
|
||||
void WebGLQuery::initialize(JS::Realm& realm)
|
||||
{
|
||||
Base::initialize(realm);
|
||||
WEB_SET_PROTOTYPE_FOR_INTERFACE(WebGLQuery);
|
||||
}
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user