Subversion Repositories Kolibri OS

Rev

Rev 1665 | Rev 1673 | Go to most recent revision | Details | Compare with Previous | Last modification | View Log | RSS feed

Rev Author Line No. Line
1665 Nasarus 1
 
2
#include "string.h"
3
4
 
5
 
6
extern char KOL_PARAM[256];
7
extern char KOL_DIR[256];
8
9
 
10
 
11
{
12
asm ("int $0x40"::"a"(-1));
13
}
14
15
 
16
 
17
{
18
asm ("int $0x40"::"a"(5), "b"(d));
19
}
20
21
 
22
 
23
{
24
asm ("nop"::"a"(0), "b"(x*65536+w), "c"(y*65536+h), "d"(c));
25
asm ("movl $0xffffff, %esi \n int $0x40");
26
}
27
28
 
29
 
30
{
31
asm ("nop"::"a"(67), "b"(x), "c"(y));
32
asm ("movl $-1, %edx \n movl $-1, %esi \n int $0x40");
33
}
34
35
 
36
 
37
{
38
asm ("int $0x40"::"a"(40), "b"(e));
39
}
40
41
 
42
 
43
{
44
asm ("int $0x40"::"a"(10));
45
}
46
47
 
48
 
49
{
50
asm ("int $0x40"::"a"(23), "b"(time));
51
}
52
53
 
54
 
55
{
56
asm ("int $0x40"::"a"(11));
57
}
58
59
 
60
 
61
{
62
asm ("int $0x40"::"a"(12), "b"(1));
63
}
64
65
 
66
 
67
{
68
asm ("int $0x40"::"a"(12), "b"(2));
69
}
70
71
 
72
 
73
{
74
asm ("int $0x40"::"a"(1), "b"(x), "c"(y), "d"(c));
75
}
76
77
 
78
 
79
{
80
asm ("int $0x40"::"a"(13), "b"(x*65536+w), "c"(y*65536+h), "d"(c));
81
}
82
83
 
84
 
85
{
86
asm ("int $0x40"::"a"(38), "b"(x1*65536+x2), "c"(y1*65536+y2), "d"(c));
87
}
88
89
 
90
 
91
{
92
asm ("int $0x40"::"a"(4), "b"(x*65536+y), "c"(c), "d"(s));
93
}
94
95
 
96
 
97
{
98
asm ("int $0x40"::"a"(7), "c"(w*65536+h), "d"(x*65536+y), "b"(d));
99
}
100
101
 
102
 
103
{
104
asm ("nop"::"c"(w*65536+h), "d"(x*65536+y), "b"(d));
105
asm ("nop"::"a"(palette));
106
asm ("movl %eax, %edi");
107
asm ("xor %eax, %eax");
108
asm ("movl %eax, %ebp");
109
asm ("pushl $8");
110
asm ("popl %esi");
111
asm ("int $0x40"::"a"(65));
112
}
113
114
 
115
 
116
{
117
asm ("int $0x40"::"a"(2));
118
}
119
120
 
121
 
122
{
123
asm ("int $0x40"::"a"(66), "b"(3));
124
}
125
126
 
127
 
128
{
129
asm ("int $0x40"::"a"(21), "b"(2), "c"(9), "d"(lang));
130
}
131
132
 
133
 
134
{
135
asm ("int $0x40"::"a"(26), "b"(2), "c"(9));
136
}
137
138
 
139
 
140
{
141
asm ("int $0x40"::"a"(66), "b"(1), "c"(mode));
142
}
143
144
 
145
 
146
{
147
asm ("int $0x40"::"a"(66), "b"(2));
148
}
149
150
 
151
 
152
{
153
asm ("int $0x40"::"a"(17));
154
}
155
156
 
157
 
158
{
159
asm ("nop"::"b"(x*65536+w), "c"(y*65536+h), "d"(d));
160
asm ("nop"::"a"(c));
161
asm ("movl %eax, %esi");
162
asm ("int $0x40"::"a"(8));
163
}
164
165
 
166
 
167
{
168
asm ("int $0x40"::"a"(48), "b"(1), "c"(t));
169
}
170
171
 
172
 
173
{
174
asm ("int $0x40"::"a"(71), "b"(1), "c"(s));
175
}
176
177
 
178
 
179
{
180
asm ("int $0x40"::"a"(37), "b"(0));
181
}
182
183
 
184
 
185
{
186
asm ("int $0x40"::"a"(37), "b"(1));
187
}
188
189
 
190
 
