Debian Codegraph @

src/board/clockdisplay.h

raw symbols SCIP
1 /***************************************************************************
2 * Copyright (C) 2009 by The qGo Project *
3 * *
4 * This file is part of qGo. *
5 * *
6 * qGo is free software: you can redistribute it and/or modify *
7 * it under the terms of the GNU General Public License as published by *
8 * the Free Software Foundation; either version 2 of the License, or *
9 * (at your option) any later version. *
10 * *
11 * This program is distributed in the hope that it will be useful, *
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of *
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
14 * GNU General Public License for more details. *
15 * *
16 * You should have received a copy of the GNU General Public License *
17 * along with this program; if not, see <http://www.gnu.org/licenses/> *
18 * or write to the Free Software Foundation, Inc., *
19 * 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. *
20 ***************************************************************************/
21
22
23 #ifndef CLOCK_H
24 #define CLOCK_H
25
26 #include "defines.h"
27 #include <QObject>
28
29 class BoardWindow;
30 class Sound;
31
32 class ClockDisplay : public QObject
33 {
34 Q_OBJECT
35
36 public:
37 ClockDisplay(BoardWindow *bw, TimeSystem s, int _maintime, int _period, int _periodtime);
38 ~ClockDisplay() {}
39 void setTime( bool black, int secs);
40 void setTimeStep(bool black);
41 void rerackTime(bool black);
42 void makeMove(bool black);
43 class TimeRecord getTimeRecord(bool black);
44 void setTimeSettings(TimeSystem s, int m, int p, int o);
45 void setTimeInfo(int btime, int bstones_periods, int wtime, int wstones_periods);
46 void updateTimers();
47 bool warning(bool black);
48 private :
49 BoardWindow *boardwindow;
50 TimeSystem timeSystem;
51 int w_time, b_time;
52 int w_stones_periods, b_stones_periods;
53 int maintime, periods, periodtime;
54 Sound *warningSound;
55 int warningSecs;
56 bool playWarningSound;
57 bool outOfMainTime;
58 bool last_black;
59 };
60
61 #endif