| 93 | } |
| 94 | |
| 95 | void ProgressDialog::goToCenter() |
| 96 | { |
| 97 | RECT rc; |
| 98 | HWND hParent = ::GetParent(_hSelf); |
| 99 | ::GetClientRect(hParent, &rc); |
| 100 | POINT center; |
| 101 | center.x = rc.left + (rc.right - rc.left)/2; |
| 102 | center.y = rc.top + (rc.bottom - rc.top)/2; |
| 103 | ::ClientToScreen(hParent, ¢er); |
| 104 | |
| 105 | RECT wrc; |
| 106 | ::GetWindowRect(_hSelf, &wrc); |
| 107 | int x = center.x - (wrc.right - wrc.left)/2; |
| 108 | int y = center.y - (wrc.bottom - wrc.top)/2; |
| 109 | |
| 110 | ::SetWindowPos(_hSelf, HWND_TOP, x, y, wrc.right - wrc.left, wrc.bottom - wrc.top, SWP_SHOWWINDOW); |
| 111 | } |
| 112 | |
| 113 | |
| 114 | void ProgressDialog::setStepCount(int stepCount) |
nothing calls this directly
no outgoing calls
no test coverage detected