| 137 |
|
|
| 138 |
|
implementation |
| 139 |
|
|
| 140 |
+ |
uses |
| 141 |
+ |
LevelDB; |
| 142 |
+ |
|
| 143 |
|
{$R *.dfm} |
| 144 |
|
|
| 145 |
|
|
| 172 |
|
i: Integer; |
| 173 |
|
toolform: TForm_ToolTemplate; |
| 174 |
|
begin |
| 175 |
+ |
Result := True; |
| 176 |
|
if MDITab.MDIChildCount > 0 then |
| 177 |
|
begin |
| 178 |
|
for i := 0 to MDITab.MDIChildCount - 1 do |
| 183 |
|
if toolform.ConnectionID = ConManager.ConnectionByIndex[index].ConnectionID then |
| 184 |
|
begin |
| 185 |
|
if not toolform.Closeable then |
| 186 |
< |
ShowMessage('Can not close toolwindow: ' + toolform.Caption); |
| 186 |
> |
begin |
| 187 |
> |
ShowMessage('Can not close toolwindow: ' + toolform.Caption); |
| 188 |
> |
Result := False; |
| 189 |
> |
end; |
| 190 |
|
end; |
| 191 |
|
end; |
| 192 |
|
end; |
| 241 |
|
|
| 242 |
|
|
| 243 |
|
procedure TForm_Main.FormCreate(Sender: TObject); |
| 237 |
– |
var |
| 238 |
– |
RepMsg: TStatusMessages; |
| 244 |
|
begin |
| 245 |
|
Self.Caption := 'Oni Un/Packer ' + version; |
| 246 |
|
Self.FormResize(Self); |
| 259 |
|
begin |
| 260 |
|
AppSettings.DatPath := ExtractFilepath(Application.EXEname); |
| 261 |
|
AppSettings.ExtractPath := ExtractFilepath(Application.EXEname) + '\extract'; |
| 257 |
– |
AppSettings.FilenumbersAsHex := False; |
| 262 |
|
AppSettings.CharSet := DEFAULT_CHARSET; |
| 263 |
|
AppSettings.HideUnusedData := False; |
| 264 |
|
end; |
| 445 |
|
position: TTBDockPosition; |
| 446 |
|
mode: TTBItemDisplayMode; |
| 447 |
|
i: Integer; |
| 444 |
– |
isEnabled: Boolean; |
| 448 |
|
begin |
| 449 |
|
toolbar := TTBToolbar(Sender); |
| 450 |
|
if toolbar.Floating then |
| 564 |
|
|
| 565 |
|
procedure TForm_Main.menu_createlvlClick(Sender: TObject); |
| 566 |
|
begin |
| 567 |
< |
ShowMessage('Not yet usable'); |
| 568 |
< |
{ |
| 567 |
> |
// ShowMessage('Not yet usable'); |
| 568 |
> |
|
| 569 |
|
opend.Filter := 'OUP-Level-DB (*.oldb)|*.oldb'; |
| 570 |
|
saved.Filter := 'Oni-Dat-Files|*.dat'; |
| 571 |
|
saved.DefaultExt := 'dat'; |
| 572 |
|
if opend.Execute then |
| 573 |
|
if saved.Execute then |
| 574 |
|
Form_LevelDB.CreateLevel(opend.FileName, saved.FileName); |
| 575 |
< |
} |
| 575 |
> |
|
| 576 |
|
end; |
| 577 |
|
|
| 578 |
|
|
| 677 |
|
procedure TForm_Main.menu_conns_itemClick(Sender: TObject); |
| 678 |
|
var |
| 679 |
|
name: String; |
| 677 |
– |
i: Integer; |
| 680 |
|
index: Integer; |
| 681 |
|
RepMsg: TStatusMessages; |
| 682 |
|
begin |
| 746 |
|
iconindex := -1; |
| 747 |
|
caption_end := IntToStr(tag) + ' '; |
| 748 |
|
|
| 749 |
+ |
toolform := nil; |
| 750 |
+ |
|
| 751 |
|
if window_context = 'binedit' then |
| 752 |
|
begin |
| 753 |
|
toolform := TForm_BinEdit.Create(Self); |