Changeset 53


Ignore:
Timestamp:
Jul 26, 2012, 3:40:30 PM (12 years ago)
Author:
chronos
Message:
  • Fixed: Interface localization was not working.
Location:
trunk
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • trunk/Forms/UFormMain.pas

    r52 r53  
    196196procedure TMainForm.FormShow(Sender: TObject);
    197197begin
     198  Core.CoolTranslator1.Translate;
    198199  LoadFromRegistry(HKEY(Core.ApplicationInfo.RegistryRoot), Core.ApplicationInfo.RegistryKey);
    199200  PageControlMain.TabIndex := 0;
  • trunk/Target/UTarget.pas

    r52 r53  
    7575    FCompiled: Boolean;
    7676    function SourceReadNext: Char;
    77     function IsOpcode(Opcode: Char): Boolean;
    7877    function CheckClear: Boolean;
    7978    function CheckOccurence(C: TBrainFuckCommand): Integer;
     
    409408    Free;
    410409  end;
    411   if FileExistsUTF8(CompilerPath) then
    412   try
    413     Process := TProcess.Create(nil);
    414     Process.CurrentDirectory := ExtractFilePath(CompilerPath);
    415     Process.CommandLine := LongFileName(CompilerPath) + ' ' + LongFileName(CompiledFile);
    416     Process.Options := [poWaitOnExit];
    417     Process.Execute;
    418   finally
    419     Process.Free;
    420   end else raise Exception.Create(Format(SCompilerNotFound, [CompilerPath]));
     410  if CompilerPath <> '' then begin
     411    if FileExistsUTF8(CompilerPath) then
     412    try
     413      Process := TProcess.Create(nil);
     414      Process.CurrentDirectory := ExtractFilePath(CompilerPath);
     415      Process.CommandLine := LongFileName(CompilerPath) + ' ' + LongFileName(CompiledFile);
     416      Process.Options := [poWaitOnExit];
     417      Process.Execute;
     418    finally
     419      Process.Free;
     420    end else raise Exception.Create(Format(SCompilerNotFound, [CompilerPath]));
     421  end;
    421422end;
    422423
     
    566567end;
    567568
    568 function TTarget.IsOpcode(Opcode: Char): Boolean;
    569 begin
    570   Result := (Opcode = '+') or (Opcode = '-') or (Opcode = '<') or (Opcode = '>') or
    571     (Opcode = '[') or (Opcode = ']') or (Opcode = ',') or (Opcode = '.');
    572 end;
    573 
    574569function TTarget.CheckClear: Boolean;
    575570begin
Note: See TracChangeset for help on using the changeset viewer.