Eolite: show timestamps in Properties dialog

git-svn-id: svn://kolibrios.org@9636 a494cfbc-eb01-0410-851d-a64ba20cac60
This commit is contained in:
Kirill Lipatov (Leency) 2022-01-14 20:04:36 +00:00
parent f2e87fdd55
commit 09089615eb
4 changed files with 34 additions and 15 deletions

View File

@ -11,9 +11,9 @@ TODO:
http://board.kolibrios.org/viewtopic.php?f=23&t=4521&p=77334#p77334
*/
#define ABOUT_TITLE "EOLITE 5.2a"
#define TITLE_EOLITE "Eolite File Manager 5.2a"
#define TITLE_KFM "Kolibri File Manager 2.2a";
#define ABOUT_TITLE "EOLITE 5.21"
#define TITLE_EOLITE "Eolite File Manager 5.21"
#define TITLE_KFM "Kolibri File Manager 2.21";
#define MEMSIZE 1024 * 250
#include "../lib/clipboard.h"

View File

@ -274,9 +274,9 @@ void DrawPropertiesWindow()
if (show_date) {
WriteTextLines(10, 136, 0x90, sc.work_text, CREATED_OPENED_MODIFIED, 20);
DrawDate(120, 136, sc.work_text, #file_info_general.datecreate);
DrawDate(120, 156, sc.work_text, #file_info_general.datelastaccess);
DrawDate(120, 176, sc.work_text, #file_info_general.datelastedit);
DrawDateTime(120, 136, sc.work_text, #file_info_general.datecreate, #file_info_general.timecreate);
DrawDateTime(120, 156, sc.work_text, #file_info_general.datelastaccess, #file_info_general.timelastaccess);
DrawDateTime(120, 176, sc.work_text, #file_info_general.datelastedit, #file_info_general.timelastedit);
}
DrawFrame(10, y.set(pform.cheight - 143), -10*2 + pform.cwidth - 2, 92, FLAGS);

View File

@ -13,25 +13,44 @@
word year;
};
:void DrawDate(dword x, y, color, in_date)
:struct time
{
EDI = in_date;
byte seconds;
byte minutes;
byte hours;
byte rez;
};
:void DrawDateTime(dword x, y, color, _date, _time)
{
EDI = _date;
EAX = 47;
EBX = 2<<16;
EDX = x<<16+y;
ESI = 0x90<<24+color;
ECX = EDI.date.day;
$int 64
EDX += 20<<16;
EDX += 24<<16;
ECX = EDI.date.month;
$int 64
EDX += 20<<16;
EDX += 24<<16;
EBX = 4<<16;
ECX = EDI.date.year;
$int 64
DrawBar(x+17,y+10,2,2,color);
$add ebx, 20 << 16
EDI = _time;
EDX += 40<<16;
EBX = 2<<16;
ECX = EDI.time.hours;
$int 64
EDX += 24<<16;
ECX = EDI.time.minutes;
$int 64
EDX += 24<<16;
ECX = EDI.time.seconds;
$int 64
WriteText(x,y,0x90,color, " . . : :");
}
#endif

View File

@ -31,11 +31,11 @@
:struct BDVK {
dword readonly:1, hidden:1, system:1, volume_label:1, isfolder:1, notarchived:1, :0;
byte type_name, rez1, rez2, selected; //name encoding
dword timecreate; //+8
time timecreate; //+8
date datecreate;
dword timelastaccess;
time timelastaccess;
date datelastaccess;
dword timelastedit;
time timelastedit;
date datelastedit;
dword sizelo;
dword sizehi;