From dab9882fbc7a46643f857f1f1e22b4a2d24bd6ce Mon Sep 17 00:00:00 2001 From: "Kirill Lipatov (Leency)" Date: Mon, 18 Sep 2017 08:12:27 +0000 Subject: [PATCH] Eolite 3.78: fix file sizes in list bigger than 4Gb, fix left blue block overflew status bar git-svn-id: svn://kolibrios.org@6987 a494cfbc-eb01-0410-851d-a64ba20cac60 --- programs/cmm/eolite/Eolite.c | 9 ++++++++- programs/cmm/eolite/include/left_panel.h | 12 ++++++------ programs/cmm/eolite/include/properties.h | 4 ++-- programs/cmm/eolite/include/translations.h | 4 ++-- 4 files changed, 18 insertions(+), 11 deletions(-) diff --git a/programs/cmm/eolite/Eolite.c b/programs/cmm/eolite/Eolite.c index 65a7e1953f..96f24fba2d 100644 --- a/programs/cmm/eolite/Eolite.c +++ b/programs/cmm/eolite/Eolite.c @@ -690,13 +690,20 @@ void Line_ReDraw(dword bgcol, filenum){ attr = ESDWORD[file_offet]; file.selected = ESBYTE[file_offet+7]; file.sizelo = ESDWORD[file_offet+32]; + file.sizehi = ESDWORD[file_offet+36]; file_name_off = file_offet+40; if (! TestBit(attr, 4) ) //file or folder? { ext1 = strrchr(file_name_off,'.') + file_name_off; if (ext1==file_name_off) ext1 = NULL; //if no extension then show nothing - WriteText(7-strlen(ConvertSize(file.sizelo))*6+files.x+files.w - 58, files.text_y+y+1, files.font_type, 0, ConvertSize(file.sizelo)); + WriteText( + 7-strlen(ConvertSize64(file.sizelo, file.sizehi))*6+files.x+files.w - 58, + files.text_y+y+1, + files.font_type, + 0, + ConvertSize64(file.sizelo, file.sizehi) + ); if (ext1) && (strlen(ext1)<9) WriteTextCenter(files.x+files.w-140, files.text_y+y+1, 72, 0, ext1); } else diff --git a/programs/cmm/eolite/include/left_panel.h b/programs/cmm/eolite/include/left_panel.h index c39462e722..9e097075b3 100644 --- a/programs/cmm/eolite/include/left_panel.h +++ b/programs/cmm/eolite/include/left_panel.h @@ -224,22 +224,22 @@ void DrawLeftPanelBg() { int actions_y = SystemDiscs.list.count*16; int start_y = actions_y+156; - int onTop1; + int area_h; DrawBar(2,41,190,15,col_lpanel); //синий прямоугольник - над девайсами DrawBar(17,actions_y+75,160,15,col_lpanel); //синий прямоугольник - под девайсами PutShadow(17,actions_y+75,160,1,1,3); PutShadow(18,actions_y+75+1,158,1,1,1); DrawBar(2,56,15,actions_y+103,col_lpanel); //синий прямоугольник - слева DrawBar(177,56,15,actions_y+103,col_lpanel); //синий прямоугольник - справа - onTop1 = Form.cheight-start_y-2 - status_bar_h; - if (onTop1 < 268) + area_h = Form.cheight-start_y-2 - status_bar_h; + if (area_h < 268) { - PutPaletteImage(#blue_hl, 190, onTop1, 2, start_y, 8, #blue_hl_pal); + PutPaletteImage(#blue_hl, 190, area_h, 2, start_y, 8, #blue_hl_pal); } else { - DrawBar(2,start_y,190, onTop1-268+status_bar_h, col_lpanel); - PutPaletteImage(#blue_hl, 190, 268, 2, Form.cheight-270, 8, #blue_hl_pal); + DrawBar(2,start_y,190, area_h-268, col_lpanel); + PutPaletteImage(#blue_hl, 190, 268, 2, Form.cheight-270-status_bar_h, 8, #blue_hl_pal); } PutShadow(17,start_y,160,1,1,3); PutShadow(18,start_y+1,158,1,1,1); diff --git a/programs/cmm/eolite/include/properties.h b/programs/cmm/eolite/include/properties.h index 8841ba25cd..6e21024a31 100644 --- a/programs/cmm/eolite/include/properties.h +++ b/programs/cmm/eolite/include/properties.h @@ -386,7 +386,7 @@ void DrawPropertiesWindow() DrawIconByExtension(NULL, NULL, 18, 49, system.color.work); sprintf(#folder_info,"%s%d%s%d",SET_6,file_count,SET_7,dir_count); WriteText(50, 49, 0x90, system.color.work_text, #folder_info); - sprintf(#element_size_label,"%s (%d %s)",ConvertSize(size_dir),size_dir,SET_BYTE_LANG); + sprintf(#element_size_label,"%s (%d %s)",ConvertSize64(size_dir),size_dir,SET_BYTE_LANG); WriteText(120, 97, 0x90, system.color.work_text, #element_size_label); } else @@ -416,7 +416,7 @@ void DrawPropertiesWindow() DrawDate(120, 156, system.color.work, #file_info_general.datelastaccess); DrawDate(120, 176, system.color.work, #file_info_general.datelastedit); - sprintf(#element_size_label,"%s (%d %s)",ConvertSize(element_size),element_size,SET_BYTE_LANG); + sprintf(#element_size_label,"%s (%d %s)",ConvertSize64(element_size),element_size,SET_BYTE_LANG); WriteText(120, 99, 0x90, system.color.work_text, #element_size_label); } flags_frame.size_x = - flags_frame.start_x * 2 + settings_form.cwidth - 2; diff --git a/programs/cmm/eolite/include/translations.h b/programs/cmm/eolite/include/translations.h index 7ca07e4e3f..03e690a371 100644 --- a/programs/cmm/eolite/include/translations.h +++ b/programs/cmm/eolite/include/translations.h @@ -1,5 +1,5 @@ -#define TITLE "Eolite File Manager v3.77" -#define ABOUT_TITLE "EOLITE 3.77" +#define TITLE "Eolite File Manager v3.78" +#define ABOUT_TITLE "EOLITE 3.78" #ifdef LANG_RUS ?define T_FILE "” ©«"