bakito said:
I want to write a C++ application with three frames. One of the frames should contain UE2Runtime window. Is it possible to bind the content of an UE2Runtime as a child window in my application?
Window.dll (one of UE2Runtime dll's) contains window-management functions. But because the library is written in C++ it is not posible to call the functions directly because missing the relevant header-files.
Use FindWindow function and yu WILL NOT need to loop through all window handles:
HWND FindWindow(
LPCTSTR lpClassName, // pointer to class name
LPCTSTR lpWindowName // pointer to window name
);
it's the easiest way to get a window handle.
Tracking window size and position can be done via catching WM_SIZE and WM_MOVE messages.
WM_MOVE
xPos = (int) LOWORD(lParam); // horizontal position
yPos = (int) HIWORD(lParam); // vertical position
WM_SIZE
fwSizeType = wParam; // resizing flag
nWidth = LOWORD(lParam); // width of client area
nHeight = HIWORD(lParam); // height of client area
fwSizeType specifies the type of resizing requested. This parameter can be one of the following values:
SIZE_MAXHIDE - Message is sent to all pop-up windows when some other window is maximized.
SIZE_MAXIMIZED - Window has been maximized.
SIZE_MAXSHOW - Message is sent to all pop-up windows when some other window has been restored to its former size.
SIZE_MINIMIZED - Window has been minimized.
SIZE_RESTORED - Window has been resized, but neither the SIZE_MINIMIZED nor SIZE_MAXIMIZED value applies.