Subversion Repositories Kolibri OS

Rev

Rev 7910 | Rev 8789 | Go to most recent revision | Details | Compare with Previous | Last modification | View Log | RSS feed

Rev Author Line No. Line
7759 leency 1
 
7910 leency 2
{
7759 leency 3
	#define TSZE 25
4
	static libimg_image top_icons;
5
	static dword semi_white=0, bg_col_light, bg_col_dark;
7780 leency 6
	int i;
7866 leency 7
	if (!semi_white) {
7759 leency 8
		top_icons.load("/sys/icons16.png");
7977 leency 9
7759 leency 10
 
7806 leency 11
		bg_col_dark = MixColors(sc.work, sc.work_graph, 90);
12
		bg_col_light = MixColors(semi_white, 0xFFFfff, skin_is_dark()*90 + 10);
7780 leency 13
7759 leency 14
 
7977 leency 15
		top_icons.replace_color(0xffCACBD6, MixColors(semi_white, 0, 220));
16
	}
7759 leency 17
18
 
19
20
 
21
	if (_icon_n==-1) {
22
		DrawBar(_x+6, _y+5, 16, 16, semi_white);
23
		for (i=0; i<=2; i++) DrawBar(_x+6, i*5+_y+7, 15, 3, sc.work_graph);
7866 leency 24
	} else {
7759 leency 25
		img_draw stdcall(top_icons.image, _x+6, _y+5+pressed, 16, 16, 0, _icon_n*16);
7910 leency 26
	}
7759 leency 27
7910 leency 28
 
29
		DrawOvalBorder(_x, _y, TSZE, TSZE, bg_col_light, bg_col_dark, semi_white, sc.work);
30
	} else {
31
		DrawOvalBorder(_x, _y, TSZE, TSZE, sc.work_graph, bg_col_light, semi_white, sc.work);
32
		PutShadow(_x+1, _y+1, TSZE, TSZE, true, 2);
33
	}
34
35
 
7866 leency 36
}
7759 leency 37