mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-09-03 08:08:43 +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: 47d6499f6d
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);
|
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
|
// https://w3c.github.io/IndexedDB/#dom-idbopendbrequest-onblocked
|
||||||
void IDBOpenDBRequest::set_onblocked(WebIDL::CallbackType* event_handler)
|
void IDBOpenDBRequest::set_onblocked(WebIDL::CallbackType* event_handler)
|
||||||
{
|
{
|
||||||
|
|
|
@ -1,6 +1,7 @@
|
||||||
/*
|
/*
|
||||||
* Copyright (c) 2024, Shannon Booth <shannon@serenityos.org>
|
* Copyright (c) 2024, Shannon Booth <shannon@serenityos.org>
|
||||||
* Copyright (c) 2024, Jamie Mansfield <jmansfield@cadixdev.org>
|
* Copyright (c) 2024, Jamie Mansfield <jmansfield@cadixdev.org>
|
||||||
|
* Copyright (c) 2024, stelar7 <dudedbz@gmail.com>
|
||||||
*
|
*
|
||||||
* SPDX-License-Identifier: BSD-2-Clause
|
* SPDX-License-Identifier: BSD-2-Clause
|
||||||
*/
|
*/
|
||||||
|
@ -19,6 +20,8 @@ class IDBOpenDBRequest : public IDBRequest {
|
||||||
public:
|
public:
|
||||||
virtual ~IDBOpenDBRequest();
|
virtual ~IDBOpenDBRequest();
|
||||||
|
|
||||||
|
[[nodiscard]] static JS::NonnullGCPtr<IDBOpenDBRequest> create(JS::Realm&);
|
||||||
|
|
||||||
void set_onblocked(WebIDL::CallbackType*);
|
void set_onblocked(WebIDL::CallbackType*);
|
||||||
WebIDL::CallbackType* onblocked();
|
WebIDL::CallbackType* onblocked();
|
||||||
void set_onupgradeneeded(WebIDL::CallbackType*);
|
void set_onupgradeneeded(WebIDL::CallbackType*);
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue