Fix editor text caret measurement
This commit is contained in:
@@ -218,6 +218,7 @@ void InspectorPanel::ResetPanelState() {
|
||||
m_visible = false;
|
||||
m_bounds = {};
|
||||
m_sceneRuntime = nullptr;
|
||||
m_textMeasurer = nullptr;
|
||||
m_subject = {};
|
||||
m_subjectKey.clear();
|
||||
m_presentation = {};
|
||||
@@ -733,6 +734,7 @@ void InspectorPanel::Update(
|
||||
m_visible = true;
|
||||
m_bounds = dispatchEntry.bounds;
|
||||
m_sceneRuntime = &context.GetSceneRuntime();
|
||||
m_textMeasurer = context.GetShellServices().textMeasurer;
|
||||
m_subject = BuildInspectorSubject(context.GetSession(), context.GetSceneRuntime());
|
||||
|
||||
const std::string nextSubjectKey = BuildSubjectKey();
|
||||
@@ -894,7 +896,10 @@ void InspectorPanel::Append(UIDrawList& drawList) const {
|
||||
m_interactionState.propertyGridState,
|
||||
m_propertyEditModel,
|
||||
::XCEngine::UI::Editor::GetUIEditorFixedPropertyGridPalette(),
|
||||
::XCEngine::UI::Editor::GetUIEditorFixedPropertyGridMetrics());
|
||||
::XCEngine::UI::Editor::GetUIEditorFixedPropertyGridMetrics(),
|
||||
{},
|
||||
{},
|
||||
m_textMeasurer);
|
||||
}
|
||||
|
||||
if (ShouldShowAddComponentButton()) {
|
||||
|
||||
Reference in New Issue
Block a user