diff options
Diffstat (limited to 'src/window/window.h')
-rw-r--r-- | src/window/window.h | 22 |
1 files changed, 20 insertions, 2 deletions
diff --git a/src/window/window.h b/src/window/window.h index 216c866..a6baae1 100644 --- a/src/window/window.h +++ b/src/window/window.h @@ -1,7 +1,8 @@ #pragma once #include <forstio/async/async.h> -#include <forstio/common.h> +#include <forstio/core/common.h> +#include <forstio/codec/schema.h> #include <string_view> #include <variant> @@ -9,7 +10,23 @@ #include "video_mode.h" namespace saw { +namespace schema { +using WindowResize = Struct< + NamedMember<UInt32, "width">, + NamedMember<UInt32, "height"> +>; +using WindowEvents = Union< + NamedMember<WindowResize, "resize"> +>; +} +} +#ifdef SAW_UNIX_XCB +#include "xcb.h" +#endif + +/** +namespace saw { class window { public: class event { @@ -47,7 +64,7 @@ public: virtual void show() = 0; virtual void hide() = 0; - virtual const video_mode &videoMode() const = 0; + virtual const video_mode &get_video_mode() const = 0; virtual const std::string_view title() const = 0; virtual void resize(size_t width, size_t height) = 0; @@ -55,3 +72,4 @@ public: virtual conveyor<variant_event> on_event() = 0; }; } // namespace saw +*/ |