aboutsummaryrefslogtreecommitdiff
path: root/include/cru/platform/win/win_native_window.hpp
diff options
context:
space:
mode:
Diffstat (limited to 'include/cru/platform/win/win_native_window.hpp')
-rw-r--r--include/cru/platform/win/win_native_window.hpp7
1 files changed, 7 insertions, 0 deletions
diff --git a/include/cru/platform/win/win_native_window.hpp b/include/cru/platform/win/win_native_window.hpp
index 9deac767..8b787485 100644
--- a/include/cru/platform/win/win_native_window.hpp
+++ b/include/cru/platform/win/win_native_window.hpp
@@ -10,6 +10,7 @@ namespace cru::platform::win {
class WinApplication;
class WindowClass;
class WindowManager;
+class WindowRenderTarget;
class WinNativeWindow : public Object, public virtual NativeWindow {
public:
@@ -70,6 +71,10 @@ class WinNativeWindow : public Object, public virtual NativeWindow {
bool HandleNativeWindowMessage(HWND hwnd, UINT msg, WPARAM w_param,
LPARAM l_param, LRESULT* result);
+ WindowRenderTarget* GetWindowRenderTarget() const {
+ return window_render_target_.get();
+ }
+
private:
// Get the client rect in pixel.
RECT GetClientRectPixel();
@@ -107,6 +112,8 @@ class WinNativeWindow : public Object, public virtual NativeWindow {
bool has_focus_ = false;
bool is_mouse_in_ = false;
+ std::shared_ptr<WindowRenderTarget> window_render_target_;
+
Event<> destroy_event_;
Event<ui::Size> resize_event_;
Event<> paint_event_;