Subversion Repositories Kolibri OS

Rev

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

Rev 8697 Rev 8839
Line 68... Line 68...
68
{
68
{
69
	autoclose.click(id);
69
	autoclose.click(id);
70
	if (id==BTN_EXIT) { StopDownloading(); ExitProcess(); }
70
	if (id==BTN_EXIT) { StopDownloading(); ExitProcess(); }
71
	if (id==BTN_START) StartDownloading();
71
	if (id==BTN_START) StartDownloading();
72
	if (id==BTN_STOP) StopDownloading();
72
	if (id==BTN_STOP) StopDownloading();
73
	if (id==BTN_DIR) RunProgram("/sys/File managers/Eolite", #filepath);
73
	if (id==BTN_DIR) { RunProgram("/sys/File managers/Eolite", #filepath); ExitProcess(); }
74
	if (id==BTN_RUN) RunProgram("/sys/@open", #filepath);
74
	if (id==BTN_RUN) { RunProgram("/sys/@open", #filepath); ExitProcess(); }
75
}
75
}
Line 76... Line 76...
76
 
76
 
77
void ProcessKeyPress()
77
void ProcessKeyPress()
78
{
78
{
Line 234... Line 234...
234
	} else {
234
	} else {
235
		miniprintf(#notify_message, FILE_NOT_SAVED, #filepath);
235
		miniprintf(#notify_message, FILE_NOT_SAVED, #filepath);
236
	}
236
	}
Line 237... Line 237...
237
	
237
 
-
 
238
	if (!exit_param) notify(#notify_message);
-
 
239
 
-
 
240
	if (!strcmpi(#filepath+strlen(#filepath)-4, ".zip"))
-
 
241
	|| (!strcmpi(#filepath+strlen(#filepath)-3, ".7z")) {
-
 
242
		Unarchive(#filepath);
-
 
243
	}
238
	if (!exit_param) notify(#notify_message);
244
 
239
	if (open_file) ProcessButtonClick(BTN_RUN);
245
	if (open_file) ProcessButtonClick(BTN_RUN);
240
	if (autoclose.checked) ExitProcess();
246
	if (autoclose.checked) ExitProcess();
Line -... Line 247...
-
 
247
}
-
 
248
 
-
 
249
void Unarchive(dword _arc)
-
 
250
{
-
 
251
	char folder_name[4096];
-
 
252
	strcpy(#folder_name, "/tmp0/1/Downloads/");
-
 
253
	strcpy(#folder_name, #filepath+strrchr(#filepath, '/'));
-
 
254
	folder_name[strlen(#folder_name)-4] = '\0';
-
 
255
	CreateDir(#folder_name);
-
 
256
 
-
 
257
	strcpy(#param, "-o \"");
-
 
258
	strcat(#param, #folder_name);
-
 
259
	strcat(#param, "\" -h \"");
-
 
260
	strcat(#param, #filepath);
-
 
261
	chrcat(#param, '\"');
-
 
262
	RunProgram("/sys/unz", #param);	
Line 241... Line 263...
241
}
263
}
242
 
264
 
243
 
265
 
244
/*
266
/*