I am quite desperate to resolve this very annoying issue :( . I am trying to display a child window on parent window.
The instantiation is fine and the window shows what it should.
At some point the window need to be resized. But for some reason, when I using MoveWindow function it leaves blank space on the top of the parent window. Here is the screenshot:<ahref>http://i32.fastpic.ru/big/2011/1016/39/9e4460be87c03499e8b183a130902d39.png[
^]
Here is the code example:
HWND hwnd HWND hwndParent = ::GetParent(hwnd);
RECT parentRect = {0,0,0,0};
RECT childRect = {0,0,0,0};
::GetClientRect(hwndParent, &parentRect);
BOOL ok = ::MoveWindow(hwnd, 0, 0, 600, 300, true);
::GetClientRect(hwnd, &childRect);
Since the rect is smaller than asked not entire window rect will be used.
WHY ?????
What am I doing wrong? Did I forgot some flags with window initialization?!