张洋 3 weeks ago
parent
commit
3b6e379429

+ 8 - 0
DuiLib/Core/UIBase.cpp

@@ -529,6 +529,14 @@ LRESULT CALLBACK CWindowWnd::__WndProc(HWND hWnd, UINT uMsg, WPARAM wParam, LPAR
             return lRes;
             return lRes;
         }
         }
     }
     }
+    // 临时诊断:确认 WM_TOUCH 是否真的被 Windows 投递到本窗口过程
+    // (用于区分「Windows 没投递」与「我们的消息链丢了」,定位完删除)
+    if( uMsg == WM_TOUCH ) {
+        DuiLib::TouchTrace::Log(_T("WNDPROC-TOUCH hwnd=%p pThis=%p owner=%p parent=%p extra=0x%08X style=0x%08X ex=0x%08X"),
+            (void*)hWnd, (void*)pThis, (void*)::GetWindow(hWnd, GW_OWNER), (void*)::GetParent(hWnd),
+            (unsigned)(DWORD_PTR)::GetMessageExtraInfo(),
+            (unsigned)::GetWindowLong(hWnd, GWL_STYLE), (unsigned)::GetWindowLong(hWnd, GWL_EXSTYLE));
+    }
     if( pThis != NULL ) {
     if( pThis != NULL ) {
         return pThis->HandleMessage(uMsg, wParam, lParam);
         return pThis->HandleMessage(uMsg, wParam, lParam);
     } 
     } 

+ 3 - 2
DuiLib/Core/UIManager.cpp

@@ -738,10 +738,11 @@ namespace DuiLib
 		BOOL bRegistered = FALSE;
 		BOOL bRegistered = FALSE;
 		if (pfnRegister != NULL)
 		if (pfnRegister != NULL)
 			bRegistered = pfnRegister(m_hWndPaint, 0);
 			bRegistered = pfnRegister(m_hWndPaint, 0);
-		TouchTrace::Log(_T("REGISTER hwnd=%p manager=%p result=%d error=%u style=0x%08X ex=0x%08X"),
+		TouchTrace::Log(_T("REGISTER hwnd=%p manager=%p result=%d error=%u style=0x%08X ex=0x%08X owner=%p parent=%p"),
 			(void*)m_hWndPaint, (void*)this, (int)bRegistered, bRegistered ? 0u : ::GetLastError(),
 			(void*)m_hWndPaint, (void*)this, (int)bRegistered, bRegistered ? 0u : ::GetLastError(),
 			(unsigned)::GetWindowLong(m_hWndPaint, GWL_STYLE),
 			(unsigned)::GetWindowLong(m_hWndPaint, GWL_STYLE),
-			(unsigned)::GetWindowLong(m_hWndPaint, GWL_EXSTYLE));
+			(unsigned)::GetWindowLong(m_hWndPaint, GWL_EXSTYLE),
+			(void*)::GetWindow(m_hWndPaint, GW_OWNER), (void*)::GetParent(m_hWndPaint));
 	}
 	}
 
 
 	void CPaintManagerUI::OnTouchInput(WPARAM wParam, LPARAM lParam)
 	void CPaintManagerUI::OnTouchInput(WPARAM wParam, LPARAM lParam)

BIN
bin/Win32/Release/zhipuzi_pos_windows/DuiLib.dll


BIN
bin/Win32/Release/zhipuzi_pos_windows/zhipuzi_pos_windows.exe


BIN
dll/release/DuiLib.dll


BIN
pdb/release/DuiLib.pdb