Commit 199e84f9 by Amnes1a

修复扫码界面卡死问题

parent 5e2b2c1a
...@@ -81,7 +81,7 @@ void ScanningDialog::timeOut() ...@@ -81,7 +81,7 @@ void ScanningDialog::timeOut()
HWND hForeWnd = ::GetForegroundWindow(); HWND hForeWnd = ::GetForegroundWindow();
DWORD dwForeID = ::GetWindowThreadProcessId(hForeWnd,NULL); DWORD dwForeID = ::GetWindowThreadProcessId(hForeWnd,NULL);
DWORD dwCurID = ::GetCurrentThreadId(); DWORD dwCurID = ::GetCurrentThreadId();
::AttachThreadInput(dwCurID,dwForeID,TRUE); //::AttachThreadInput(dwCurID,dwForeID,TRUE);
::SetWindowPos( (HWND)effectiveWinId(), HWND_TOPMOST, 0, 0, 0, 0, SWP_NOMOVE | SWP_NOSIZE | SWP_SHOWWINDOW); ::SetWindowPos( (HWND)effectiveWinId(), HWND_TOPMOST, 0, 0, 0, 0, SWP_NOMOVE | SWP_NOSIZE | SWP_SHOWWINDOW);
...@@ -89,7 +89,7 @@ void ScanningDialog::timeOut() ...@@ -89,7 +89,7 @@ void ScanningDialog::timeOut()
::SetForegroundWindow((HWND)this->effectiveWinId()); ::SetForegroundWindow((HWND)this->effectiveWinId());
::AttachThreadInput(dwCurID,dwForeID,FALSE); //::AttachThreadInput(dwCurID,dwForeID,FALSE);
this->setFocus(); this->setFocus();
ui->labScaningBar->setFocus(); ui->labScaningBar->setFocus();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment