Subversion Repositories Kolibri OS

Rev

Rev 7757 | Rev 7786 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 7757 Rev 7778
Line 1... Line 1...
1
//Leency, Veliant, Punk_Joker, PavelYakov & KolibriOS Team 2008-2019
1
//Leency, Veliant, Punk_Joker, PavelYakov & KolibriOS Team 2008-2020
2
//GNU GPL license.
2
//GNU GPL license.
Line 3... Line 3...
3
 
3
 
Line 4... Line 4...
4
// 70.5 - get volume info and label
4
// 70.5 - get volume info and label
Line 75... Line 75...
75
int toolbar_buttons_x[7]={9,46,85,134,167,203};
75
int toolbar_buttons_x[7]={9,46,85,134,167,203};
Line 76... Line 76...
76
 
76
 
77
bool active_about = false;
77
bool active_about = false;
78
bool active_settings = false;
78
bool active_settings = false;
79
bool _not_draw = false;
-
 
80
bool menu_call_mouse = false;
79
bool _not_draw = false;
81
bool exif_load = false;
80
bool exif_load = false;
Line 82... Line 81...
82
bool dir_at_fat16 = NULL;
81
bool dir_at_fat16 = NULL;
83
 
82
 
Line 108... Line 107...
108
dword eolite_ini_path[4096];
107
dword eolite_ini_path[4096];
109
_ini ini;
108
_ini ini;
Line 110... Line 109...
110
 
109
 
Line 111... Line 110...
111
char scroll_used=false;
110
char scroll_used=false;
Line 112... Line 111...
112
 
111
 
113
dword menu_stak,about_stak,properties_stak,settings_stak,copy_stak,delete_stak;
112
dword about_stak,properties_stak,settings_stak,copy_stak,delete_stak;
114
 
113
 
115
proc_info Form;
114
proc_info Form;
Line 259... Line 258...
259
						if (files.ProcessMouse(mouse.x, mouse.y)) List_ReDraw(); else {
258
						if (files.ProcessMouse(mouse.x, mouse.y)) List_ReDraw(); else {
260
							if (mouse.y - files.y / files.item_h + files.first == files.cur_y) Open(0);
259
							if (mouse.y - files.y / files.item_h + files.first == files.cur_y) Open(0);
261
						}
260
						}
262
					}
261
					}
263
					//file menu
262
					//file menu
264
					if (mouse.key&MOUSE_RIGHT)
263
					if (mouse.key&MOUSE_RIGHT) && (mouse.up)
265
					{
264
					{
266
						menu_call_mouse = 1;
-
 
267
						if (files.ProcessMouse(mouse.x, mouse.y)) List_ReDraw();
265
						if (files.ProcessMouse(mouse.x, mouse.y)) List_ReDraw();
268
						if (getElementSelectedFlag(files.cur_y) == false) selected_count = 0; //on redraw selection would be flashed, see [L001] 
266
						if (getElementSelectedFlag(files.cur_y) == false) selected_count = 0; //on redraw selection would be flashed, see [L001] 
269
						menu_stak = malloc(4096);
267
						EventShowListMenu();
270
						CreateThread(#FileMenu,menu_stak+4092);
-
 
271
						break;
268
						break;
272
					}
269
					}
273
				}
270
				}
Line 274... Line 271...
274
 
271
 
Line 500... Line 497...
500
								if (active_panel==1) active_panel=2; else active_panel=1;
497
								if (active_panel==1) active_panel=2; else active_panel=1;
501
								ChangeActivePanel();
498
								ChangeActivePanel();
502
								DrawFilePanels();
499
								DrawFilePanels();
503
								break;
500
								break;
504
						case SCAN_CODE_MENU:
501
						case SCAN_CODE_MENU:
505
								menu_call_mouse=0;
502
								mouse.x = files.x+15;
506
								menu_stak = malloc(4096);
503
								mouse.y = files.cur_y - files.first * files.item_h + files.y + 5;
507
								CreateThread(#FileMenu,menu_stak+4092);
504
								EventShowListMenu();
508
								break;
505
								break;
509
						case SCAN_CODE_DEL:
506
						case SCAN_CODE_DEL:
510
								Del_Form();
507
								Del_Form();
511
								break;
508
								break;
512
						case SCAN_CODE_INS:
509
						case SCAN_CODE_INS:
Line 524... Line 521...
524
				}                         
521
				}                         
525
			break;
522
			break;
526
			case evIPC:
523
			case evIPC:
527
			case evReDraw:
524
			case evReDraw:
528
				draw_window();
525
				draw_window();
529
				if (action_buf) 
526
				if (CheckActiveProcess(Form.ID)) && (GetMenuClick()) break;
530
				{
-
 
531
					if (action_buf==OPERATION_END)
527
				if (action_buf==OPERATION_END)
532
					{
528
				{
533
						FnProcess(5);
529
					FnProcess(5);
534
						if (copy_stak) SelectFileByName(#copy_to+strrchr(#copy_to,'/'));
530
					if (copy_stak) SelectFileByName(#copy_to+strrchr(#copy_to,'/'));
535
					}
-
 
536
					if (action_buf==100) Open(0);
-
 
537
					if (action_buf==201) ShowOpenWithDialog();
-
 
538
					if (action_buf==202) FnProcess(3); //F3
-
 
539
					if (action_buf==203) FnProcess(4); //F4
-
 
540
					if (action_buf==104) Copy(#file_path, NOCUT);
-
 
541
					if (action_buf==105) Copy(#file_path, CUT);
-
 
542
					if (action_buf==106) Paste();
-
 
543
					if (action_buf==207) FnProcess(2);
-
 
544
					if (action_buf==108) Del_Form();
-
 
545
					if (action_buf==109) FnProcess(5);
-
 
546
					if (action_buf==110) FnProcess(8);
-
 
547
					action_buf=0;
531
					action_buf=0;
548
				}
532
				}
549
			break;
533
			break;
550
			default:
534
			default:
551
				if (Form.status_window>2) break;
535
				if (Form.status_window>2) break;
552
				EventRefreshDisksAndFolders();
536
				EventRefreshDisksAndFolders();
553
		}
537
		}
Line 554... Line 538...
554
		
538
		
555
		if(cmd_free)
539
		if(cmd_free)
556
		{
-
 
557
			if(cmd_free==1)      menu_stak=free(menu_stak);
540
		{
558
			else if(cmd_free==2) about_stak=free(about_stak);
541
			if(cmd_free==2) about_stak=free(about_stak);
559
			else if(cmd_free==3) properties_stak=free(properties_stak);
542
			else if(cmd_free==3) properties_stak=free(properties_stak);
560
			else if(cmd_free==4) settings_stak=free(settings_stak);
543
			else if(cmd_free==4) settings_stak=free(settings_stak);
561
			else if(cmd_free==5) copy_stak=free(copy_stak);
544
			else if(cmd_free==5) copy_stak=free(copy_stak);
562
			else if(cmd_free==6) delete_stak=free(delete_stak);
545
			else if(cmd_free==6) delete_stak=free(delete_stak);