From 6ce70ed4b08c7db20b6b384be26c7fc4e11c98de Mon Sep 17 00:00:00 2001 From: crupest Date: Wed, 28 Oct 2020 20:51:55 +0800 Subject: ... --- src/ui/controls/TextControlService.hpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/ui/controls/TextControlService.hpp') diff --git a/src/ui/controls/TextControlService.hpp b/src/ui/controls/TextControlService.hpp index 8419f35c..8c1bd32f 100644 --- a/src/ui/controls/TextControlService.hpp +++ b/src/ui/controls/TextControlService.hpp @@ -12,7 +12,7 @@ #include "cru/ui/DebugFlags.hpp" #include "cru/ui/ShortcutHub.hpp" #include "cru/ui/UiEvent.hpp" -#include "cru/ui/UiHost.hpp" +#include "cru/ui/WindowHost.hpp" #include "cru/ui/render/CanvasRenderObject.hpp" #include "cru/ui/render/ScrollRenderObject.hpp" #include "cru/ui/render/TextRenderObject.hpp" @@ -208,7 +208,7 @@ class TextControlService : public Object { } void ScrollToCaret() { - this->control_->GetUiHost()->RunAfterLayoutStable([this]() { + this->control_->GetWindowHost()->RunAfterLayoutStable([this]() { const auto caret_rect = this->GetTextRenderObject()->GetCaretRect(); this->GetScrollRenderObject()->ScrollToContain(caret_rect, Thickness{5.f}); @@ -408,7 +408,7 @@ class TextControlService : public Object { void GainFocusHandler(event::FocusChangeEventArgs& args) { CRU_UNUSED(args); if (editable_) { - UiHost* ui_host = this->control_->GetUiHost(); + WindowHost* ui_host = this->control_->GetWindowHost(); auto window = ui_host->GetNativeWindowResolver()->Resolve(); if (window == nullptr) return; input_method_context_ = -- cgit v1.2.3