Eolite 1.98.5: fix & update rename function

git-svn-id: svn://kolibrios.org@4029 a494cfbc-eb01-0410-851d-a64ba20cac60
This commit is contained in:
Kirill Lipatov (Leency) 2013-10-15 10:30:46 +00:00
parent 88b0e3bc8b
commit c991e634ef
3 changed files with 25 additions and 15 deletions

View File

@ -76,8 +76,8 @@
enum {ONLY_SHOW, WITH_REDRAW, ONLY_OPEN}; //OpenDir
#define TITLE "Eolite File Manager v1.98.4"
#define ABOUT_TITLE "Eolite v1.98.4"
#define TITLE "Eolite File Manager v1.98.5"
#define ABOUT_TITLE "Eolite v1.98.5"
dword col_work = 0xE4DFE1;
dword col_border = 0x9098B0; //A0A0B8; //0x819FC5;
dword col_padding = 0xC8C9C9;
@ -753,23 +753,29 @@ void ReName(byte rename)
if (strcmp(#file_path,#temp)!=0) && (file_name)
if (itdir)
{
del_rezult = DeleteFile(#file_path);
if (del_rezult!=0)
if (del_rezult = DeleteFile(#file_path))
{
Write_Error(del_rezult);
ShowMessage(T_DEL_ERROR_1, 150);
return;
}
ELSE CreateDir(#temp);
if (CreateDir(#temp)) CreateDir(#file_path);
Open_Dir(#path,WITH_REDRAW);
SelectFile(#edit_name);
}
else
{
copy_rezult = CopyFile(#file_path,#temp);
if (copy_rezult!=0) Write_Error(copy_rezult); else Del_File(true);
if (copy_rezult = CopyFile(#file_path,#temp))
{
Write_Error(copy_rezult);
}
else
{
Del_File(true);
SelectFile(#edit_name);
}
}
}
Line_ReDraw(col_selec,files.current);
}

View File

@ -45,24 +45,27 @@ void Install()
proc_info Process;
ShowProgress("Mounting virtual disk...");
if (TmpDiskAdd(9, 100)!=0) RunProgram("/sys/tmpdisk", "a9s100");
for (i=2; i<256; i++;)
//if (TmpDiskAdd(9, 100)!=0) RunProgram("/sys/tmpdisk", "a9s100");
for (i=0; i<256; i++;)
{
GetProcessInfo(#Process, i);
if (i==Form.ID) || (strcmp(#Process.name, "OS")==0) continue;
//debug(#Process.name);
KillProcess(i);
}
//RunProgram("/sys/develop/board", NULL); //temp============
RunProgram("/sys/REFRSCRN", NULL);
pause(100);
//pause(100);
ShowProgress("Copying files...");
copyf("/sys/docpack", "/tmp9/1/docpack");
copyf("/sys/docpack", "/kolibrios/docpack");
DeleteFile("/sys/docpack");
copyf(abspath("sys"), "/rd/1");
copyf(abspath("tmp"), "/tmp9/1");
//copyf(abspath("tmp"), "/tmp9/1");
SetAddApplDir("kolibrios", abspath("kolibrios"));
ShowProgress("Post install actions...");
RunProgram("/sys/launcher", NULL);
SetSystemSkin("/tmp9/1/skins/latte.skn");
SetSystemSkin("/kolibrios/skins/latte.skn");
EndLoop();
}
@ -102,3 +105,4 @@ void EndLoop()
DrawLink(TEXTX, BLACK_H*2+85, 0x80, 11, "http://kolibri-n.org/donate.php");
}
}

View File

@ -120,7 +120,7 @@
{
DrawRectangle(x,y,w,h,col_border);
DrawBar(x+1,y+1,w-1,1,0xFFFfff);
DrawBar(x+1,y+2,1,h-3,0xFFFfff);
DrawBar(x+1,y+2,1,h-2,0xFFFfff);
if (col_work!=-1) DrawBar(x+2,y+2,w-2,h-2,col_work);
DrawPopupShadow(x,y,w,h-1,skinned);
}