Subversion Repositories Kolibri OS

Rev

Rev 7425 | Rev 7593 | Go to most recent revision | Only display areas with differences | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 7425 Rev 7506
1
#ifdef LANG_RUS
1
#ifdef LANG_RUS
2
	?define WINDOW_TITLE_PROPERTIES "‘¢®©á⢠"
2
	?define WINDOW_TITLE_PROPERTIES "‘¢®©á⢠"
3
	?define BTN_CLOSE "‡ ªàëâì"
3
	?define BTN_CLOSE "‡ ªàëâì"
4
	?define BTN_APPLY "à¨¬¥­¨âì"
4
	?define BTN_APPLY "à¨¬¥­¨âì"
5
	?define QUEST_1 "à¨¬¥­¨âì ª® ¢á¥¬ ¢«®¦¥­­ë¬"
5
	?define QUEST_1 "à¨¬¥­¨âì ª® ¢á¥¬ ¢«®¦¥­­ë¬"
6
	?define QUEST_2 "ä ©« ¬ ¨ ¯ ¯ª ¬?"
6
	?define QUEST_2 "ä ©« ¬ ¨ ¯ ¯ª ¬?"
7
	?define PR_T_NAME "ˆ¬ï:"
7
	?define PR_T_NAME "ˆ¬ï:"
8
	?define PR_T_DEST " á¯®«®¦¥­¨¥:"
8
	?define PR_T_DEST " á¯®«®¦¥­¨¥:"
9
	?define PR_T_SIZE " §¬¥à:"
9
	?define PR_T_SIZE " §¬¥à:"
10
	?define CREATED_OPENED_MODIFIED "‘®§¤ ­:\nŽâªàëâ:\nˆ§¬¥­¥­:"
10
	?define CREATED_OPENED_MODIFIED "‘®§¤ ­:\nŽâªàëâ:\nˆ§¬¥­¥­:"
11
	?define SET_6 "” ©«®¢: "
11
	?define SET_6 "” ©«®¢: "
12
	?define SET_7 "  ¯®ª: "
12
	?define SET_7 "  ¯®ª: "
13
	?define PR_T_CONTAINS "‘®¤¥à¦¨â: "
13
	?define PR_T_CONTAINS "‘®¤¥à¦¨â: "
14
	?define FLAGS " €ââਡãâë "
14
	?define FLAGS " €ââਡãâë "
15
	?define PR_T_HIDDEN "‘ªàëâë©"
15
	?define PR_T_HIDDEN "‘ªàëâë©"
16
	?define PR_T_SYSTEM "‘¨á⥬­ë©"
16
	?define PR_T_SYSTEM "‘¨á⥬­ë©"
17
	?define PR_T_ONLY_READ "’®«ìª® ç⥭¨¥"
17
	?define PR_T_ONLY_READ "’®«ìª® ç⥭¨¥"
18
	?define SET_BYTE_LANG "¡ ©â"
18
	?define SET_BYTE_LANG "¡ ©â"
19
#else // Apply to all subfolders
19
#else // Apply to all subfolders
20
	?define WINDOW_TITLE_PROPERTIES "Properties"
20
	?define WINDOW_TITLE_PROPERTIES "Properties"
21
	?define BTN_CLOSE "Close"
21
	?define BTN_CLOSE "Close"
22
	?define BTN_APPLY "Apply"
22
	?define BTN_APPLY "Apply"
23
	?define QUEST_1 "Apply to all subfolders"
23
	?define QUEST_1 "Apply to all subfolders"
24
	?define QUEST_2 "files and Folders?"
24
	?define QUEST_2 "files and Folders?"
25
	?define PR_T_NAME "Name:"
25
	?define PR_T_NAME "Name:"
26
	?define PR_T_DEST "Destination:"
26
	?define PR_T_DEST "Destination:"
27
	?define PR_T_SIZE "Size:"
27
	?define PR_T_SIZE "Size:"
28
	?define CREATED_OPENED_MODIFIED "Created:\nOpened:\nModified:"
28
	?define CREATED_OPENED_MODIFIED "Created:\nOpened:\nModified:"
29
	?define SET_6 "Files: "
