Fix IO::readKPACK, font.h ability to load kpacked fonts, Eolite fix

git-svn-id: svn://kolibrios.org@5751 a494cfbc-eb01-0410-851d-a64ba20cac60
This commit is contained in:
Kirill Lipatov (Leency) 2015-08-20 10:06:51 +00:00
parent ae13c6042f
commit 0212e7a18e
4 changed files with 16 additions and 18 deletions

View File

@ -29,7 +29,7 @@ char *ext[]={
void Put_icon(dword extension, xx, yy, fairing_color, icon_n)
{
int i, font_half_height;
int i;
if (extension) for (i=0; ext[i]!=0; i+=2;)
{
@ -43,8 +43,7 @@ void Put_icon(dword extension, xx, yy, fairing_color, icon_n)
ficons_pal[0] = fairing_color;
PutPaletteImage(icon_n*16*15+#ficons,16,15,xx,yy,8,#ficons_pal);
if (fairing_color!=0xFFFfff) IconFairing(icon_n, xx, yy, fairing_color);
if (font_size==9) font_half_height=0; else font_half_height=4;
if (icon_n!=17) && (strlen(extension)<9) WriteText(-FileShow.font_size_x/2*strlen(extension)+files.x+files.w-103,yy+font_half_height,files.font_type,0,extension);
if (icon_n!=17) && (strlen(extension)<9) WriteText(-FileShow.font_size_x/2*strlen(extension)+files.x+files.w-103,yy+4,files.font_type,0,extension);
}

View File

@ -1,5 +1,5 @@
#define TITLE "Eolite File Manager v3.06"
#define ABOUT_TITLE "Eolite 3.06"
#define TITLE "Eolite File Manager v3.08"
#define ABOUT_TITLE "Eolite 3.08"
#ifdef LANG_RUS
?define T_FILE "” ©«"

View File

@ -212,7 +212,7 @@ FONT font = 0;
dword tmp;
buffer_size = 0;
IF(data)free(data);
if (io.read(path)!=0)
if (!io.readKPACK(path))
{
debug("Error while loading font: ");
debugln(path);

View File

@ -286,16 +286,6 @@
__FILE file;
____BDVK BDVK;
}io;
:dword IO::readKPACK(dword path1)
{
dword sizes;
EAX = 68;
EBX = 27;
ECX = path.path(path1);
EDX = sizes;
$int 0x40;
return EAX;
}
:byte __ConvertSize_size_prefix[8];
:dword IO::convert_size()
{
@ -310,7 +300,16 @@
sprintf(#__ConvertSize_size_prefix,"%d %s",bytes,#size_nm);
return #__ConvertSize_size_prefix;
}
:dword IO::readKPACK(dword path1)
{
EAX = 68;
EBX = 27;
ECX = path1;
$int 0x40;
FILES_SIZE = EDX;
buffer_data = EAX;
return buffer_data;
}
:int IO::write(dword PATH,data)
{
file.write(0,strlen(data),data,PATH);
@ -324,7 +323,7 @@
buffer_data = malloc(FILES_SIZE+1);
result = file.read(0,FILES_SIZE,buffer_data,PATH);
if (result!=0) buffer_data = free(buffer_data); //file read failed
return result;
return buffer_data;
}
:signed int IO::run(dword rpath,rparam)