From bed29872d2a7befff9d4cb7313cb40060326a95e Mon Sep 17 00:00:00 2001 From: crupest Date: Mon, 9 Nov 2020 20:45:27 +0800 Subject: ... --- src/ui/controls/RootControl.cpp | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) (limited to 'src/ui/controls/RootControl.cpp') diff --git a/src/ui/controls/RootControl.cpp b/src/ui/controls/RootControl.cpp index c6d9a577..1ebcb6e7 100644 --- a/src/ui/controls/RootControl.cpp +++ b/src/ui/controls/RootControl.cpp @@ -27,10 +27,7 @@ render::RenderObject* RootControl::GetRenderObject() const { void RootControl::EnsureWindowCreated() { this->GetNativeWindow(true); } void RootControl::SetRect(const Rect& rect) { - auto native_window = GetNativeWindow(false); - if (!native_window) return; - - native_window->SetWindowRect(rect); + window_host_->SetWindowRect(rect); } void RootControl::Show(bool create) { -- cgit v1.2.3