29
	?define SET_6 "Files: "
30
	?define SET_7 " Folders: "
30
	?define SET_7 " Folders: "
31
	?define PR_T_CONTAINS "Contains: "
31
	?define PR_T_CONTAINS "Contains: "
32
	?define FLAGS " Attributes "
32
	?define FLAGS " Attributes "
33
	?define PR_T_HIDDEN "Hidden"
33
	?define PR_T_HIDDEN "Hidden"
34
	?define PR_T_SYSTEM "System"
34
	?define PR_T_SYSTEM "System"
35
	?define PR_T_ONLY_READ "Read-only"
35
	?define PR_T_ONLY_READ "Read-only"
36
	?define SET_BYTE_LANG "byte"
36
	?define SET_BYTE_LANG "byte"
37
#endif
37
#endif
38
 
38
 
39
char path_to_file[4096];
39
char path_to_file[4096];
40
char file_name2[4096];
40
char file_name2[4096];
41
edit_box file_name_ed = {230,59,32,0xffffff,0x94AECE,0xFFFfff,0xffffff,0x10000000,sizeof(file_name2),#file_name2,NULL, 1000000000000000b,2,2};
41
edit_box file_name_ed = {230,59,32,0xffffff,0x94AECE,0xFFFfff,0xffffff,0x10000000,sizeof(file_name2)-2,#file_name2,NULL, 0b,2,2};
42
edit_box path_to_file_ed = {160,120,79,0xffffff,0x94AECE,0xFFFfff,0xffffff,2,sizeof(path_to_file),#path_to_file,NULL, 1000000000000000b,2,2};
42
edit_box path_to_file_ed = {160,120,79,0xffffff,0x94AECE,0xFFFfff,0xffffff,2,sizeof(path_to_file)-2,#path_to_file,NULL, 0b,2,2};
43
 
43
 
44
BDVK file_info_general;
44
BDVK file_info_general;
45
BDVK file_info_dirsize;
45
BDVK file_info_dirsize;
46
 
46
 
47
bool quest_active;
47
bool quest_active;
48
 
48
 
49
_dir_size more_files_count;
49
_dir_size more_files_count;
50
 
50
 
51
checkbox ch_read_only = { PR_T_ONLY_READ, NULL };
51
checkbox ch_read_only = { PR_T_ONLY_READ, NULL };
52
checkbox ch_hidden = { PR_T_HIDDEN, NULL };
52
checkbox ch_hidden = { PR_T_HIDDEN, NULL };
53
checkbox ch_system = { PR_T_SYSTEM, NULL };
53
checkbox ch_system = { PR_T_SYSTEM, NULL };
54
 
54
 
55
void SetPropertiesFile(dword cur_file, bdvk_pointer)
55
void SetPropertiesFile(dword cur_file, bdvk_pointer)
56
{
56
{
57
	GetFileInfo(cur_file, bdvk_pointer);
57
	GetFileInfo(cur_file, bdvk_pointer);
58
	ESI = bdvk_pointer;
58
	ESI = bdvk_pointer;
59
	ESI.BDVK.readonly = ch_read_only.checked;
59
	ESI.BDVK.readonly = ch_read_only.checked;
60
	ESI.BDVK.hidden = ch_hidden.checked;
60
	ESI.BDVK.hidden = ch_hidden.checked;
61
	ESI.BDVK.system = ch_system.checked;
61
	ESI.BDVK.system = ch_system.checked;
62
	SetFileInfo(cur_file, bdvk_pointer);
62
	SetFileInfo(cur_file, bdvk_pointer);
63
}
63
}
64
 
64
 
65
void SetPropertiesDir(dword way)
65
void SetPropertiesDir(dword way)
66
{
66
{
67
	dword dirbuf, fcount, i, filename;
67
	dword dirbuf, fcount, i, filename;
68
	dword cur_file;
68
	dword cur_file;
69
	if (dir_exists(way))
69
	if (dir_exists(way))
70
	{
70
	{
71
		cur_file = malloc(4096);
71
		cur_file = malloc(4096);
72
		GetDir(#dirbuf, #fcount, way, DIRS_ONLYREAL);
72
		GetDir(#dirbuf, #fcount, way, DIRS_ONLYREAL);
73
		for (i=0; i
73
		for (i=0; i
74
		{
74
		{
75
			filename = i*304+dirbuf+72;
75
			filename = i*304+dirbuf+72;
76
			strcpy(cur_file, way);
76
			strcpy(cur_file, way);
77
			chrcat(cur_file, '/');
77
			chrcat(cur_file, '/');
78
			strcat(cur_file, filename);
78
			strcat(cur_file, filename);
79
			if ( TestBit(ESDWORD[filename-40], 4) )
79
			if ( TestBit(ESDWORD[filename-40], 4) )
80
			{
80
			{
81
				SetPropertiesDir(cur_file);
81
				SetPropertiesDir(cur_file);
82
			}
82
			}
83
			SetPropertiesFile(cur_file, #file_info_dirsize);
83
			SetPropertiesFile(cur_file, #file_info_dirsize);
84
		}
84
		}
85
		free(cur_file);
85
		free(cur_file);
86
	}
86
	}
87
}
87
}
88
 
88
 
89
void SetProperties(byte prop)
89
void SetProperties(byte prop)
90
{
90
{
91
	dword cur_file;
91
	dword cur_file;
92
	dword i;
92
	dword i;
93
 
93
 
94
	if (prop==1) || (prop==2)
94
	if (prop==1) || (prop==2)
95
	{
95
	{
96
		if (selected_count)
96
		if (selected_count)
97
		{
97
		{
98
			cur_file = malloc(4096);
98
			cur_file = malloc(4096);
99
			for (i=0; i
99
			for (i=0; i
100
			{
100
			{
101
				if (getElementSelectedFlag(i) == true) 
101
				if (getElementSelectedFlag(i) == true) 
102
				{
102
				{
103
					strcpy(cur_file, #path);
103
					strcpy(cur_file, #path);
104
					strcat(cur_file, file_mas[i]*304+buf+72);
104
					strcat(cur_file, file_mas[i]*304+buf+72);
105
					SetPropertiesDir(cur_file);
105
					SetPropertiesDir(cur_file);
106
					if (prop==2)
106
					if (prop==2)
107
					{
107
					{
108
						if (dir_exists(cur_file))
108
						if (dir_exists(cur_file))
109
						{
109
						{
110
							SetPropertiesDir(cur_file);
110
							SetPropertiesDir(cur_file);
111
						}
111
						}
112
					}
112
					}
113
				}
113
				}
114
			}
114
			}
115
			free(cur_file);
115
			free(cur_file);
116
		}
116
		}
117
		else
117
		else
118
		{
118
		{
119
			SetPropertiesFile(#file_path, #file_info_general);
119
			SetPropertiesFile(#file_path, #file_info_general);
120
			if (prop==2) SetPropertiesDir(#file_path);
120
			if (prop==2) SetPropertiesDir(#file_path);
121
		}
121
		}
122
		quest_active = 0;
122
		quest_active = 0;
123
		DrawPropertiesWindow();
123
		DrawPropertiesWindow();
124
	}
124
	}
125
	else
125
	else
126
	{
126
	{
127
		SetPropertiesFile(#file_path, #file_info_general);
127
		SetPropertiesFile(#file_path, #file_info_general);
128
	}
128
	}
129
	cmd_free=3;
129
	cmd_free=3;
130
	_not_draw = true;
130
	_not_draw = true;
131
	Open_Dir(#path,WITH_REDRAW);
131
	Open_Dir(#path,WITH_REDRAW);
132
	_not_draw = false;
132
	_not_draw = false;
133
	EventRedrawWindow(Form.left,Form.top);
133
	EventRedrawWindow(Form.left,Form.top);
134
	ExitProcess();
134
	ExitProcess();
135
}
135
}
136
 
136
 
137
void ShowConfirmQuestionPopin()
137
void ShowConfirmQuestionPopin()
138
{
138
{
139
	quest_active = 1;
139
	quest_active = 1;
140
	DrawPopup(15,80,250,90,1,system.color.work, system.color.work_graph);
140
	DrawPopup(15,80,250,90,1,system.color.work, system.color.work_graph);
141
	WriteText(35, 102, 0x90, 0x000000, QUEST_1);
141
	WriteText(35, 102, 0x90, 0x000000, QUEST_1);
142
	WriteText(65, 117, 0x90, 0x000000, QUEST_2);
142
	WriteText(65, 117, 0x90, 0x000000, QUEST_2);
143
	DrawStandartCaptButton(62,138,301,T_YES);
143
	DrawStandartCaptButton(62,138,301,T_YES);
144
	DrawStandartCaptButton(155,138,302,T_NO);
144
	DrawStandartCaptButton(155,138,302,T_NO);
145
}
145
}
146
 
146
 
147
void GetSizeMoreFiles(dword way)
147
void GetSizeMoreFiles(dword way)
148
{
148
{
149
	char cur_file[4096];
149
	char cur_file[4096];
150
	dword i;
150
	dword i;
151
	
151
	
152
	for (i=0; i
152
	for (i=0; i
153
	{
153
	{
154
		if (getElementSelectedFlag(i) == true) 
154
		if (getElementSelectedFlag(i) == true) 
155
		{
155
		{
156
			sprintf(#cur_file,"%s/%s",way,file_mas[i]*304+buf+72);
156
			sprintf(#cur_file,"%s/%s",way,file_mas[i]*304+buf+72);
157
			if (TestBit(ESDWORD[file_mas[i]*304+buf+32], 4) )
157
			if (TestBit(ESDWORD[file_mas[i]*304+buf+32], 4) )
158
			{
158
			{
159
				more_files_count.calculate_loop(#cur_file);
159
				more_files_count.calculate_loop(#cur_file);
160
				more_files_count.folders++;
160
				more_files_count.folders++;
161
			}
161
			}
162
			else
162
			else
163
			{
163
			{
164
				GetFileInfo(#cur_file, #file_info_dirsize);
164
				GetFileInfo(#cur_file, #file_info_dirsize);
165
				more_files_count.bytes += file_info_dirsize.sizelo;
165
				more_files_count.bytes += file_info_dirsize.sizelo;
166
				more_files_count.files++;
166
				more_files_count.files++;
167
			}
167
			}
168
		}
168
		}
169
	}  
169
	}  
170
}
170
}
171
 
171
 
172
void properties_dialog()
172
void properties_dialog()
173
{
173
{
174
	int id;
174
	int id;
175
	
175
	
176
	if (selected_count)
176
	if (selected_count)
177
	{
177
	{
178
		more_files_count.get(NULL);
178
		more_files_count.get(NULL);
179
		GetSizeMoreFiles(#path);
179
		GetSizeMoreFiles(#path);
180
		ch_read_only.checked = 0;
180
		ch_read_only.checked = 0;
181
		ch_hidden.checked = 0;
181
		ch_hidden.checked = 0;
182
		ch_system.checked = 0;
182
		ch_system.checked = 0;
183
	}
183
	}
184
	else
184
	else
185
	{
185
	{
186
		GetFileInfo(#file_path, #file_info_general);
186
		GetFileInfo(#file_path, #file_info_general);
187
		strcpy(#file_name2, #file_name);
187
		strcpy(#file_name2, #file_name);
188
		file_name_ed.size = strlen(#file_name2);   
188
		EditBox_UpdateText(#file_name_ed, 0);
189
		if(itdir) dir_size.get(#file_path);
189
		if(itdir) dir_size.get(#file_path);
190
		ch_read_only.checked = file_info_general.readonly;
190
		ch_read_only.checked = file_info_general.readonly;
191
		ch_hidden.checked = file_info_general.hidden;
191
		ch_hidden.checked = file_info_general.hidden;
192
		ch_system.checked = file_info_general.system;
192
		ch_system.checked = file_info_general.system;
193
	}
193
	}
194
	strcpy(#path_to_file, #path);
194
	strcpy(#path_to_file, #path);
195
	path_to_file_ed.size = strlen(#path_to_file);
195
	path_to_file_ed.size = strlen(#path_to_file);
196
	
196
	
197
	SetEventMask(EVM_REDRAW + EVM_KEY + EVM_BUTTON + EVM_MOUSE + EVM_MOUSE_FILTER);
197
	SetEventMask(EVM_REDRAW + EVM_KEY + EVM_BUTTON + EVM_MOUSE + EVM_MOUSE_FILTER);
198
	loop() switch(WaitEvent())
198
	loop() switch(WaitEvent())
199
	{
199
	{
200
		case evButton: 
200
		case evButton: 
201
				id=GetButtonID();
201
				id=GetButtonID();
202
				ch_read_only.click(id);
202
				ch_read_only.click(id);
203
				ch_hidden.click(id);
203
				ch_hidden.click(id);
204
				ch_system.click(id);
204
				ch_system.click(id);
205
				if (quest_active)
205
				if (quest_active)
206
				{
206
				{
207
					IF (id==301) SetProperties(2);
207
					IF (id==301) SetProperties(2);
208
					IF (id==302) SetProperties(1);
208
					IF (id==302) SetProperties(1);
209
					quest_active=false;
209
					quest_active=false;
210
					break;
210
					break;
211
				}
211
				}
212
				if (id==1) || (id==10)
212
				if (id==1) || (id==10)
213
				{
213
				{
214
					cmd_free=3;
214
					cmd_free=3;
215
					ExitProcess();
215
					ExitProcess();
216
				}
216
				}
217
				IF (id==11) 
217
				IF (id==11) 
218
				{
218
				{
219
					if (selected_count) || (itdir)
219
					if (selected_count) || (itdir)
220
					{
220
					{
221
						ShowConfirmQuestionPopin();
221
						ShowConfirmQuestionPopin();
222
					}
222
					}
223
					else 
223
					else 
224
					{
224
					{
225
						SetProperties(0);
225
						SetProperties(0);
226
					}
226
					}
227
					break;
227
					break;
228
				}
228
				}
229
				break;
229
				break;
230
				
230
				
231
		case evMouse:
231
		case evMouse:
232
				edit_box_mouse stdcall (#file_name_ed);
232
				edit_box_mouse stdcall (#file_name_ed);
233
				edit_box_mouse stdcall (#path_to_file_ed);
233
				edit_box_mouse stdcall (#path_to_file_ed);
234
				break;
234
				break;
235
			
235
			
236
		case evKey:
236
		case evKey:
237
				GetKeys();
237
				GetKeys();
238
				
238
				
239
				if (quest_active)
239
				if (quest_active)
240
				{
240
				{
241
					IF (key_scancode==SCAN_CODE_ENTER) SetProperties(2);
241
					IF (key_scancode==SCAN_CODE_ENTER) SetProperties(2);
242
					IF (key_scancode==SCAN_CODE_ESC) SetProperties(1);
242
					IF (key_scancode==SCAN_CODE_ESC) SetProperties(1);
243
					quest_active=false;
243
					quest_active=false;
244
					break;
244
					break;
245
				}
245
				}
246
				if (key_scancode==SCAN_CODE_ESC)
246
				if (key_scancode==SCAN_CODE_ESC)
247
				{
247
				{
248
					cmd_free=3;
248
					cmd_free=3;
249
					ExitProcess();
249
					ExitProcess();
250
				}
250
				}
251
				if (key_scancode==SCAN_CODE_ENTER)
251
				if (key_scancode==SCAN_CODE_ENTER)
252
				{
252
				{
253
					if (selected_count) || (itdir)
253
					if (selected_count) || (itdir)
254
					{
254
					{
255
						ShowConfirmQuestionPopin();
255
						ShowConfirmQuestionPopin();
256
					}
256
					}
257
					else 
257
					else 
258
					{
258
					{
259
						SetProperties(0);
259
						SetProperties(0);
260
					}
260
					}
261
					break;
261
					break;
262
				}
262
				}
263
				edit_box_key stdcall(#file_name_ed);
263
				edit_box_key stdcall(#file_name_ed);
264
				edit_box_key stdcall(#path_to_file_ed);
264
				edit_box_key stdcall(#path_to_file_ed);
265
				break;
265
				break;
266
				
266
				
267
		case evReDraw:
267
		case evReDraw:
268
				DrawPropertiesWindow();
268
				DrawPropertiesWindow();
269
	}
269
	}
270
}
270
}
271
 
271
 
272
void DrawPropertiesWindow()
272
void DrawPropertiesWindow()
273
{
273
{
274
	proc_info settings_form;
274
	proc_info settings_form;
275
	char element_size_label[32];
275
	char element_size_label[32];
276
	char folder_info[200];
276
	char folder_info[200];
277
	dword ext1;
277
	dword ext1;
278
	dword element_size;
278
	dword element_size;
279
	incn y;
279
	incn y;
280
	char temp_path[sizeof(file_path)];
280
	char temp_path[sizeof(file_path)];
281
	DefineAndDrawWindow(Form.left + 150,150,315,360+skin_height,0x34,system.color.work,WINDOW_TITLE_PROPERTIES,0);
281
	DefineAndDrawWindow(Form.left + 150,150,315,360+skin_height,0x34,system.color.work,WINDOW_TITLE_PROPERTIES,0);
282
	GetProcessInfo(#settings_form, SelfInfo);
282
	GetProcessInfo(#settings_form, SelfInfo);
283
 
283
 
284
	DrawStandartCaptButton(settings_form.cwidth - 96, settings_form.cheight-34, 10, BTN_CLOSE);
284
	DrawStandartCaptButton(settings_form.cwidth - 96, settings_form.cheight-34, 10, BTN_CLOSE);
285
	DrawStandartCaptButton(settings_form.cwidth -208, settings_form.cheight-34, 11, BTN_APPLY);
285
	DrawStandartCaptButton(settings_form.cwidth -208, settings_form.cheight-34, 11, BTN_APPLY);
286
	
286
	
287
	WriteText(10, 78, 0x90, system.color.work_text, PR_T_DEST);
287
	WriteText(10, 78, 0x90, system.color.work_text, PR_T_DEST);
288
	edit_box_draw stdcall (#path_to_file_ed);
288
	edit_box_draw stdcall (#path_to_file_ed);
289
 
289
 
290
	WriteText(10, 97, 0x90, system.color.work_text, PR_T_SIZE);
290
	WriteText(10, 97, 0x90, system.color.work_text, PR_T_SIZE);
291
	
291
	
292
	if (selected_count)
292
	if (selected_count)
293
	{
293
	{
294
		PropertiesDrawIcon(NULL, "");
294
		PropertiesDrawIcon(NULL, "");
295
		sprintf(#folder_info,"%s%d%s%d",SET_6,more_files_count.files,SET_7,more_files_count.folders);
295
		sprintf(#folder_info,"%s%d%s%d",SET_6,more_files_count.files,SET_7,more_files_count.folders);
296
		WriteText(file_name_ed.left+4, 30, 0x90, system.color.work_text, #folder_info);
296
		WriteText(file_name_ed.left+4, 30, 0x90, system.color.work_text, #folder_info);
297
		sprintf(#element_size_label,"%s (%d %s)",ConvertSize64(more_files_count.bytes, NULL),more_files_count.bytes,SET_BYTE_LANG);
297
		sprintf(#element_size_label,"%s (%d %s)",ConvertSize64(more_files_count.bytes, NULL),more_files_count.bytes,SET_BYTE_LANG);
298
		WriteText(120, 97, 0x90, system.color.work_text, #element_size_label);
298
		WriteText(120, 97, 0x90, system.color.work_text, #element_size_label);
299
	}
299
	}
300
	else
300
	else
301
	{
301
	{
302
		if ( file_info_general.isfolder )
302
		if ( file_info_general.isfolder )
303
				PropertiesDrawIcon(NULL, "");
303
				PropertiesDrawIcon(NULL, "");
304
		else {
304
		else {
305
			sprintf(#temp_path,"%s/%s",#path,#file_name2);
305
			sprintf(#temp_path,"%s/%s",#path,#file_name2);
306
			ext1 = strrchr(#file_name2,'.');
306
			ext1 = strrchr(#file_name2,'.');
307
			if (ext1) ext1 += #file_name2;
307
			if (ext1) ext1 += #file_name2;
308
			PropertiesDrawIcon(#temp_path, ext1);
308
			PropertiesDrawIcon(#temp_path, ext1);
309
		}
309
		}
310
		WriteText(file_name_ed.left, file_name_ed.top-15, 0x80, system.color.work_text, PR_T_NAME);
310
		WriteText(file_name_ed.left, file_name_ed.top-15, 0x80, system.color.work_text, PR_T_NAME);
311
		DrawEditBox(#file_name_ed);
311
		DrawEditBox(#file_name_ed);
312
		
312
		
313
		if (!itdir) element_size = file_info_general.sizelo;
313
		if (!itdir) element_size = file_info_general.sizelo;
314
		else
314
		else
315
		{
315
		{
316
			WriteText(10,116, 0x90, system.color.work_text, PR_T_CONTAINS);                              
316
			WriteText(10,116, 0x90, system.color.work_text, PR_T_CONTAINS);                              
317
			sprintf(#folder_info,"%s%d%s%d",SET_6,dir_size.files,SET_7,dir_size.folders);
317
			sprintf(#folder_info,"%s%d%s%d",SET_6,dir_size.files,SET_7,dir_size.folders);
318
			WriteText(120, 116, 0x90, system.color.work_text, #folder_info);
318
			WriteText(120, 116, 0x90, system.color.work_text, #folder_info);
319
			element_size = dir_size.bytes;
319
			element_size = dir_size.bytes;
320
		}
320
		}
321
		WriteTextLines(10,  136, 0x90, system.color.work_text, CREATED_OPENED_MODIFIED, 20);
321
		WriteTextLines(10,  136, 0x90, system.color.work_text, CREATED_OPENED_MODIFIED, 20);
322
		DrawDate(120,  136, system.color.work_text, #file_info_general.datecreate);
322
		DrawDate(120,  136, system.color.work_text, #file_info_general.datecreate);
323
		DrawDate(120, 156, system.color.work_text, #file_info_general.datelastaccess);
323
		DrawDate(120, 156, system.color.work_text, #file_info_general.datelastaccess);
324
		DrawDate(120, 176, system.color.work_text, #file_info_general.datelastedit);
324
		DrawDate(120, 176, system.color.work_text, #file_info_general.datelastedit);
325
 
325
 
326
		sprintf(#element_size_label,"%s (%d %s)",ConvertSize64(element_size, NULL),element_size,SET_BYTE_LANG);
326
		sprintf(#element_size_label,"%s (%d %s)",ConvertSize64(element_size, NULL),element_size,SET_BYTE_LANG);
327
		WriteText(120, 99, 0x90, system.color.work_text, #element_size_label);
327
		WriteText(120, 99, 0x90, system.color.work_text, #element_size_label);
328
	}
328
	}
329
	DrawFrame(10, 212, -10*2 + settings_form.cwidth - 2, 92, FLAGS);
329
	DrawFrame(10, 212, -10*2 + settings_form.cwidth - 2, 92, FLAGS);
330
	y.n = 212; //212 => attributes_frame.y
330
	y.n = 212; //212 => attributes_frame.y
331
	ch_read_only.draw(24, y.inc(18));
331
	ch_read_only.draw(24, y.inc(18));
332
	ch_hidden.draw(24, y.inc(24));
332
	ch_hidden.draw(24, y.inc(24));
333
	ch_system.draw(24, y.inc(24));
333
	ch_system.draw(24, y.inc(24));
334
}
334
}
335
 
335
 
336
void PropertiesDrawIcon(dword file_path, extension)
336
void PropertiesDrawIcon(dword file_path, extension)
337
{
337
{
338
	#define ICON_PADDING 11
338
	#define ICON_PADDING 11
339
	DrawBar(20-ICON_PADDING, 30-ICON_PADDING-1, ICON_PADDING*2+16, ICON_PADDING*2+16, 0xFFFfff);
339
	DrawBar(20-ICON_PADDING, 30-ICON_PADDING-1, ICON_PADDING*2+16, ICON_PADDING*2+16, 0xFFFfff);
340
	DrawIconByExtension(file_path, extension, -icon_size/2+28, -icon_size/2+38, 0xFFFfff);
340
	DrawIconByExtension(file_path, extension, -icon_size/2+28, -icon_size/2+38, 0xFFFfff);
341
}
341
}