殺虫侍
読み取り中…
検索中…
一致する文字列を見つけられません
window.h
[詳解]
1
7#include <windows.h>
8
12class Window
13{
14public:
16 Window();
17
19 virtual ~Window();
20
26 bool Initialize(HINSTANCE hInst);
27
32 bool Terminate();
33
38 bool MessageLoop();
39
48 static LRESULT CALLBACK MainWndProc(HWND hWnd, UINT msg, WPARAM wParam, LPARAM lParam);
49
55 void OnResize(UINT width, UINT height);
56
61 HWND GetWindowHandle() { return m_hWindow; }
62
63private:
64 WNDCLASS m_wc;
65 HWND m_hWindow = nullptr;
66 SIZE m_sizeWindow;
67 MSG m_msg = {};
68};
static LRESULT CALLBACK MainWndProc(HWND hWnd, UINT msg, WPARAM wParam, LPARAM lParam)
ウィンドウプロシージャ(Win32 コールバック)
Definition window.cpp:81
virtual ~Window()
デストラクタ
Definition window.cpp:11
HWND GetWindowHandle()
ウィンドウハンドルを取得する
Definition window.h:61
bool Terminate()
ウィンドウを破棄してリソースを解放する
Definition window.cpp:58
Window()
コンストラクタ
Definition window.cpp:4
void OnResize(UINT width, UINT height)
ウィンドウサイズ変更時の処理
bool MessageLoop()
ウィンドウメッセージを処理する
Definition window.cpp:68
bool Initialize(HINSTANCE hInst)
ウィンドウクラスを登録してウィンドウを生成する
Definition window.cpp:16