Subversion Repositories Kolibri OS

Compare Revisions

Regard whitespace Rev 2173 → Rev 2174

/programs/system/shell/all.h
10,6 → 10,7
#include "system/kolibri.h"
#include "system/stdlib.h"
#include "system/string.h"
#include "system/ctype.h"
 
#include "globals.h"
#include "prototypes.h"
/programs/system/shell/compile_eng.bat
6,7 → 6,8
gcc -c system/kolibri.c
gcc -c system/stdlib.c
gcc -c system/string.c
ld -nostdlib -T kolibri.ld -o shell start.o kolibri.o stdlib.o string.o shell.o
gcc -c system/ctype.c
ld -nostdlib -T kolibri.ld -o shell start.o kolibri.o stdlib.o string.o ctype.o shell.o
objcopy shell -O binary
erase lang.h start.o shell.o kolibri.o stdlib.o string.o
kpack shell
/programs/system/shell/compile_rus.bat
6,7 → 6,8
gcc -c system/kolibri.c
gcc -c system/stdlib.c
gcc -c system/string.c
ld -nostdlib -T kolibri.ld -o shell start.o kolibri.o stdlib.o string.o shell.o
gcc -c system/ctype.c
ld -nostdlib -T kolibri.ld -o shell start.o kolibri.o stdlib.o string.o ctype.o shell.o
objcopy shell -O binary
erase lang.h start.o shell.o kolibri.o stdlib.o string.o
kpack shell
/programs/system/shell/globals.h
1,5 → 1,5
 
#define SHELL_VERSION "0.4.8"
#define SHELL_VERSION "0.4.9"
 
extern char PATH[256];
extern char PARAM[256];
/programs/system/shell/modules/module_command.c
74,6 → 74,13
default:
if (CMD_POS < 255)
{
if ( kol_key_control() & 0x40 ) // åñëè âêëþ÷¸í CapsLock
if ( (kol_key_control() & 1) || (kol_key_control() & 2)) // åñëè íàæàòû øèôòû
key = tolower(key);
else
key = toupper(key);
 
CMD[CMD_POS] = key;
CMD_POS++;
printf("%c", key);
/programs/system/shell/system/ctype.c
0,0 → 1,39
 
#include "ctype.h"
 
int toupper(int c)
{
 
if ( (c >= 97) && (c <= 122) )
return c-32 ;
 
if ( (c >= 160) && (c <= 175) )
return c-32 ;
 
if ( (c >= 224) && (c <= 239) )
return c-80 ;
 
if ( (c == 241) || (c == 243) || (c == 245) || (c == 247) )
return c-1;
 
return c;
}
 
int tolower(int c)
{
 
if ( (c >= 65) && (c <= 90) )
return c+32 ;
 
if ( (c >= 128) && (c <= 143) )
return c+32 ;
 
if ( (c >= 144) && (c <= 159) )
return c+80 ;
 
if ( (c == 240) || (c == 242) || (c == 244) || (c == 246) )
return c+1;
 
return c;
}
 
/programs/system/shell/system/ctype.h
0,0 → 1,3
 
int toupper(int c);
int tolower(int c);