Subversion Repositories Kolibri OS

Rev

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

Rev Author Line No. Line
6289 leency 1
 
2
void DrawPathBar()
3
{
4
	PathShow.start_x = -efm*20 + 250;
8764 leency 5
6
 
6291 leency 7
	DrawBar(PathShow.start_x-3, PathShow.start_y-6, PathShow.area_size_x+3, 19, col.odd_line);
7634 leency 8
	DrawRectangle(PathShow.start_x-4,PathShow.start_y-7,PathShow.area_size_x+4,20,sc.work_graph);
7806 leency 9
	DefineHiddenButton(PathShow.start_x-4+1,PathShow.start_y-7+1,PathShow.area_size_x+4-2,20-2,PATH_BTN);
7422 leency 10
	DrawBar(PathShow.start_x-4, PathShow.start_y+14, PathShow.area_size_x+5+18, 1, sc.work_light);
7806 leency 11
7462 leency 12
 
13
14
 
7634 leency 15
	PathShow.font_color = col.list_gb_text;
16
	PathShow_prepare stdcall(#PathShow);
6289 leency 17
	PathShow_draw stdcall(#PathShow);
18
}
19
20
 
21
 collection_int breadCrumb=0;
7972 leency 22
 char PathShow_path[4096];
6289 leency 23
 block btn;
7227 leency 24
 int i;
6289 leency 25
 unsigned text_line, area_w;
26
 {
27
	strcat(#PathShow_path, #path);
28
	for (i=0; i<50; i++) DeleteButton(i+BREADCRUMB_ID);
29
	breadCrumb.drop();
30
	for (i=0; PathShow_path[i]; i++)
31
	{
32
		if (PathShow_path[i]=='/') {
33
			PathShow_path[i] = NULL;
34
			breadCrumb.add(i+1);
35
		}
36
	}
37
	breadCrumb.add(i+1);
6782 leency 38
	btn.set_size(246,10,NULL,20);
6739 leency 39
	area_w = Form.cwidth - btn.x - 20;
6289 leency 40
	for (i=0; i
41
	{
42
		text_line = breadCrumb.get(i) + #PathShow_path;
43
		btn.w = strlen(text_line)*8+10;
44
		DrawBreadcrumbButton(btn.x, btn.y, btn.w, btn.h, i+BREADCRUMB_ID, text_line);
45
		btn.x += btn.w;
46
	}
47
	//DrawFavButton(btn.x);
6291 leency 48
	//btn.x+=20;
49
	btn.x++;
50
	DrawBar(btn.x,btn.y-1,Form.cwidth-btn.x-25,btn.h+3,sc.work);
7806 leency 51
}
6289 leency 52
53
 
54
 
55
{
56
	int i, slashpos = #path;
57
	for (i=0; i!=clickid+2; i++) {
58
		slashpos=strchr(slashpos,'/')+1;
59
	}
60
	ESBYTE[slashpos-1] = NULL;
6782 leency 61
	Open_Dir(#path,WITH_REDRAW);
6289 leency 62
}
63
64
 
65
 
66
{
67
	int i;
68
	DrawRectangle(x,y,w,h,sc.work_graph);
7806 leency 69
	for (i=0; (i
7634 leency 70
	DrawRectangle3D(x+1,y+1,w-2,h-2,sc.work_light, sc.work_dark);
7806 leency 71
	DefineHiddenButton(x+1,y+1,w-2,h-2,id);
7422 leency 72
	WriteText(-strlen(text)*8+w/2+x,h/2+y-7,0x90,sc.work_text,text);
7806 leency 73
	DrawBar(x, y+h+1, w+1, 1, sc.work_light);
74
}
6289 leency 75