关键节点
This commit is contained in:
46
editor/app/Platform/Win32/Chrome/BorderlessWindowFrame.h
Normal file
46
editor/app/Platform/Win32/Chrome/BorderlessWindowFrame.h
Normal file
@@ -0,0 +1,46 @@
|
||||
#pragma once
|
||||
|
||||
#ifndef NOMINMAX
|
||||
#define NOMINMAX
|
||||
#endif
|
||||
|
||||
#include <XCEngine/UI/Types.h>
|
||||
|
||||
#include <windows.h>
|
||||
|
||||
namespace XCEngine::UI::Editor::Host {
|
||||
|
||||
enum class BorderlessWindowResizeEdge : std::uint8_t {
|
||||
None = 0,
|
||||
Left,
|
||||
Top,
|
||||
Right,
|
||||
Bottom,
|
||||
TopLeft,
|
||||
TopRight,
|
||||
BottomLeft,
|
||||
BottomRight
|
||||
};
|
||||
|
||||
struct BorderlessWindowFrameMetrics {
|
||||
float resizeBorderThickness = 6.0f;
|
||||
int minimumOuterWidth = 640;
|
||||
int minimumOuterHeight = 360;
|
||||
};
|
||||
|
||||
BorderlessWindowResizeEdge HitTestBorderlessWindowResizeEdge(
|
||||
const ::XCEngine::UI::UIRect& clientRect,
|
||||
const ::XCEngine::UI::UIPoint& point,
|
||||
const BorderlessWindowFrameMetrics& metrics = {});
|
||||
|
||||
LPCWSTR ResolveBorderlessWindowResizeCursor(BorderlessWindowResizeEdge edge);
|
||||
|
||||
RECT ComputeBorderlessWindowResizeRect(
|
||||
const RECT& initialRect,
|
||||
const POINT& initialScreenPoint,
|
||||
const POINT& currentScreenPoint,
|
||||
BorderlessWindowResizeEdge edge,
|
||||
int minimumOuterWidth,
|
||||
int minimumOuterHeight);
|
||||
|
||||
} // namespace XCEngine::UI::Editor::Host
|
||||
Reference in New Issue
Block a user