new_editor: reduce app shell capture plumbing
This commit is contained in:
@@ -3,6 +3,7 @@
|
||||
#include "Ports/ViewportRenderPort.h"
|
||||
#include "Composition/EditorContext.h"
|
||||
#include "Composition/EditorPanelIds.h"
|
||||
#include <XCEditor/Shell/UIEditorShellCapturePolicy.h>
|
||||
#include <XCEngine/Rendering/RenderContext.h>
|
||||
|
||||
namespace XCEngine::UI::Editor::App {
|
||||
@@ -127,31 +128,17 @@ UIEditorDockHostTabDropTarget EditorShellRuntime::ResolveDockTabDropTarget(
|
||||
point);
|
||||
}
|
||||
|
||||
EditorShellPointerOwner EditorShellRuntime::GetPointerOwner() const {
|
||||
return m_hostedPanelCoordinator.ResolvePointerOwner(
|
||||
m_shellInteractionState,
|
||||
m_hierarchyPanel,
|
||||
m_projectPanel);
|
||||
}
|
||||
|
||||
bool EditorShellRuntime::WantsHostPointerCapture() const {
|
||||
return IsHostedContentPointerOwner(GetPointerOwner());
|
||||
}
|
||||
|
||||
bool EditorShellRuntime::WantsHostPointerRelease() const {
|
||||
return !IsHostedContentPointerOwner(GetPointerOwner());
|
||||
}
|
||||
|
||||
bool EditorShellRuntime::HasHostedContentCapture() const {
|
||||
return IsHostedContentPointerOwner(GetPointerOwner());
|
||||
return m_hierarchyPanel.HasActivePointerCapture() ||
|
||||
m_projectPanel.HasActivePointerCapture();
|
||||
}
|
||||
|
||||
bool EditorShellRuntime::HasShellInteractiveCapture() const {
|
||||
return IsShellPointerOwner(GetPointerOwner());
|
||||
return HasActiveUIEditorShellInteractiveCapture(m_shellInteractionState);
|
||||
}
|
||||
|
||||
bool EditorShellRuntime::HasInteractiveCapture() const {
|
||||
return GetPointerOwner() != EditorShellPointerOwner::None;
|
||||
return HasHostedContentCapture() || HasShellInteractiveCapture();
|
||||
}
|
||||
|
||||
} // namespace XCEngine::UI::Editor::App
|
||||
|
||||
Reference in New Issue
Block a user