Advanced Strategic Command
autoprogressbar.h
Go to the documentation of this file.
1 /***************************************************************************
2  dropdownselector
3  -------------------
4  copyright : (C) 2006 by Martin Bickel
5  email : <bickel@asc-hq.org>
6  ***************************************************************************/
7 
8 /***************************************************************************
9  * *
10  * This program is free software; you can redistribute it and/or modify *
11  * it under the terms of the GNU General Public License as published by *
12  * the Free Software Foundation; either version 2 of the License, or *
13  * (at your option) any later version. *
14  * *
15  ***************************************************************************/
16 
17 #ifndef autoprogressbarH
18 #define autoprogressbarH
19 
20 #include <vector>
21 #include <pgprogressbar.h>
22 #include "../global.h"
23 
24 class AutoProgressBar: public PG_ProgressBar {
25 
26  int starttime;
27  int time;
28  int lastticktime;
29  int lastdisplaytime;
30  int counter;
31  vector<int> newTickTimes;
32  vector<int> prevTickTimes;
33 
34  void tick();
35  public:
36  AutoProgressBar( sigc::signal<void>& tickSignal, PG_Widget *parent, const PG_Rect &r=PG_Rect::null, const std::string &style="Progressbar" );
37  void close( );
38 };
39 
40 #endif
AutoProgressBar(sigc::signal< void > &tickSignal, PG_Widget *parent, const PG_Rect &r=PG_Rect::null, const std::string &style="Progressbar")