Subversion Repositories Kolibri OS

Compare Revisions

Regard whitespace Rev 3958 → Rev 3957

/programs/cmm/lib/kolibri.h
150,6 → 150,22
$shr eax,8
}
 
//----------------------------------------
 
/* ecx = point to structure
sysdir_name rb 64
sysdir_path rb 64
Ïðèìåð:
dir_name1 db 'addappl',0
dir_path1 db 'HD0/1',0
*/
inline fastcall int SetAddApplDir( ECX)
{
EAX = 30;
EBX = 3;
$int 0x40
}
 
inline fastcall dword GetFreeRAM()
{
$mov eax, 18
365,7 → 381,7
}
//------------------------------------------------------------------------------
 
void DefineAndDrawWindow(dword x, y, size_w, size_h, byte WindowType,dword WindowAreaColor, EDI, ESI)
void DefineAndDrawWindow(dword x,y, sizeX,sizeY, byte WindowType,dword WindowAreaColor, EDI, ESI)
{
EAX = 12; // function 12:tell os about windowdraw
EBX = 1;
372,8 → 388,8
$int 0x40
EAX = 0;
EBX = x << 16 + size_w;
ECX = y << 16 + size_h;
EBX = x << 16 + sizeX;
ECX = y << 16 + sizeY;
EDX = WindowType << 24 | WindowAreaColor;
$int 0x40
 
/programs/cmm/lib/strings.h
233,14 → 233,12
}
 
 
unsigned int strcpyb(dword search_in, copyin, startstr, endstr)
void strcpyb(dword search_in, copyin, startstr, endstr)
{
dword startp, endp;
dword copyin_start_off = copyin;
if (startstr==0) startp = search_in; else startp = strstr(search_in, startstr) + strlen(startstr);
startp = strstr(search_in, startstr) + strlen(startstr);
endp = strstri(startp, endstr);
if (endp==0) endp = startp+strlen(search_in);
//if (startp==endp) return 0;
if (startp==endp) return;
do
{
DSBYTE[copyin] = DSBYTE[startp];
249,7 → 247,6
}
while (startp<endp);
DSBYTE[copyin] = '\0';
return copyin_start_off;
}
 
 
/programs/cmm/lib/socket.h
1,26 → 1,5
#define SOCKET_PASSIVE 0
#define SOCKET_ACTIVE 1
 
inline fastcall int GetNumOfActiveNetworkDevices()
{
$mov eax,74
BL = -1;
$int 0x40
}
 
inline fastcall dword OpenUnixSocket( ECX, EDX, ESI, EDI)
{
$mov eax,75
$mov bl,0
$int 0x40
}
 
 
 
 
 
/* ======================= OLD =========================*/
 
inline fastcall dword OpenSocket( ECX, EDX, ESI, EDI)
{
$mov eax,53
28,7 → 7,6
$int 0x40
}
 
 
inline fastcall dword CloseSocket( ECX )
{
$mov eax, 53