summaryrefslogtreecommitdiff
path: root/Editor/GUI/WindowUtil.cpp
diff options
context:
space:
mode:
authorchai <chaifix@163.com>2021-10-17 11:14:00 +0800
committerchai <chaifix@163.com>2021-10-17 11:14:00 +0800
commitd35db57d457132dd9d83fa2bd51491b148530655 (patch)
treeb5a29675f091f268577b5991988c723f273b0bd1 /Editor/GUI/WindowUtil.cpp
parent7b0a6d1fe0117cf42a5776aaabda2db78599e5b8 (diff)
*GUI
Diffstat (limited to 'Editor/GUI/WindowUtil.cpp')
-rw-r--r--Editor/GUI/WindowUtil.cpp19
1 files changed, 19 insertions, 0 deletions
diff --git a/Editor/GUI/WindowUtil.cpp b/Editor/GUI/WindowUtil.cpp
new file mode 100644
index 0000000..fc32719
--- /dev/null
+++ b/Editor/GUI/WindowUtil.cpp
@@ -0,0 +1,19 @@
+#include "EditorWindows.h"
+#include "WinUtils.h"
+
+const wchar_t* WindowUtil::kContainerWindowClassName = L"GameLabContainerWndClass";
+const wchar_t* WindowUtil::kPopupWindowClassName = L"GameLabPopupWndClass";
+const wchar_t* WindowUtil::kGUIWindowClassName = L"GUIViewWindowClassName";
+
+static ATOM ContainerWindowClassAtom;
+static ATOM PopupWindowClassAtom;
+static ATOM GUIViewClassAtom;
+
+void WindowUtil::Init()
+{
+ log_info("WindowUtil::Init()");
+
+ ContainerWindowClassAtom = winutils::RegisterWindowClass(kContainerWindowClassName, ContainnerWindow::ContainerWndProc, CS_HREDRAW | CS_VREDRAW);
+ PopupWindowClassAtom = winutils::RegisterWindowClass(kPopupWindowClassName, ContainnerWindow::ContainerWndProc, CS_HREDRAW | CS_VREDRAW | CS_DROPSHADOW);//CS_HREDRAW宽度(水平)变化时重绘、CS_VREDRAW高度(垂直)变化时重绘
+ GUIViewClassAtom = winutils::RegisterWindowClass(kGUIWindowClassName, GUIWindow::GUIViewWndProc, CS_HREDRAW | CS_VREDRAW | CS_DROPSHADOW);
+} \ No newline at end of file