forked from KolibriOS/kolibrios
Eolite: the notification of the completion of the copy (optionaly)
git-svn-id: svn://kolibrios.org@5459 a494cfbc-eb01-0410-851d-a64ba20cac60
This commit is contained in:
parent
18e9a1dc33
commit
d43cb2a354
@ -3,4 +3,4 @@ SelectionColor=148,174,206
|
||||
LineHeight=18
|
||||
ShowDeviceName=1
|
||||
RealFileNamesCase=0
|
||||
|
||||
InfoAfterCopy=0
|
||||
|
@ -83,8 +83,8 @@
|
||||
|
||||
enum {ONLY_SHOW, WITH_REDRAW, ONLY_OPEN}; //OpenDir
|
||||
|
||||
#define TITLE "Eolite File Manager v2.54"
|
||||
#define ABOUT_TITLE "Eolite v2.54"
|
||||
#define TITLE "Eolite File Manager v2.55"
|
||||
#define ABOUT_TITLE "Eolite v2.55"
|
||||
dword col_padding, col_selec, col_lpanel;
|
||||
|
||||
int toolbar_buttons_x[7]={9,46,85,134,167,203};
|
||||
@ -110,6 +110,7 @@ byte
|
||||
del_active=0,
|
||||
show_dev_name=1,
|
||||
real_files_names_case=0,
|
||||
info_after_copy=0,
|
||||
sort_num=2,
|
||||
itdir;
|
||||
|
||||
|
@ -1,5 +1,13 @@
|
||||
//Leency 2008-2014
|
||||
|
||||
#ifdef LANG_RUS
|
||||
?define INFO_AFTER_COPY "Š®¯¨à®¢ ¨¥ § ¢¥à襮"
|
||||
#elif LANG_EST
|
||||
?define INFO_AFTER_COPY "Copy finished"
|
||||
#else
|
||||
?define INFO_AFTER_COPY "Copy finished"
|
||||
#endif
|
||||
|
||||
byte copy_to[4096];
|
||||
byte cut_active=0;
|
||||
|
||||
@ -111,6 +119,7 @@ void Paste()
|
||||
{
|
||||
cut_active=false;
|
||||
}
|
||||
if (info_after_copy) notify(INFO_AFTER_COPY);
|
||||
CopyExit();
|
||||
}
|
||||
|
||||
|
@ -8,6 +8,7 @@
|
||||
?define SET_1 "‚뢮¤¨âì §¢ ¨ï ª« áá ãáâனáâ¢"
|
||||
?define SET_2 "<EFBFBD>®ª §ë¢ âì ¨¬¥ ä ©«®¢ ¥ ¬¥ïï ॣ¨áâà"
|
||||
?define SET_3 "‚ëá®â áâப¨ ¢ ᯨ᪥"
|
||||
?define SET_4 "“¢¥¤®¬«ïâì ® § ¢¥à襨¨ ª®¯¨à®¢ ¨ï"
|
||||
?define CANCEL_T "Žâ¬¥ "
|
||||
?define APPLY_T "<EFBFBD>ਬ¥¨âì"
|
||||
#else
|
||||
@ -16,27 +17,30 @@
|
||||
?define SET_1 "Show device class name"
|
||||
?define SET_2 "Show real file names without changing case"
|
||||
?define SET_3 "List line height"
|
||||
?define SET_4 "To notify the completion of the copy"
|
||||
?define CANCEL_T "Cancel"
|
||||
?define APPLY_T "Apply"
|
||||
#endif
|
||||
|
||||
int mouse_ddd;
|
||||
char lineh_s[30]="18\0";
|
||||
edit_box LineHeight_ed = {52,10,70,0xffffff,0x94AECE,0xffc90E,0xffffff,2,4,#lineh_s,#mouse_ddd, 1000000000000000b,2,2};
|
||||
edit_box LineHeight_ed = {52,10,90,0xffffff,0x94AECE,0xffc90E,0xffffff,2,4,#lineh_s,#mouse_ddd, 1000000000000000b,2,2};
|
||||
checkbox2 ShowDeviceName_chb = {10*65536+15, 10*65536+15, 5, 0xffffff, 0x9098B0, 0x80000000, SET_1, CH_FLAG_MIDDLE, 0};
|
||||
checkbox2 RealFileNamesCase_chb = {10*65536+15, 30*65536+15, 5, 0xffffff, 0x9098B0, 0x80000000, SET_2, CH_FLAG_MIDDLE, 0};
|
||||
checkbox2 InfoAfterCopy_chb = {10*65536+15, 50*65536+15, 5, 0xffffff, 0x9098B0, 0x80000000, SET_4, CH_FLAG_MIDDLE, 0};
|
||||
|
||||
void settings_dialog()
|
||||
{
|
||||
byte id;
|
||||
unsigned int key;
|
||||
proc_info settings_form;
|
||||
|
||||
if (active_about) ExitProcess();
|
||||
active_about=1;
|
||||
|
||||
if (active_settings) ExitProcess();
|
||||
active_settings=1;
|
||||
|
||||
ShowDeviceName_chb.size_of_str = strlen(SET_1) * 6;
|
||||
RealFileNamesCase_chb.size_of_str = strlen(SET_2) * 6;
|
||||
InfoAfterCopy_chb.size_of_str = strlen(SET_4) * 6;
|
||||
|
||||
SetEventMask(0x27);
|
||||
loop() switch(WaitEvent())
|
||||
@ -46,13 +50,13 @@ void settings_dialog()
|
||||
if (id==10)
|
||||
{
|
||||
SaveIniSettings();
|
||||
active_about=0;
|
||||
active_settings=0;
|
||||
action_buf = 300;
|
||||
ExitProcess();
|
||||
}
|
||||
if (id==1) || (id==11)
|
||||
{
|
||||
active_about=0;
|
||||
active_settings=0;
|
||||
ExitProcess();
|
||||
}
|
||||
if (id==5)
|
||||
@ -65,7 +69,7 @@ void settings_dialog()
|
||||
key = GetKey();
|
||||
if (key==27)
|
||||
{
|
||||
active_about=0;
|
||||
active_settings=0;
|
||||
action_buf = 300;
|
||||
ExitProcess();
|
||||
}
|
||||
@ -76,6 +80,7 @@ void settings_dialog()
|
||||
case evMouse:
|
||||
check_box_mouse stdcall (#ShowDeviceName_chb);
|
||||
check_box_mouse stdcall (#RealFileNamesCase_chb);
|
||||
check_box_mouse stdcall (#InfoAfterCopy_chb);
|
||||
edit_box_mouse stdcall (#LineHeight_ed);
|
||||
break;
|
||||
|
||||
@ -85,16 +90,18 @@ void settings_dialog()
|
||||
|
||||
ShowDeviceName_chb.flags |= 1 << show_dev_name;
|
||||
RealFileNamesCase_chb.flags |= 1 << real_files_names_case;
|
||||
InfoAfterCopy_chb.flags |= 1 << info_after_copy;
|
||||
|
||||
key = itoa(files.line_h);
|
||||
strcpy(#lineh_s, key);
|
||||
|
||||
check_box_draw stdcall (#ShowDeviceName_chb);
|
||||
check_box_draw stdcall (#RealFileNamesCase_chb);
|
||||
check_box_draw stdcall (#InfoAfterCopy_chb);
|
||||
edit_box_draw stdcall (#LineHeight_ed);
|
||||
DrawRectangle(LineHeight_ed.left-1, LineHeight_ed.top-1, LineHeight_ed.width+2, 16, sc.work_graph);
|
||||
WriteText(10, 57, 0x80, 0x000000, SET_3);
|
||||
DrawFlatButton(9, 100, strlen(EDIT_FILE_ASSOCIATIONS)+4*6, 22, 5, 0xE4DFE1, EDIT_FILE_ASSOCIATIONS);
|
||||
WriteText(10, 77, 0x80, 0x000000, SET_3);
|
||||
DrawFlatButton(9, 120, strlen(EDIT_FILE_ASSOCIATIONS)+4*6, 22, 5, 0xE4DFE1, EDIT_FILE_ASSOCIATIONS);
|
||||
DrawFlatButton(128, settings_form.cheight - 34, 70, 22, 10, 0xE4DFE1, APPLY_T);
|
||||
DrawFlatButton(208, settings_form.cheight - 34, 70, 22, 11, 0xE4DFE1, CANCEL_T);
|
||||
}
|
||||
@ -112,14 +119,18 @@ void LoadIniSettings()
|
||||
show_dev_name = EAX;
|
||||
ini_get_int stdcall (eolite_ini_path, "Config", "RealFileNamesCase", 0);
|
||||
real_files_names_case = EAX;
|
||||
ini_get_int stdcall (eolite_ini_path, "Config", "InfoAfterCopy", 0);
|
||||
info_after_copy = EAX;
|
||||
}
|
||||
|
||||
void SaveIniSettings()
|
||||
{
|
||||
show_dev_name = TestBit(ShowDeviceName_chb.flags, 1);
|
||||
real_files_names_case = TestBit(RealFileNamesCase_chb.flags, 1);
|
||||
info_after_copy = TestBit(InfoAfterCopy_chb.flags, 1);
|
||||
ini_set_int stdcall (eolite_ini_path, "Config", "ShowDeviceName", show_dev_name);
|
||||
ini_set_int stdcall (eolite_ini_path, "Config", "RealFileNamesCase", real_files_names_case);
|
||||
ini_set_int stdcall (eolite_ini_path, "Config", "InfoAfterCopy", info_after_copy);
|
||||
ini_set_int stdcall (eolite_ini_path, "Config", "LineHeight", atoi(#lineh_s));
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user