diff options
| author | Crystalwarrior <varsash@gmail.com> | 2020-08-25 12:48:09 +0300 |
|---|---|---|
| committer | Crystalwarrior <varsash@gmail.com> | 2020-08-25 12:48:09 +0300 |
| commit | ee3bad44c72329d61a2cb0c4064c22512451372d (patch) | |
| tree | 421e95752a4580b30dc097f4c5b72d7e2c7493fe /src/courtroom.cpp | |
| parent | 7e9c5726e02a65023d9563f49e833525bf8f4bae (diff) | |
Implement clock pausing
Implement clock setting w/o starting or stopping
Both of these should make it possible for the server to start/stop/pause/resume the clock with perfect synchronization to the true time.
Diffstat (limited to 'src/courtroom.cpp')
| -rw-r--r-- | src/courtroom.cpp | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/src/courtroom.cpp b/src/courtroom.cpp index 6bd2bd2d..f4e31647 100644 --- a/src/courtroom.cpp +++ b/src/courtroom.cpp @@ -4715,11 +4715,26 @@ void Courtroom::announce_case(QString title, bool def, bool pro, bool jud, } } +void Courtroom::start_clock() +{ + ui_clock->start(); +} + void Courtroom::start_clock(qint64 msecs) { ui_clock->start(static_cast<int>(msecs)); } +void Courtroom::set_clock(qint64 msecs) +{ + ui_clock->set(static_cast<int>(msecs), true); +} + +void Courtroom::pause_clock() +{ + ui_clock->pause(); +} + void Courtroom::stop_clock() { ui_clock->stop(); |
