AeonGUI
A portable video game graphic user interface library.
Loading...
Searching...
No Matches
UIEvent.hpp
1/*
2Copyright (C) 2026 Rodrigo Jose Hernandez Cordoba
3
4Licensed under the Apache License, Version 2.0 (the "License");
5you may not use this file except in compliance with the License.
6You may obtain a copy of the License at
7
8http://www.apache.org/licenses/LICENSE-2.0
9
10Unless required by applicable law or agreed to in writing, software
11distributed under the License is distributed on an "AS IS" BASIS,
12WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13See the License for the specific language governing permissions and
14limitations under the License.
15*/
16#ifndef AEONGUI_DOM_UIEVENT_H
17#define AEONGUI_DOM_UIEVENT_H
18#include "aeongui/dom/Event.hpp"
19
20namespace AeonGUI
21{
22 namespace DOM
23 {
24 class Window;
29 {
30 Window* view{nullptr};
31 long detail{0};
32 };
33
40 class UIEvent : public Event
41 {
42 public:
47 DLL UIEvent ( const DOMString& type, const UIEventInit& eventInitDict = {} );
50 DLL Window* view() const;
53 DLL long detail() const;
54 private:
55 Window* m_view{nullptr};
56 long m_detail{0};
57 };
58 }
59}
60#endif
constexpr const DOMString & type() const
Get the event type.
Definition Event.hpp:73
Event(const DOMString &type, const std::optional< EventInit > &eventInitDict={})
Construct an event of the given type.
Definition Event.cpp:21
Window * view() const
Get the Window associated with this event.
Definition UIEvent.cpp:27
UIEvent(const DOMString &type, const UIEventInit &eventInitDict={})
Construct a UIEvent.
Definition UIEvent.cpp:21
long detail() const
Get the detail value.
Definition UIEvent.cpp:31
Represents a display window in the AeonGUI framework.
Definition Window.hpp:44
Initialization dictionary for Event construction.
Definition Event.hpp:34
Initialization dictionary for UIEvent construction.
Definition UIEvent.hpp:29
Window * view
The Window from which the event was generated.
Definition UIEvent.hpp:30
long detail
Application-specific detail information.
Definition UIEvent.hpp:31