How to wrap a win32 WndProc into a C++ class?
问题 Is this even possible? For example, let's say I have the following: class Window { private: WNDCLASSEX wc; public: inline WNDCLASSEX getWindowClass() { return wc; } Window(); LRESULT CALLBACK WndProc(HWND hwnd, UINT message, LPARAM lParam, WPARAM wParam); } void RegisterWindow(Window win) { WNDCLASSEX* wc = win.getWindowClass(); RegisterClassEx(wc); } Now, somewhere there is going to be a section (probably in the constructor of the Window class, where it's necessary to assign the WNDCLASSEX a