mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-07-29 12:19:54 +00:00
LibWeb: Implement dialog.requestClose()
This commit is contained in:
parent
b056e27afd
commit
dd37d1c536
Notes:
github-actions[bot]
2025-01-30 23:25:42 +00:00
Author: https://github.com/lukewarlow
Commit: dd37d1c536
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/3280
Reviewed-by: https://github.com/ADKaster ✅
8 changed files with 67 additions and 17 deletions
|
@ -25,10 +25,15 @@ public:
|
|||
static WebIDL::ExceptionOr<GC::Ref<CloseWatcher>> construct_impl(JS::Realm&, CloseWatcherOptions const& = {});
|
||||
[[nodiscard]] static GC::Ref<CloseWatcher> establish(HTML::Window&);
|
||||
|
||||
bool request_close();
|
||||
void request_close_for_bindings();
|
||||
void close();
|
||||
void destroy();
|
||||
|
||||
bool request_close(bool require_history_action_activation);
|
||||
|
||||
bool get_enabled_state() const { return m_is_enabled; }
|
||||
void set_enabled(bool enabled) { m_is_enabled = enabled; }
|
||||
|
||||
virtual ~CloseWatcher() override = default;
|
||||
|
||||
void set_oncancel(WebIDL::CallbackType*);
|
||||
|
@ -44,6 +49,7 @@ private:
|
|||
|
||||
bool m_is_running_cancel_action { false };
|
||||
bool m_is_active { true };
|
||||
bool m_is_enabled { true };
|
||||
};
|
||||
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue