| 124 | } |
| 125 | |
| 126 | static void StopRecording() |
| 127 | { |
| 128 | auto const& args = GetCommandLineArgs(); |
| 129 | |
| 130 | assert(IsRecording() == true); |
| 131 | gIsRecording = false; |
| 132 | |
| 133 | // Stop time --timed timer if there is one |
| 134 | if (args.mStartTimer) { |
| 135 | KillTimer(gWnd, TIMED_TIMER_ID); |
| 136 | } |
| 137 | |
| 138 | // Tell OutputThread to stop recording |
| 139 | SetOutputRecordingState(false); |
| 140 | |
| 141 | // Notify the user we're no longer recording |
| 142 | if (args.mScrollLockIndicator) { |
| 143 | EnableScrollLock(false); |
| 144 | } |
| 145 | if (args.mConsoleOutput == ConsoleOutput::Simple && args.mCSVOutput != CSVOutput::None) { |
| 146 | wprintf(L"Stopped recording.\n"); |
| 147 | } |
| 148 | } |
| 149 | |
| 150 | // Handle Ctrl events (CTRL_C_EVENT, CTRL_BREAK_EVENT, CTRL_CLOSE_EVENT, |
| 151 | // CTRL_LOGOFF_EVENT, CTRL_SHUTDOWN_EVENT) by redirecting the termination into |
no test coverage detected