you can now delete characters in the timerentry description with the mute-key
[enigma2.git] / lib / base / thread.h
1 #ifndef __lib_base_thread_h
2 #define __lib_base_thread_h
3
4 #include <pthread.h>
5 #include <signal.h>
6
7 class eThread
8 {
9         pthread_t the_thread;
10         static void *wrapper(void *ptr);
11         int alive;
12         static void thread_completed(void *p);
13 public:
14         bool thread_running() { return alive; }
15         eThread();
16         virtual ~eThread();
17
18         void run(int prio=0, int policy=0);
19
20         virtual void thread()=0;
21         virtual void thread_finished() { }
22         void sendSignal(int sig);
23
24         void kill(bool sendcancel=false);
25 };
26
27 #endif