Subversion Repositories Kolibri OS

Rev

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

Rev 3467 Rev 3695
Line 1... Line 1...
1
//Leency & Veliant 2008-2013
1
//Leency & Veliant 2008-2013
2
//GNU GPL licence.
2
//GNU GPL licence.
Line 3... Line 3...
3
 
3
 
Line 4... Line 4...
4
//êîïèðîâàòü ÷åðåç ïîòîê
4
//êîïèðîâàòü ÷åðåç ïîòîê
5
 
5
 
6
//libraries
6
//libraries
7
#define MEMSIZE 0xA0000
7
#define MEMSIZE 0xA0000
Line 20... Line 20...
20
#include "imgs\left_p.txt"
20
#include "imgs\left_p.txt"
Line 21... Line 21...
21
 
21
 
Line 22... Line 22...
22
 
22
 
23
enum {ONLY_SHOW, WITH_REDRAW, ONLY_OPEN}; //OpenDir
23
enum {ONLY_SHOW, WITH_REDRAW, ONLY_OPEN}; //OpenDir
24
 
24
 
25
#define TITLE "Eolite File Manager v1.89"
25
#define TITLE "Eolite File Manager v1.90"
26
#define ABOUT_TITLE "Eolite v1.89"
26
#define ABOUT_TITLE "Eolite v1.90"
27
dword col_work    = 0xE4DFE1;
27
dword col_work    = 0xE4DFE1;
28
dword col_border  = 0x9098B0; //A0A0B8; //0x819FC5;
28
dword col_border  = 0x9098B0; //A0A0B8; //0x819FC5;
Line 57... Line 57...
57
 
57
 
58
edit_box edit2= {250,213,80,0xFFFFCC,0x94AECE,0xFFFFCC,0xffffff,0,248,#file_name,#mouse_dd,64,6,6};
58
edit_box edit2= {250,213,80,0xFFFFCC,0x94AECE,0xFFFFCC,0xffffff,0,248,#file_name,#mouse_dd,64,6,6};
59
PathShow_data PathShow = {0, 17,250, 6, 250, 0, 0, 0x0, 0xFFFfff, #path, #temp, 0};
59
PathShow_data PathShow = {0, 17,250, 6, 250, 0, 0, 0x0, 0xFFFfff, #path, #temp, 0};
Line -... Line 60...
-
 
60
PathShow_data FileShow = {0, 56,215, 6, 100, 0, 0, 0x0, 0xFFFfff, #file_name, #temp, 0};
60
PathShow_data FileShow = {0, 56,215, 6, 100, 0, 0, 0x0, 0xFFFfff, #file_name, #temp, 0};
61
 
61
 
-
 
62
#include "include\some_code.h"
62
#include "include\copypaste.h"
63
#include "include\about_dialog.h"
63
#include "include\some_code.h"
64
#include "include\sorting.h"
64
#include "include\sorting.h"
65
#include "include\icons_f.h"
65
#include "include\icons_f.h"
66
#include "include\ini.h"
66
#include "include\ini.h"
67
#include "include\left_panel.h"
67
#include "include\left_panel.h"
68
#include "include\history.h"
68
#include "include\history.h"
Line 69... Line 69...
69
#include "include\file_menu.h"
69
#include "include\file_menu.h"
70
#include "include\copypaste.h"
70
#include "include\about_dialog.h"
71
 
71
 
Line 82... Line 82...
82
	{
82
	{
83
		strcpy(#path, #param);
83
		strcpy(#path, #param);
84
		if (path[strlen(#path)-1]!='/') chrcat(#path, '/'); //add "/" to the end of the string
84
		if (path[strlen(#path)-1]!='/') chrcat(#path, '/'); //add "/" to the end of the string
85
	}
85
	}
86
	else
86
	else
-
 
87
	{
87
		strcpy(#path, "/rd/1/");		
88
		strcpy(#path, "/rd/1/");		
-
 
89
	}
88
	Open_Dir(#path,ONLY_OPEN);
90
	Open_Dir(#path,ONLY_OPEN);
89
	SetEventMask(0x27);
91
	SetEventMask(0x27);
90
	loop() switch(WaitEvent())
92
	loop() switch(WaitEvent())
91
	{
93
	{
92
		case evMouse:
94
		case evMouse:
Line 110... Line 112...
110
 
112
 
111
			//select/open file {
113
			//select/open file {
112
			if (!m.lkm) && (!m.pkm) && (can_select)
114
			if (!m.lkm) && (!m.pkm) && (can_select)
113
			{
115
			{
114
				can_select = 0;
116
				can_select = 0;
-
 
117
				if (m.y>=57)
115
				if (m.y<57) break;
118
				{
116
				id = m.y - 57 / files.line_h;
119
					id = m.y - 57 / files.line_h;
-
 
120
					if (id!=m_selected)
-
 
121
					{
-
 
122
						can_show=0;
-
 
123
						break;
-
 
124
					}
117
				if (id!=m_selected) {can_show=0; break;}
125
					if (files.current!=id)
-
 
126
						List_Current(id-files.current);
118
				if (files.current!=id) List_Current(id-files.current);
127
					else
-
 
128
						Open();
119
				else Open();
129
				}
120
			};
130
			};
Line 121... Line 131...
121
			// } select/open file
131
			// } select/open file
122
 
132
 
123
			//file menu {
133
			//file menu {
124
			if (!m.pkm) && (!m.lkm) && (can_show)
134
			if (!m.pkm) && (!m.lkm) && (can_show)
125
			{
135
			{
-
 
136
				can_show = 0;
126
				can_show = 0;
137
				if (m.y>=57)
127
				if (m.y<57) break;
138
				{
-
 
139
					SwitchToAnotherThread();
128
				SwitchToAnotherThread();
140
					CreateThread(#FileMenu,#menu_stak);
129
				CreateThread(#FileMenu,#menu_stak);
141
				}
130
				break;
142
				break;
Line 131... Line -...
131
			}
-
 
132
			// } file menu
143
			}
133
 
144
			// } file menu
134
 
145
 
135
			if (m.vert)
146
			if (m.vert)
136
			{
147
			{
Line 442... Line 453...
442
 
453
 
443
 
454
 
444
void List_ReDraw()
455
void List_ReDraw()
445
{
456
{
446
	int paint_y;
457
	int paint_y;
447
	//åñëè ìû â êîíöå ñïèñêà ôàéëîâ ðàçâåðí¸ì îêíî ïîÿâÿòüñÿ ïóñòÿå áåëûå êíîïêè
458
	//åñëè ìû â êîíöå ñïèñêà ôàéëîâ ðàçâåðí¸ì îêíî ïîÿâÿòüñÿ ïóñòÿå áåëûå êíîïêè
448
	//ýòî åñëè âûäåëåíèå ïîñëå ñõëîïûâàíèÿ îêíà çà êàäðîì
459
	//ýòî åñëè âûäåëåíèå ïîñëå ñõëîïûâàíèÿ îêíà çà êàäðîì
Line 449... Line 460...
449
	if (files.count-files.firstfiles.visible-1)
460
	if (files.count-files.firstfiles.visible-1)
450
	{ files.first=files.count-files.visible; files.current=files.visible-1; }
461
	{ files.first=files.count-files.visible; files.current=files.visible-1; }