Ignore:
Timestamp:
Oct 15, 2010, 7:09:49 AM (14 years ago)
Author:
george
Message:
  • Added: Windows for Code tree and compiled code.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/Transpascal/Forms/UProjectManager.pas

    r61 r62  
    11unit UProjectManager;
    2 
    3 {$mode objfpc}{$H+}
    42
    53interface
     
    3028
    3129uses
    32   UMainForm, UCodeForm;
     30  UMainForm, UCodeForm, UCompiledForm, UCodeTreeForm, UProducerTreeView;
    3331
    3432{ TProjectManager }
     
    4543      FileName := Compiler.CompiledFolder + DirectorySeparator +
    4644        Compiler.Producer.ClassName + DirectorySeparator + ExtractFileNameOnly(TProjectFile(Node.Data).Name) + Compiler.Producer.FileExtension;
    47       if ProducerControl is TMemo then
    4845        if FileExists(FileName) then
    49         TMemo(ProducerControl).Lines.LoadFromFile(FileName) else
    50           TMemo(ProducerControl).Lines.Clear;
    51       //if ProducerControl is TTreeView then
    52       //  TTreeView(ProducerControl).Assign(TProjectFile(Node.Data).ProducedCode);
     46        CompiledForm.SynEdit1.Lines.LoadFromFile(FileName) else
     47          CompiledForm.SynEdit1.Lines.Clear;
     48
     49      // Load code tree view
     50      Compiler.Producer.Free;
     51      Compiler.Producer := TProducerTreeView.Create;
     52      Compiler.Init;
     53      Compiler.Parser.OnGetSource := GetSource;
     54      with TProjectFile(Project.Items[0]) do begin
     55        Compiler.Compile(Parent.GetDir + Name, Source);
     56      end;
     57      //CodeTreeForm.TreeView1.Assign(TProducerTreeView(Compiler.Producer).TreeView);
    5358    end;
    5459  end;
Note: See TracChangeset for help on using the changeset viewer.