editor: remove shared panel services bag
This commit is contained in:
@@ -17,22 +17,6 @@ using ::XCEngine::UI::Editor::BuildEditorShellShortcutManager;
|
||||
using ::XCEngine::UI::Editor::UIEditorWorkspacePanelPresentationModel;
|
||||
using ::XCEngine::UI::Editor::AppendUIEditorRuntimeTrace;
|
||||
|
||||
void RequestEditorContextUtilityWindow(
|
||||
void* requester,
|
||||
EditorUtilityWindowKind kind) {
|
||||
auto* context = static_cast<EditorContext*>(requester);
|
||||
if (context != nullptr) {
|
||||
context->RequestOpenUtilityWindow(kind);
|
||||
}
|
||||
}
|
||||
|
||||
bool RequestEditorContextOpenSceneAsset(
|
||||
void* requester,
|
||||
const std::filesystem::path& scenePath) {
|
||||
auto* context = static_cast<EditorContext*>(requester);
|
||||
return context != nullptr && context->RequestOpenSceneAsset(scenePath);
|
||||
}
|
||||
|
||||
std::string ComposeStatusText(
|
||||
std::string_view status,
|
||||
std::string_view message) {
|
||||
@@ -260,20 +244,8 @@ const UIEditorShellInteractionServices& EditorContext::GetShellServices() const
|
||||
return m_shellServices;
|
||||
}
|
||||
|
||||
EditorPanelServices EditorContext::BuildPanelServices() {
|
||||
return EditorPanelServices{
|
||||
.session = m_session,
|
||||
.projectRuntime = m_projectRuntime,
|
||||
.sceneRuntime = m_sceneRuntime,
|
||||
.commandFocusService = m_commandFocusService,
|
||||
.colorPickerToolState = m_colorPickerToolState,
|
||||
.systemInteractionHost = m_systemInteractionHost,
|
||||
.textMeasurer = m_shellServices.textMeasurer,
|
||||
.utilityWindowRequester = this,
|
||||
.requestUtilityWindow = RequestEditorContextUtilityWindow,
|
||||
.sceneAssetOpenRequester = this,
|
||||
.requestOpenSceneAsset = RequestEditorContextOpenSceneAsset,
|
||||
};
|
||||
const UIEditorTextMeasurer* EditorContext::GetTextMeasurer() const {
|
||||
return m_shellServices.textMeasurer;
|
||||
}
|
||||
|
||||
bool EditorContext::RequestOpenSceneAsset(const std::filesystem::path& scenePath) {
|
||||
|
||||
Reference in New Issue
Block a user