Last change
on this file was
49,
checked in by Sam Hocevar, 15 years ago
|
- Imported original public domain release, for future reference.
|
File size:
880 bytes
|
Line | |
---|
1 | #ifndef __STATUS_HPP_ |
---|
2 | #define __STATUS_HPP_ |
---|
3 | |
---|
4 | #include "visobj.hpp" // get visual object declaration |
---|
5 | |
---|
6 | |
---|
7 | class status_manager |
---|
8 | { |
---|
9 | public : |
---|
10 | virtual void push(char *name, visual_object *show) = 0; |
---|
11 | virtual void update(int percentage) = 0; |
---|
12 | virtual void pop() = 0; |
---|
13 | virtual void force_display() { ; } |
---|
14 | } ; |
---|
15 | |
---|
16 | |
---|
17 | class text_status_node; |
---|
18 | |
---|
19 | class text_status_manager : public status_manager |
---|
20 | { |
---|
21 | public : |
---|
22 | int level; |
---|
23 | text_status_node *first; |
---|
24 | text_status_manager(); |
---|
25 | virtual void push(char *name, visual_object *show); |
---|
26 | virtual void update(int percentage); |
---|
27 | virtual void pop(); |
---|
28 | } ; |
---|
29 | |
---|
30 | |
---|
31 | extern status_manager *stat_man; |
---|
32 | |
---|
33 | class stack_stat // something you can declare on the stact that is sure to get cleaned up |
---|
34 | { |
---|
35 | public : |
---|
36 | stack_stat(char *st, visual_object *show=NULL) { if (stat_man) stat_man->push(st,show); } |
---|
37 | ~stack_stat() { if (stat_man) stat_man->pop(); } |
---|
38 | } ; |
---|
39 | |
---|
40 | |
---|
41 | #endif |
---|
42 | |
---|
Note: See
TracBrowser
for help on using the repository browser.