ViewVC Help
View File | Revision Log | View Changeset | Root Listing
root/Oni2/oup/current/Main.pas
(Generate patch)

Comparing oup/current/Main.pas (file contents):
Revision 208 by alloc, Sat May 26 18:42:15 2007 UTC vs.
Revision 209 by alloc, Mon Jun 4 22:07:29 2007 UTC

# Line 135 | Line 135 | var
135   implementation
136  
137   uses
138 <  LevelDB;
138 >  LevelDB, MetaEditor;
139  
140   {$R *.dfm}
141  
# Line 414 | Line 414 | begin
414    tb_rawedit.Enabled := active;
415    tb_txmpreplacer.Enabled := active;
416    tb_extractor.Enabled := active;
417 +  tb_meta.Enabled := active;
418   //  tb_compare.Enabled := active;
419   //  tb_structure.Enabled := active;
420   end;
# Line 604 | Line 605 | begin
605   end;
606  
607   procedure TForm_Main.menu_metaClick(Sender: TObject);
608 < begin
609 <  ShowMessage('TBD');
608 > var
609 >  toolform:    TForm_Meta;
610 >  i:           Integer;
611 >  tag:         Integer;
612 >  iconindex:   Integer;
613 > begin
614 >  tag := 1;
615 >  if MDIChildCount > 0 then
616 >    for i := 0 to MDIChildCount - 1 do
617 >      if MDIChildren[i].Tag >= tag then
618 >        tag := MDIChildren[i].Tag + 1;
619 >
620 >  iconindex := -1;
621 >
622 >  toolform := nil;
623 >
624 >  toolform         := TForm_Meta.Create(Self);
625 >  toolform.Caption := 'MetaEditor' + ' ' + IntToStr(tag) + '       ';
626 >  iconindex        := 11;
627 >
628 >  if Assigned(toolform) then
629 >  begin
630 >    toolform.Name    := 'meta' + IntToStr(tag);
631 >    toolform.Tag     := tag;
632 >    MDITab.AddTab(TForm(toolform), iconindex);
633 >    toolform.Caption := AnsiReplaceStr(toolform.Caption, '       ', '');
634 >  end;
635   end;
636  
637   procedure TForm_Main.menu_filecompareClick(Sender: TObject);

Diff Legend

Removed lines
+ Added lines
< Changed lines (old)
> Changed lines (new)