CtrlCore: DHCtrl fixed

git-svn-id: svn://ultimatepp.org/upp/trunk@12019 f0d560ea-af0d-0410-9eb7-867de7ffcac7
This commit is contained in:
cxl 2018-06-26 09:54:11 +00:00
parent 0119bc5167
commit b50ea5b44a
2 changed files with 4 additions and 4 deletions

View file

@ -64,12 +64,11 @@ void DHCtrl::OpenHWND()
GuiLock __;
CloseHWND();
HWND phwnd = GetTopCtrl()->GetHWND();
if(phwnd) {
if(phwnd)
CreateWindowEx(0, "UPP-CLASS-A", "",
WS_CHILD|WS_DISABLED|WS_VISIBLE,
0, 0, 20, 20,
phwnd, NULL, hInstance, this);
}
}
void DHCtrl::SyncHWND()
@ -102,6 +101,7 @@ DHCtrl::DHCtrl()
{
hwnd = NULL;
isdhctrl = true;
BackPaint(EXCLUDEPAINT);
}
DHCtrl::~DHCtrl()

View file

@ -8,7 +8,7 @@ namespace Upp {
#define LOGTIMING 0
#ifdef _DEBUG
// #define LOGMESSAGES 1
#define LOGMESSAGES 1
#endif
#define ELOGW(x) // RLOG(GetSysTime() << ": " << x) // Only activate in MT!
@ -675,7 +675,7 @@ LRESULT CALLBACK Ctrl::WndProc(HWND hWnd, UINT message, WPARAM wParam, LPARAM lP
}
#endif
LRESULT l = 0;
if(w && w->GetHWND()) {
if(w && (w->GetHWND() || w->isdhctrl)) {
#if defined(_DEBUG) && LOGTIMING
int ticks = msecs();
String wname = w->Name();