Details | Last modification | View Log | RSS feed
Rev | Author | Line No. | Line |
---|---|---|---|
6289 | leency | 1 | |
8901 | leency | 2 | // // |
3 | // PATH // |
||
4 | // // |
||
5 | //===================================================// |
||
6 | |||
7 | |||
8 | PathShow_data PathShow = {0, 17,250, 6, 250, 0, 0, 0x000000, 0xFFFFCC, NULL, #work_area_pointer, 0}; |
||
8949 | leency | 9 | void DrawPathBar() |
6289 | leency | 10 | { |
11 | if (efm) { |
||
8854 | leency | 12 | DrawPathBarKfm(); |
8901 | leency | 13 | return; |
8854 | leency | 14 | } |
15 | |||
16 | |||
8901 | leency | 17 | DrawBreadCrumbs(); |
18 | return; |
||
19 | } |
||
20 | |||
21 | |||
8949 | leency | 22 | PathShow.start_x = 250; |
8901 | leency | 23 | PathShow.start_y = 17; |
24 | PathShow.area_size_x = Form.cwidth-300; |
||
6291 | leency | 25 | DrawBar(PathShow.start_x-3, PathShow.start_y-6, PathShow.area_size_x+3, 19, col.odd_line); |
7634 | leency | 26 | DrawRectangle(PathShow.start_x-4,PathShow.start_y-7,PathShow.area_size_x+4,20,sc.work_graph); |
7806 | leency | 27 | DefineHiddenButton(PathShow.start_x-4+1,PathShow.start_y-7+1,PathShow.area_size_x+4-2,20-2,PATH_BTN); |
7422 | leency | 28 | DrawBar(PathShow.start_x-4, PathShow.start_y+14, PathShow.area_size_x+5+18, 1, sc.work_light); |
7806 | leency | 29 | |
7462 | leency | 30 | |
31 | |||
32 | |||
7634 | leency | 33 | PathShow_prepare stdcall(#PathShow); |
6289 | leency | 34 | PathShow_draw stdcall(#PathShow); |
35 | } |
||
36 | |||
37 | |||
8901 | leency | 38 | { |
39 | dword bgc; |
||
40 | int i=0; |
||
41 | if (!Form.cwidth) return; |
||
42 | |||
43 | |||
44 | bgc = col.odd_line; |
||
45 | PathShow.font_color = col.list_gb_text; |
||
46 | } else { |
||
47 | bgc = 0xFFFFCC; |
||
48 | PathShow.font_color = 0x222222; |
||
49 | } |
||
50 | PathShow.start_y = Form.cheight - status_bar_h+2; |
||
8949 | leency | 51 | |
52 | |||
8901 | leency | 53 | PathShow.area_size_x = Form.cwidth/2-8; |
54 | do { |
||
8949 | leency | 55 | DrawBar(PathShow.start_x-2,PathShow.start_y-3,PathShow.area_size_x+5,14,bgc); |
56 | DrawRectangle(PathShow.start_x-3,PathShow.start_y-4,PathShow.area_size_x+6,15,sc.work_graph); |
||
57 | PathShow.text_pointer = location[i]; |
||
58 | PathShow_prepare stdcall(#PathShow); |
||
59 | PathShow_draw stdcall(#PathShow); |
||
60 | |||
61 | |||
8901 | leency | 62 | PathShow.area_size_x = Form.cwidth - PathShow.start_x - 5; |
8949 | leency | 63 | i++; |
64 | } while (i<2); |
||
65 | |||
8901 | leency | 66 | |
67 | DrawBar(Form.cwidth-1,PathShow.start_y-2,1,15,sc.work); |
||
68 | DrawBar(1,PathShow.start_y+12,Form.cwidth-2,1,sc.work_light); |
||
69 | } |
||
70 | |||
71 | |||
72 | // // |
||
73 | // BREADCRUMBS // |
||
74 | // // |
||
75 | //===================================================// |
||
76 | |||
77 | |||
6289 | leency | 78 | collection_int breadCrumb=0; |
7972 | leency | 79 | char PathShow_path[4096]; |
6289 | leency | 80 | block btn; |
7227 | leency | 81 | int i; |
6289 | leency | 82 | unsigned text_line; |
8868 | leency | 83 | { |
6289 | leency | 84 | strcat(#PathShow_path, path); |
8949 | leency | 85 | for (i=0; i<50; i++) DeleteButton(i+BREADCRUMB_ID); |
6289 | leency | 86 | breadCrumb.drop(); |
87 | for (i=0; (PathShow_path[i]) && (i |
||
8901 | leency | 88 | { |
6289 | leency | 89 | if (PathShow_path[i]=='/') { |
90 | PathShow_path[i] = NULL; |
||
91 | breadCrumb.add(i+1); |
||
92 | } |
||
93 | } |
||
94 | breadCrumb.add(i+1); |
||
6782 | leency | 95 | btn.set_size(246,10,NULL,20); |
6739 | leency | 96 | //area_w = Form.cwidth - btn.x - 20; |
8868 | leency | 97 | for (i=0; i |
6289 | leency | 98 | { |
99 | text_line = breadCrumb.get(i) + #PathShow_path; |
||
100 | btn.w = strlen(text_line)*8+10; |
||
101 | DrawBreadcrumbButton(btn.x, btn.y, btn.w, btn.h, i+BREADCRUMB_ID, text_line); |
||
102 | btn.x += btn.w; |
||
103 | } |
||
104 | //DrawFavButton(btn.x); |
||
6291 | leency | 105 | //btn.x+=20; |
106 | btn.x++; |
||
107 | DrawBar(btn.x,btn.y-1,Form.cwidth-btn.x-25,btn.h+3,sc.work); |
||
7806 | leency | 108 | } |
6289 | leency | 109 | |
110 | |||
111 | |||
112 | { |
||
113 | int i, slashpos = path; |
||
8949 | leency | 114 | for (i=0; i!=clickid+2; i++) { |
6289 | leency | 115 | slashpos=strchr(slashpos,'/')+1; |
116 | } |
||
117 | ESBYTE[slashpos-1] = NULL; |
||
6782 | leency | 118 | Open_Dir(path,WITH_REDRAW); |
8949 | leency | 119 | } |
6289 | leency | 120 | |
121 | |||
122 | |||
123 | { |
||
124 | int i; |
||
125 | DrawRectangle(x,y,w,h,sc.work_graph); |
||
7806 | leency | 126 | for (i=0; (i |
7634 | leency | 127 | DrawRectangle3D(x+1,y+1,w-2,h-2,sc.work_light, sc.work_dark); |
7806 | leency | 128 | DefineHiddenButton(x+1,y+1,w-2,h-2,id); |
7422 | leency | 129 | WriteText(-strlen(text)*8+w/2+x,h/2+y-7,0x90,sc.work_text,text); |
7806 | leency | 130 | DrawBar(x, y+h+1, w+1, 1, sc.work_light); |
131 | }20);>50;>2); |
||
6289 | leency | 132 |