anchor.diff:        s := s + cProjectExt;
       GProject.Save(s);
     end;
  -
  +end;
  +
  +procedure TMainForm.miProjectAddUnitToProject(Sender: TObject);
  +var
  +  u: TUnit;
  +  s: TfpgString;
  +  i: integer;
  +begin
  +  s := pcEditor.ActivePage.Hint;
  +  writeln('adding unit: ', s);
  +  if s = '' then
  +    Exit;
  +  if GProject.UnitList.FileExists(s) then
  +    Exit;
  +  u := TUnit.Create;
  +  u.FileName := s;
  +  u.Opened := True;
  +  GProject.UnitList.Add(u);
   end;
   
   procedure TMainForm.TabSheetClosing(Sender: TObject; ATabSheet: TfpgTabSheet);
  
positive.code:     AddMenuItem('Save As...', '', @miProjectSaveAs);
      AddMenuItem('-', '', nil);
      AddMenuItem('View Source', '', nil);
      AddMenuItem('Add editor file to Project', '', nil);
    end;
  
    mnuRun := TfpgPopupMenu.Create(self);
  
negative.code:   ,frm_debug
    ,ideconst
    ,Project
    ,UnitList
    ;
  
  
  