mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2024-11-21 23:20:20 +00:00
LibWeb: Allow constructing a IDBOpenDBRequest
This commit is contained in:
parent
67fccf4eb2
commit
47d6499f6d
Notes:
github-actions[bot]
2024-11-08 18:12:28 +00:00
Author: https://github.com/stelar7 Commit: https://github.com/LadybirdBrowser/ladybird/commit/47d6499f6d7 Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/2165 Reviewed-by: https://github.com/ADKaster ✅ Reviewed-by: https://github.com/shannonbooth
2 changed files with 8 additions and 0 deletions
|
@ -27,6 +27,11 @@ void IDBOpenDBRequest::initialize(JS::Realm& realm)
|
|||
WEB_SET_PROTOTYPE_FOR_INTERFACE(IDBOpenDBRequest);
|
||||
}
|
||||
|
||||
JS::NonnullGCPtr<IDBOpenDBRequest> IDBOpenDBRequest::create(JS::Realm& realm)
|
||||
{
|
||||
return realm.heap().allocate<IDBOpenDBRequest>(realm, realm);
|
||||
}
|
||||
|
||||
// https://w3c.github.io/IndexedDB/#dom-idbopendbrequest-onblocked
|
||||
void IDBOpenDBRequest::set_onblocked(WebIDL::CallbackType* event_handler)
|
||||
{
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
/*
|
||||
* Copyright (c) 2024, Shannon Booth <shannon@serenityos.org>
|
||||
* Copyright (c) 2024, Jamie Mansfield <jmansfield@cadixdev.org>
|
||||
* Copyright (c) 2024, stelar7 <dudedbz@gmail.com>
|
||||
*
|
||||
* SPDX-License-Identifier: BSD-2-Clause
|
||||
*/
|
||||
|
@ -19,6 +20,8 @@ class IDBOpenDBRequest : public IDBRequest {
|
|||
public:
|
||||
virtual ~IDBOpenDBRequest();
|
||||
|
||||
[[nodiscard]] static JS::NonnullGCPtr<IDBOpenDBRequest> create(JS::Realm&);
|
||||
|
||||
void set_onblocked(WebIDL::CallbackType*);
|
||||
WebIDL::CallbackType* onblocked();
|
||||
void set_onupgradeneeded(WebIDL::CallbackType*);
|
||||
|
|
Loading…
Reference in a new issue