Subversion Repositories Kolibri OS

Rev

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

Rev 7374 Rev 7424
Line 1... Line 1...
1
/*
1
/*
2
SOFTWARE CENTER v2.8
2
SOFTWARE CENTER v2.81
3
*/
3
*/
Line 4... Line 4...
4
 
4
 
5
#define MEMSIZE 4096 * 15
5
#define MEMSIZE 4096 * 15
6
#include "..\lib\strings.h" 
6
#include "..\lib\strings.h" 
Line 116... Line 116...
116
	int tmp,
116
	int tmp,
117
		icon_id,
117
		icon_id,
118
		icon_char_pos;
118
		icon_char_pos;
Line 119... Line 119...
119
 
119
 
120
	//do not show items located in /kolibrios/ if this directory not mounted
120
	//do not show items located in /kolibrios/ if this directory not mounted
-
 
121
	if (!strncmp(key_value, "/kolibrios/", 11)) || (!strncmp(key_value, "/k/", 3))
Line 121... Line 122...
121
	if (!strncmp(key_value, "/kolibrios/", 11)) && (!kolibrios_mounted) return true;
122
		if (!kolibrios_mounted) return true;
122
 
123
 
123
	if (col==list.column_max) {
124
	if (col==list.column_max) {
124
		row++;
125
		row++;
Line 176... Line 177...
176
	kfont.WriteIntoWindowCenter(0,5, Form.cwidth, list.y, system.color.work, system.color.work_text, 16, #window_title);
177
	kfont.WriteIntoWindowCenter(0,5, Form.cwidth, list.y, system.color.work, system.color.work_text, 16, #window_title);
177
}
178
}
Line 178... Line 179...
178
 
179
 
179
void EventRunApp(dword appid)
180
void EventRunApp(dword appid)
-
 
181
{
180
{
182
	char run_app_path[4096]=0;
181
	dword app_path = app_path_collection.get(appid);
-
 
182
	
183
	dword app_path = app_path_collection.get(appid);
183
	dword param_pos = strchr(app_path, '|');
184
	dword param_pos = strchr(app_path, '|');
184
	if (param_pos) {
185
	if (param_pos) {
185
		ESBYTE[param_pos] = NULL;
186
		ESBYTE[param_pos] = NULL;
186
		param_pos++;
187
		param_pos++;
Line -... Line 188...
-
 
188
	}
-
 
189
 
-
 
190
	// the next block is created to save some space in ramdisk{
-
 
191
	//
-
 
192
	// convert relative path to absolute      "calc"    => "/sys/calc"
-
 
193
	// convert short kolibrios path to full   "/k/calc" => "/kolibrios/calc"
-
 
194
	// other copy => as is
-
 
195
	if (ESBYTE[app_path]!='/') {
-
 
196
		strcpy(#run_app_path, "/sys/");
-
 
197
	}
-
 
198
	else if (!strncmp(app_path, "/k/",3)) {
-
 
199
		strcpy(#run_app_path, "/kolibrios/");
-
 
200
		app_path+=3;
-
 
201
	}
-
 
202
	strcat(#run_app_path, app_path);
187
	}
203
	// }end
188
 
204
 
189
	if (file_exists(app_path))
205
	if (file_exists(#run_app_path))
190
	{
206
	{
191
		io.run(app_path, param_pos); //0 or offset
207
		io.run(#run_app_path, param_pos); //0 or offset
192
		if (param_pos) ESBYTE[param_pos - 1] = '|';
208
		if (param_pos) ESBYTE[param_pos - 1] = '|';
193
	}
209
	}
194
	else
210
	else