Rev 4674 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 4674 | Rev 4718 | ||
---|---|---|---|
Line 42... | Line 42... | ||
42 | 42 | ||
43 | do{ |
43 | do{ |
44 | if (!strcmp(#parametr,"src=")) //íàäî îáúåäèíèòü ñ GetNewUrl() |
44 | if (!strcmp(#parametr,"src=")) //íàäî îáúåäèíèòü ñ GetNewUrl() |
45 | { |
45 | { |
46 | if (http_transfer<>0) strcpy(#img_path, #history_list[BrowserHistory.current-1].Item); else |
- | |
47 | strcpy(#img_path, BrowserHistory.CurrentUrl()); |
- | |
48 | if (strcmpn(#img_path, "http:", 5)!=0) || (strcmpn(#options, "http:", 5)!=0) |
- | |
49 | { |
- | |
50 | //get path: absolute or relative |
- | |
51 | if (options[0]=='/') |
46 | if (http_transfer<>0) strcpy(#img_path, #history_list[BrowserHistory.current-1].Item); else |
52 | strcpy(#img_path, #options); |
- | |
53 | else |
- | |
54 | { |
47 | strcpy(#img_path, #options); |
55 | img_path[strrchr(#img_path, '/')] = '\0'; |
- | |
56 | strcat(#img_path, #options); |
- | |
57 | } |
48 | PageLinks.GetAbsoluteURL(#img_path); |
58 | cur_pic = GetImageNumber(#img_path); |
49 | cur_pic = GetImageNumber(#img_path); |
59 | } |
- | |
60 | } |
50 | } |
61 | if (!strcmp(#parametr,"alt=")) |
51 | if (!strcmp(#parametr,"alt=")) |
62 | { |
52 | { |
63 | strcpy(#alt, "["); |
53 | strcpy(#alt, "["); |
64 | strcat(#alt, #options); |
54 | strcat(#alt, #options); |
Line 76... | Line 66... | ||
76 | imgw = DSWORD[pics[cur_pic].image+4]; |
66 | imgw = DSWORD[pics[cur_pic].image+4]; |
77 | imgh = DSWORD[pics[cur_pic].image+8]; |
67 | imgh = DSWORD[pics[cur_pic].image+8]; |
78 | if (imgw > width1) imgw = width1; |
68 | if (imgw > width1) imgw = width1; |
Line 79... | Line 69... | ||
79 | 69 | ||
80 | if (stroka==0) DrawBar(WB1.list.x, WB1.list.y, WB1.list.w-15, 5, bg_color); //çàêðàøèâàåì ïåðâóþ ñòðîêó |
70 | if (stroka==0) DrawBar(WB1.list.x, WB1.list.y, WB1.list.w-15, 5, bg_color); //çàêðàøèâàåì ïåðâóþ ñòðîêó |
- | 71 | stroka += imgh / WB1.list.line_h; |
|
81 | stroka += imgh/10; |
72 | if (imgh % WB1.list.line_h) stroka++; |
82 | if (top1+imgh |
73 | if (top1+imgh |
83 | if (top1 |
74 | if (top1 |
84 | { |
75 | { |
85 | img_lines_first=WB1.list.y-top1; |
76 | img_lines_first=WB1.list.y-top1; |
Line 93... | Line 84... | ||
93 | if (imgh<=0) return; |
84 | if (imgh<=0) return; |
94 | if (anchor) return; |
85 | if (anchor) return; |
Line 95... | Line 86... | ||
95 | 86 | ||
96 | img_draw stdcall (pics[cur_pic].image, left1-5, top1, imgw, imgh,0,img_lines_first); |
87 | img_draw stdcall (pics[cur_pic].image, left1-5, top1, imgw, imgh,0,img_lines_first); |
- | 88 | DrawBar(left1+imgw - 5, top1, WB1.list.w-imgw, imgh, bg_color); |
|
97 | DrawBar(left1+imgw - 5, top1, WB1.list.w-imgw, imgh, bg_color); |
89 | DrawBar(WB1.list.x, top1+imgh, WB1.list.w, -imgh % WB1.list.line_h + WB1.list.line_h, bg_color); |
98 | IF (link) |
90 | IF (link) |
99 | { |
91 | { |
100 | UnsafeDefineButton(left1 - 5, top1, imgw, imgh-1, PageLinks.count + 400 + BT_HIDE, 0xB5BFC9); |
92 | UnsafeDefineButton(left1 - 5, top1, imgw, imgh-1, PageLinks.count + 400 + BT_HIDE, 0xB5BFC9); |
101 | PageLinks.AddText(0, imgw, imgh-1, NOLINE); |
93 | PageLinks.AddText(0, imgw, imgh-1, NOLINE); |