Mistři v programování na #hovnokod

Delphi #633

procedure Load_flashDEF_setings;
var
  Reg: TRegistry;
  RegKeyPath: string;
begin
 Reg := TRegistry.Create;
 try
  with Reg do begin
   RootKey := HKEY_CURRENT_USER;
   RegKeyPath := 'Software\fuckinSoft';
   OpenKey(RegKeyPath, True);
   if ReadBool('Wipe_File')=false then begin Main.frmMain.CBx_wipe_file.Checked:=false;
   end
   else
   if ReadBool('Wipe_File')=true then begin Main.frmMain.CBx_wipe_file.Checked:=true;
   end
   else
   if ReadBool('Def_Module')=false then begin Main.frmMain.CBx_defence_module.Checked:=false;
   end
   else
   if ReadBool('Def_Module')=true then begin Main.frmMain.CBx_defence_module.Checked:=true;
   end
  end
 finally
  Reg.CloseKey;
  Reg.Free;
 end;
end;
 
procedure Save_flashDEF_setings;
var
  Reg: TRegistry;
  RegKeyPath: string;
begin
 Reg := TRegistry.Create;
 try
  with Reg do begin
   RootKey := HKEY_CURRENT_USER;
   RegKeyPath := 'Software\fuckinSoft';
   OpenKey(RegKeyPath, True);
   if Main.frmMain.CBx_wipe_file.Checked=true then begin WriteBool('Wipe_File', true);
   end
   else
   if Main.frmMain.CBx_wipe_file.Checked=false then begin WriteBool('Wipe_File', false);
   end
   else
   if Main.frmMain.CBx_defence_module.Checked=true then begin WriteBool('Def_Module', true);
   end
   else
   if Main.frmMain.CBx_defence_module.Checked=false then begin WriteBool('Def_Module', false);
   end
  end
 finally
  Reg.CloseKey;
  Reg.Free;
 end;
end;

HovnoKod,