diff --git a/programs/cmm/Calypte/include/properties.h b/programs/cmm/Calypte/include/properties.h index fa60284191..dd6b0460ec 100644 --- a/programs/cmm/Calypte/include/properties.h +++ b/programs/cmm/Calypte/include/properties.h @@ -50,10 +50,6 @@ void properties_dialog() { byte id; byte key; - dword file_name_off; - dword element_size; - dword selected_offset2; - char element_size_label[32]; proc_info settings_form; IF (active_properties) ExitProcess(); diff --git a/programs/cmm/eolite/Eolite.c b/programs/cmm/eolite/Eolite.c index 29e1240615..41bc310a37 100644 --- a/programs/cmm/eolite/Eolite.c +++ b/programs/cmm/eolite/Eolite.c @@ -458,10 +458,8 @@ void main() Del_Form(); break; case SCAN_CODE_INS: - selected_offset = file_mas[files.cur_y]*304 + buf+32 + 7; - if (ESBYTE[selected_offset]) setElementSelectedFlag(files.cur_y, false); + if (getElementSelectedFlag(files.cur_y) == true) setElementSelectedFlag(files.cur_y, false); else setElementSelectedFlag(files.cur_y, true); - _INSERT_END: files.KeyDown(); List_ReDraw(); DrawStatusBar(); diff --git a/programs/cmm/eolite/include/copy.h b/programs/cmm/eolite/include/copy.h index a4943d41cf..3d0689420e 100644 --- a/programs/cmm/eolite/include/copy.h +++ b/programs/cmm/eolite/include/copy.h @@ -7,17 +7,21 @@ enum {NOCUT, CUT}; Clipboard clipboard; -void setElementSelectedFlag(dword n, bool state) { +void setElementSelectedFlag(dword n, int state) { dword selected_offset = file_mas[n]*304 + buf+32 + 7; - if (!n) if (!strncmp(selected_offset+33, "..", 2)) return; //do not selec ".." directory ESBYTE[selected_offset] = state; + if (n==0) && (strncmp(file_mas[n]*304+buf+72,"..",2)==0) ESBYTE[selected_offset] = false; //do not selec ".." directory if (state==true) selected_count++; if (state==false) selected_count--; } +int getElementSelectedFlag(dword n) { + dword selected_offset = file_mas[n]*304 + buf+32 + 7; + return ESBYTE[selected_offset]; +} + void Copy(dword pcth, char cut) { - dword selected_offset2; byte copy_t[4096]; dword buff_data; dword path_len = 0; @@ -29,8 +33,7 @@ void Copy(dword pcth, char cut) size_buf = 4; for (i=0; i