Rev 7771 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 7771 | Rev 7806 | ||
---|---|---|---|
Line 64... | Line 64... | ||
64 | } |
64 | } |
65 | } |
65 | } |
66 | break; |
66 | break; |
Line 67... | Line 67... | ||
67 | 67 | ||
68 | case SEND_NLIST: |
68 | case SEND_NLIST: |
69 | WriteText(5, Form.cheight-11, 0x80, system.color.work_text, "Send LIST, awaiting answer..."); |
69 | WriteText(5, Form.cheight-11, 0x80, sc.work_text, "Send LIST, awaiting answer..."); |
70 | request_len = GetRequest("LIST", NULL); |
70 | request_len = GetRequest("LIST", NULL); |
71 | Send(socketnum, #request, request_len, 0); |
71 | Send(socketnum, #request, request_len, 0); |
72 | if (EAX == 0xffffffff) {debugln("Error while sending LIST. Retry..."); break;} |
72 | if (EAX == 0xffffffff) {debugln("Error while sending LIST. Retry..."); break;} |
73 | else aim = GET_ANSWER_NLIST; |
73 | else aim = GET_ANSWER_NLIST; |
Line 236... | Line 236... | ||
236 | LoginBoxLoop(); |
236 | LoginBoxLoop(); |
237 | } |
237 | } |
238 | if (id==CHANGE_CHARSET) |
238 | if (id==CHANGE_CHARSET) |
239 | { |
239 | { |
240 | DefineButton(0,0,Form.cwidth,Form.cheight, CLOSE_CHANGE_CHARSET+BT_HIDE+BT_NOFRAME); |
240 | DefineButton(0,0,Form.cwidth,Form.cheight, CLOSE_CHANGE_CHARSET+BT_HIDE+BT_NOFRAME); |
241 | DrawRectangle(Form.cwidth-100, Form.cheight-status_bar_h- 70, 70, 82, system.color.work_graph); |
241 | DrawRectangle(Form.cwidth-100, Form.cheight-status_bar_h- 70, 70, 82, sc.work_graph); |
242 | DrawRectangle3D(Form.cwidth-99, Form.cheight-status_bar_h- 69, 68, 80, 0xFFFfff, system.color.work); |
242 | DrawRectangle3D(Form.cwidth-99, Form.cheight-status_bar_h- 69, 68, 80, 0xFFFfff, sc.work); |
243 | for (id=0; id<5; id++) |
243 | for (id=0; id<5; id++) |
244 | { |
244 | { |
245 | if (cur_charset==id+1) { line_col=system.color.work_button; text_col=system.color.work_button_text; } |
245 | if (cur_charset==id+1) { line_col=sc.button; text_col=sc.button_text; } |
246 | else { line_col=system.color.work; text_col=system.color.work_text; } |
246 | else { line_col=sc.work; text_col=sc.work_text; } |
247 | DrawBar(Form.cwidth-98, id*16+Form.cheight-status_bar_h- 68, 67, 16, line_col); |
247 | DrawBar(Form.cwidth-98, id*16+Form.cheight-status_bar_h- 68, 67, 16, line_col); |
248 | DrawCaptButton(Form.cwidth-100, id*16+Form.cheight-status_bar_h- 68, 70,16, 10+id+BT_HIDE, |
248 | DrawCaptButton(Form.cwidth-100, id*16+Form.cheight-status_bar_h- 68, 70,16, 10+id+BT_HIDE, |
249 | 0, text_col, charsets[id+1]); |
249 | 0, text_col, charsets[id+1]); |
250 | } |
250 | } |
251 | } |
251 | } |
Line 263... | Line 263... | ||
263 | 263 | ||
264 | break; |
264 | break; |
265 | case evReDraw: _MB_DRAW: |
265 | case evReDraw: _MB_DRAW: |
266 | if !(DefineWindow(MAILBOX_HEADER)) break; |
266 | if !(DefineWindow(MAILBOX_HEADER)) break; |
267 | scroll1.bckg_col = scroll_wv.bckg_col = 0xBBBbbb; |
267 | scroll1.bckg_col = scroll_wv.bckg_col = 0xBBBbbb; |
268 | scroll1.frnt_col = scroll_wv.frnt_col = system.color.work; |
268 | scroll1.frnt_col = scroll_wv.frnt_col = sc.work; |
269 | scroll1.line_col = scroll_wv.line_col = system.color.work_graph; |
269 | scroll1.line_col = scroll_wv.line_col = sc.work_graph; |
270 | DrawToolbar(); |
270 | DrawToolbar(); |
Line 271... | Line 271... | ||
271 | DrawMailBox(); |
271 | DrawMailBox(); |
272 | 272 | ||
Line 293... | Line 293... | ||
293 | #define BUT_H 22 |
293 | #define BUT_H 22 |
294 | #define BUT_W 74 |
294 | #define BUT_W 74 |
295 | int toolbar_w = BUT_Y + BUT_H + BUT_Y + 3; |
295 | int toolbar_w = BUT_Y + BUT_H + BUT_Y + 3; |
296 | mail_list.SetSizes(0, toolbar_w, Form.cwidth - scroll1.size_x - 1, mail_list.h, 18); |
296 | mail_list.SetSizes(0, toolbar_w, Form.cwidth - scroll1.size_x - 1, mail_list.h, 18); |
Line 297... | Line 297... | ||
297 | 297 | ||
298 | DrawBar(0,0, Form.cwidth,toolbar_w-3, system.color.work); |
298 | DrawBar(0,0, Form.cwidth,toolbar_w-3, sc.work); |
299 | DrawCaptButton(10 , BUT_Y, BUT_W, BUT_H, GET_MAIL, system.color.work_button, system.color.work_button_text,"Get mail"); |
299 | DrawCaptButton(10 , BUT_Y, BUT_W, BUT_H, GET_MAIL, sc.button, sc.button_text,"Get mail"); |
300 | DrawCaptButton(BUT_W+ 20, BUT_Y, BUT_W+10, BUT_H, SAVE_LETTER, system.color.work_button, system.color.work_button_text,"Save letter"); |
300 | DrawCaptButton(BUT_W+ 20, BUT_Y, BUT_W+10, BUT_H, SAVE_LETTER, sc.button, sc.button_text,"Save letter"); |
Line 301... | Line 301... | ||
301 | DrawCaptButton(Form.cwidth-BUT_W - 10, BUT_Y, BUT_W, BUT_H, EXIT_MAIL, system.color.work_button, system.color.work_button_text,"< Exit"); |
301 | DrawCaptButton(Form.cwidth-BUT_W - 10, BUT_Y, BUT_W, BUT_H, EXIT_MAIL, sc.button, sc.button_text,"< Exit"); |
302 | 302 | ||
303 | DrawBar(0, mail_list.y-3, mail_list.w,1, system.color.work_graph); |
303 | DrawBar(0, mail_list.y-3, mail_list.w,1, sc.work_graph); |
304 | DrawBar(0, mail_list.y-2, mail_list.w,1, 0xdfdfdf); |
304 | DrawBar(0, mail_list.y-2, mail_list.w,1, 0xdfdfdf); |
Line 305... | Line 305... | ||
305 | DrawBar(0, mail_list.y-1, mail_list.w,1, 0xf0f0f0); |
305 | DrawBar(0, mail_list.y-1, mail_list.w,1, 0xf0f0f0); |
Line 330... | Line 330... | ||
330 | DrawScroller1(); |
330 | DrawScroller1(); |
331 | } |
331 | } |
Line 332... | Line 332... | ||
332 | 332 | ||
333 | void DrawLetterInfo() { |
333 | void DrawLetterInfo() { |
334 | int lt_y = mail_list.y+mail_list.h; |
334 | int lt_y = mail_list.y+mail_list.h; |
335 | DrawBar(0, lt_y, mail_list.w, 1, system.color.work_graph); |
335 | DrawBar(0, lt_y, mail_list.w, 1, sc.work_graph); |
336 | DrawBar(0, lt_y+1, Form.cwidth, 1, LBUMP); |
336 | DrawBar(0, lt_y+1, Form.cwidth, 1, LBUMP); |
337 | DrawBar(0, lt_y+2, Form.cwidth, LIST_INFO_H-4, system.color.work); |
337 | DrawBar(0, lt_y+2, Form.cwidth, LIST_INFO_H-4, sc.work); |
338 | WriteText(mail_list.w-30/2, lt_y, 0x80, 0x888888, "= = ="); |
338 | WriteText(mail_list.w-30/2, lt_y, 0x80, 0x888888, "= = ="); |
339 | WriteText(mail_list.w-30/2, lt_y+1, 0x80, 0xEeeeee, "= = ="); |
339 | WriteText(mail_list.w-30/2, lt_y+1, 0x80, 0xEeeeee, "= = ="); |
340 | DrawBar(0, lt_y+LIST_INFO_H-2, Form.cwidth, 1, system.color.work_graph); //bottom |
340 | DrawBar(0, lt_y+LIST_INFO_H-2, Form.cwidth, 1, sc.work_graph); //bottom |
341 | DrawBar(0, lt_y+LIST_INFO_H-1, Form.cwidth, 1, 0xdfdfdf); |
341 | DrawBar(0, lt_y+LIST_INFO_H-1, Form.cwidth, 1, 0xdfdfdf); |
342 | DrawBar(0, lt_y+LIST_INFO_H , Form.cwidth, 1, 0xf0f0f0); |
342 | DrawBar(0, lt_y+LIST_INFO_H , Form.cwidth, 1, 0xf0f0f0); |
343 | WriteTextB(10, lt_y+8 , 0x80, system.color.work_text, "From:"); |
343 | WriteTextB(10, lt_y+8 , 0x80, sc.work_text, "From:"); |
344 | WriteText (45, lt_y+8 , 0x80, system.color.work_text, #from); |
344 | WriteText (45, lt_y+8 , 0x80, sc.work_text, #from); |
345 | WriteTextB(10, lt_y+20, 0x80, system.color.work_text, "To:"); |
345 | WriteTextB(10, lt_y+20, 0x80, sc.work_text, "To:"); |
346 | WriteText (45, lt_y+20, 0x80, system.color.work_text, #to); |
346 | WriteText (45, lt_y+20, 0x80, sc.work_text, #to); |
347 | WriteTextB(10, lt_y+32, 0x80, system.color.work_text, "Date:"); |
347 | WriteTextB(10, lt_y+32, 0x80, sc.work_text, "Date:"); |
348 | WriteText (45, lt_y+32, 0x80, system.color.work_text, #date); |
348 | WriteText (45, lt_y+32, 0x80, sc.work_text, #date); |
349 | WriteTextB(10, lt_y+44, 0x80, system.color.work_text, "Subj:"); |
349 | WriteTextB(10, lt_y+44, 0x80, sc.work_text, "Subj:"); |
350 | WriteText (45, lt_y+44, 0x80, system.color.work_text, #subj); |
350 | WriteText (45, lt_y+44, 0x80, sc.work_text, #subj); |
Line 351... | Line 351... | ||
351 | } |
351 | } |
352 | 352 | ||
Line 380... | Line 380... | ||
380 | 380 | ||
381 | 381 | ||
382 | 382 | ||
383 | void DrawStatusBar() { |
383 | void DrawStatusBar() { |
384 | int st_y = Form.cheight -status_bar_h; |
384 | int st_y = Form.cheight -status_bar_h; |
385 | DrawBar(0, st_y, Form.cwidth, status_bar_h, system.color.work); |
385 | DrawBar(0, st_y, Form.cwidth, status_bar_h, sc.work); |
386 | if (aim) { |
386 | if (aim) { |
387 | SetMailBoxStatus(cur_st_percent, cur_st_text); |
387 | SetMailBoxStatus(cur_st_percent, cur_st_text); |
388 | DrawCaptButton(240, st_y+1, 36, status_bar_h-3, STOP_LOADING, system.color.work_button, system.color.work_button_text,"Stop"); |
388 | DrawCaptButton(240, st_y+1, 36, status_bar_h-3, STOP_LOADING, sc.button, sc.button_text,"Stop"); |
389 | } |
389 | } |
Line 390... | Line 390... | ||
390 | DrawCaptButton(Form.cwidth - 100, st_y+1, 70, status_bar_h-2, CHANGE_CHARSET+BT_HIDE, |
390 | DrawCaptButton(Form.cwidth - 100, st_y+1, 70, status_bar_h-2, CHANGE_CHARSET+BT_HIDE, |
391 | system.color.work, system.color.work_text,cur_charset*10+#charsets); |
391 | sc.work, sc.work_text,cur_charset*10+#charsets); |
392 | } |
392 | } |
393 | 393 | ||
394 | 394 | ||
395 | 395 |