Subversion Repositories Kolibri OS

Rev

Rev 8365 | Details | Compare with Previous | Last modification | View Log | RSS feed

Rev Author Line No. Line
7491 leency 1
 
2
#define LOAD_CPU 0x2460C8
3
#define PROGRESS_ACTIVE 0x62B7E4
8365 leency 4
#define PROGRESS_BG 0xFFFfff
7491 leency 5
#define PROGRESS_BG_TEXT 0x696969
6
7
 
8
	int x,y,w,h;
9
	void set_size();
10
	void draw_wrapper();
11
	void draw_progress();
12
};
13
14
 
15
{
16
	x=_x+2;
17
	y=_y;
18
	w=_w;
19
	h=_h;
20
	draw_wrapper();
21
}
22
23
 
24
{
25
	DrawRectangle(x-1, y-1, w+1, h+1, sc.line);
9602 leency 26
	DrawRectangle3D(x-2, y-2, w+3, h+3, sc.work, sc.light);
27
}
7491 leency 28
29
 
7906 leency 30
{
7491 leency 31
	char textp[16];
7906 leency 32
	DrawBar(x, y,     w-progress_w, 1,   MixColors(PROGRESS_ACTIVE, PROGRESS_BG, 200));
7491 leency 33
	DrawBar(x, y+1,   w-progress_w, h-2, PROGRESS_ACTIVE);
34
	DrawBar(x, y+h-1, w-progress_w, 1,   MixColors(PROGRESS_ACTIVE, sc.line, 200));
9602 leency 35
	DrawBar(x+w-progress_w, y, progress_w, h, PROGRESS_BG);
7906 leency 36
7491 leency 37
 
7906 leency 38
	chrcat(#textp, '%');
39
	WriteText(-strlen(#textp)*8 + w / 2 + x, h/2-7+y, 0x90, 0x000000, #textp);
40
}
7491 leency 41