191
{
192
asm ("int $0x40"::"a"(37), "b"(2));
193
}
194
195
 
196
 
197
{
198
asm ("int $0x40"::"a"(63), "b"(1), "c"(c));
199
}
200
201
 
202
 
203
{
204
unsigned i;
205
i = 0;
206
while (*(s+i))
207
	{
208
	asm ("int $0x40"::"a"(63), "b"(1), "c"(*(s+i)));
209
	i++;
210
	}
211
}
212
213
 
214
 
215
{
216
char c;
217
int i = 0;
218
do
219
	{
220
	c = n % 10 + '0';
221
	asm ("int $0x40"::"a"(63), "b"(1), "c"(c));
222
	i++;
223
	}
224
	while ((n /= 10) > 0);
225
}
226
227
 
228
 
229
{
230
asm ("int $0x40"::"a"(70), "b"(k));
231
}
232
233
 
234
 
235
{
236
asm ("int $0x40"::"a"(68), "b"(19), "c"(name));
237
}
238
239
 
240
 
241
{
242
int i;
243
for (i=0;;i++)
244
	if ( NULL == ((imp+i) -> name))
245
		break;
246
	else
247
		if ( 0 == strcmp(name, (imp+i)->name) )
248
			return (imp+i)->data;
249
return NULL;
250
}
251
252
 
253
 
254
{
255
unsigned i, n;
256
257
 
258
	if ( NULL == ((imp+i) -> name))
259
		break;
260
	else
261
		n++;
262
263
 
264
}
265
266
 
267
 
268
{
269
unsigned i;
270
*name = 0;
271
272
 
273
	if ( NULL == ((imp+i) -> name))
274
		break;
275
	else
276
		if ( i == n )
277
			{
278
			strcpy(name, ((imp+i)->name));
279
			break;
280
			}
281
282
 
283
284
 
285
 
286
{
287
asm ("int $0x40"::"a"(18), "b"(5));
288
}
289
290
 
291
 
292
{
293
asm ("int $0x40"::"a"(18), "b"(17));
294
}
295
296
 
297
 
298
{
299
asm ("int $0x40"::"a"(18), "b"(16));
300
}
301
302
 
303
 
304
{
305
asm ("int $0x40"::"a"(3));
306
}
307
308
 
309
 
310
{
311
asm ("int $0x40"::"a"(29));
312
}
313
314
 
315
 
316
{
317
asm ("int $0x40"::"a"(18), "b"(9), "c"(param));
318
}
319
320
 
321
 
322
{
323
unsigned i;
324
strcpy (dir, fname);
325
for ( i = strlen(dir);; --i)
326
	if ( '/' == dir[i])
327
		{
328
		dir[i] = '\0';
329
		return;
330
		}
331
}
332
333
 
334
 
335
{
336
char temp[256];
337
338
 
339
{
340
341
 
342
	strncpy(temp, fname+1, 2);
343
	temp[2]=0;
344
	if ( (!strcmp("rd", temp)) || (!strcmp("hd", temp)) || (!strcmp("cd", temp)) )
345
		strcpy (full, fname);
346
	break;
347
348
 
349
	break;
350
351
 
352
	break;
353
354
 
355
356
 
357
358
 
359
 
360
 
361
{
362
asm ("int $0x40"::"a"(18), "b"(14));
363
}
364
365
 
366
 
367
 
368
{
369
unsigned size;
370
asm ("int $0x40":"=a"(size):"a"(14));
371
*w = size / 65536;
372
*h = size % 65536;
373
}
374
375
 
376
 
377
 
378
{
379
asm ("int $0x40"::"a"(48), "b"(4));
380
}
381
382
 
383
 
384
{
385
asm ("int $0x40"::"a"(51), "b"(1), "c"(start), "d"(stack));
386
}
387
388
 
389
 
390
{
391
asm ("int $0x40"::"a"(26), "b"(9));
392
}
393
394
 
395
 
396
{
397
asm ("movl %0, %%esi"::"a"(data));
398
asm ("int $0x40"::"a"(55), "b"(55));
399
}
400
401
 
402
 
403
{
404
asm ("int $0x40"::"a"(9), "b"(buf1k), "c"(slot));
405
}
406
407
 
408
 
409
{
410
asm ("int $0x40"::"a"(18), "b"(18), "c"(process));
411
}
412
1668 Nasarus 413
 
414
{
415
asm ("int $0x40"::"a"(18), "b"(13), "c"(buff16b));
416
}
417