mirror of
https://github.com/moparisthebest/Simba
synced 2025-02-07 10:40:19 -05:00
Fixed bug in freeing, Simba was freeing an already freed component!
This commit is contained in:
parent
495c652e9c
commit
229cdd6886
@ -8,19 +8,32 @@ object BitmapConvForm: TBitmapConvForm
|
|||||||
ClientWidth = 320
|
ClientWidth = 320
|
||||||
LCLVersion = '0.9.29'
|
LCLVersion = '0.9.29'
|
||||||
object Button1: TButton
|
object Button1: TButton
|
||||||
Left = 144
|
Left = 192
|
||||||
Height = 52
|
Height = 36
|
||||||
Top = 152
|
Top = 184
|
||||||
Width = 105
|
Width = 113
|
||||||
Caption = 'Button1'
|
Caption = 'Button1'
|
||||||
TabOrder = 0
|
TabOrder = 0
|
||||||
end
|
end
|
||||||
object CheckBox1: TCheckBox
|
object CheckBox1: TCheckBox
|
||||||
Left = 24
|
Left = 224
|
||||||
Height = 17
|
Height = 17
|
||||||
Top = 160
|
Top = 152
|
||||||
Width = 71
|
Width = 71
|
||||||
Caption = 'CheckBox1'
|
Caption = 'CheckBox1'
|
||||||
TabOrder = 1
|
TabOrder = 1
|
||||||
end
|
end
|
||||||
|
object Button2: TButton
|
||||||
|
Left = 12
|
||||||
|
Height = 36
|
||||||
|
Top = 184
|
||||||
|
Width = 90
|
||||||
|
Caption = 'Open'
|
||||||
|
OnClick = Button2Click
|
||||||
|
TabOrder = 2
|
||||||
|
end
|
||||||
|
object OpenPictureDialog1: TOpenPictureDialog
|
||||||
|
left = 128
|
||||||
|
top = 184
|
||||||
|
end
|
||||||
end
|
end
|
||||||
|
@ -6,7 +6,7 @@ interface
|
|||||||
|
|
||||||
uses
|
uses
|
||||||
Classes, SysUtils, FileUtil, LResources, Forms, Controls, Graphics, Dialogs,
|
Classes, SysUtils, FileUtil, LResources, Forms, Controls, Graphics, Dialogs,
|
||||||
StdCtrls;
|
StdCtrls, EditBtn, ExtDlgs;
|
||||||
|
|
||||||
type
|
type
|
||||||
|
|
||||||
@ -14,7 +14,10 @@ type
|
|||||||
|
|
||||||
TBitmapConvForm = class(TForm)
|
TBitmapConvForm = class(TForm)
|
||||||
Button1: TButton;
|
Button1: TButton;
|
||||||
|
Button2: TButton;
|
||||||
CheckBox1: TCheckBox;
|
CheckBox1: TCheckBox;
|
||||||
|
OpenPictureDialog1: TOpenPictureDialog;
|
||||||
|
procedure Button2Click(Sender: TObject);
|
||||||
private
|
private
|
||||||
{ private declarations }
|
{ private declarations }
|
||||||
public
|
public
|
||||||
@ -28,5 +31,13 @@ implementation
|
|||||||
|
|
||||||
{$R *.lfm}
|
{$R *.lfm}
|
||||||
|
|
||||||
|
{ TBitmapConvForm }
|
||||||
|
|
||||||
|
procedure TBitmapConvForm.Button2Click(Sender: TObject);
|
||||||
|
begin
|
||||||
|
if OpenPictureDialog1.Execute then
|
||||||
|
writeln(OpenPictureDialog1.FileName);
|
||||||
|
end;
|
||||||
|
|
||||||
end.
|
end.
|
||||||
|
|
||||||
|
@ -5,7 +5,6 @@ object ScriptFrame: TScriptFrame
|
|||||||
Width = 397
|
Width = 397
|
||||||
ClientHeight = 328
|
ClientHeight = 328
|
||||||
ClientWidth = 397
|
ClientWidth = 397
|
||||||
LCLVersion = '0.9.29'
|
|
||||||
TabOrder = 0
|
TabOrder = 0
|
||||||
DesignLeft = 159
|
DesignLeft = 159
|
||||||
DesignTop = 420
|
DesignTop = 420
|
||||||
|
@ -85,7 +85,6 @@ type
|
|||||||
procedure MakeActiveScriptFrame;
|
procedure MakeActiveScriptFrame;
|
||||||
procedure ScriptThreadTerminate(Sender: TObject);
|
procedure ScriptThreadTerminate(Sender: TObject);
|
||||||
constructor Create(TheOwner: TComponent); override;
|
constructor Create(TheOwner: TComponent); override;
|
||||||
destructor Destroy; override;
|
|
||||||
{ public declarations }
|
{ public declarations }
|
||||||
end;
|
end;
|
||||||
|
|
||||||
@ -640,11 +639,6 @@ begin
|
|||||||
// TSynPasSyn(SynEdit.Highlighter).NestedComments:= false; Does not work :(
|
// TSynPasSyn(SynEdit.Highlighter).NestedComments:= false; Does not work :(
|
||||||
end;
|
end;
|
||||||
|
|
||||||
destructor TScriptFrame.Destroy;
|
|
||||||
begin
|
|
||||||
inherited Destroy;
|
|
||||||
end;
|
|
||||||
|
|
||||||
initialization
|
initialization
|
||||||
{$R *.lfm}
|
{$R *.lfm}
|
||||||
|
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
object SimbaForm: TSimbaForm
|
object SimbaForm: TSimbaForm
|
||||||
Left = 150
|
Left = 143
|
||||||
Height = 623
|
Height = 623
|
||||||
Top = 69
|
Top = 115
|
||||||
Width = 660
|
Width = 660
|
||||||
AllowDropFiles = True
|
AllowDropFiles = True
|
||||||
Caption = 'THA FUKING Simba'
|
Caption = 'THA FUKING Simba'
|
||||||
@ -1348,6 +1348,10 @@ object SimbaForm: TSimbaForm
|
|||||||
Caption = 'Settings'
|
Caption = 'Settings'
|
||||||
OnClick = MenuItemSettingsButtonClick
|
OnClick = MenuItemSettingsButtonClick
|
||||||
end
|
end
|
||||||
|
object MenuItemBitmapConv: TMenuItem
|
||||||
|
Caption = 'New Item50'
|
||||||
|
OnClick = MenuItemBitmapConvClick
|
||||||
|
end
|
||||||
object MenuItemDivider10: TMenuItem
|
object MenuItemDivider10: TMenuItem
|
||||||
Caption = '-'
|
Caption = '-'
|
||||||
end
|
end
|
||||||
|
@ -104,6 +104,7 @@ type
|
|||||||
MenuFile: TMenuItem;
|
MenuFile: TMenuItem;
|
||||||
MenuEdit: TMenuItem;
|
MenuEdit: TMenuItem;
|
||||||
MenuHelp: TMenuItem;
|
MenuHelp: TMenuItem;
|
||||||
|
MenuItemBitmapConv: TMenuItem;
|
||||||
MenuItemExtensions: TMenuItem;
|
MenuItemExtensions: TMenuItem;
|
||||||
MenuItemSettingsButton: TMenuItem;
|
MenuItemSettingsButton: TMenuItem;
|
||||||
MenuItemDivider10: TMenuItem;
|
MenuItemDivider10: TMenuItem;
|
||||||
@ -258,6 +259,7 @@ type
|
|||||||
procedure FunctionListEnter(Sender: TObject);
|
procedure FunctionListEnter(Sender: TObject);
|
||||||
procedure FunctionListExit(Sender: TObject);
|
procedure FunctionListExit(Sender: TObject);
|
||||||
procedure FunctionListTimerTimer(Sender: TObject);
|
procedure FunctionListTimerTimer(Sender: TObject);
|
||||||
|
procedure MenuItemBitmapConvClick(Sender: TObject);
|
||||||
procedure MenuItemExtensionsClick(Sender: TObject);
|
procedure MenuItemExtensionsClick(Sender: TObject);
|
||||||
procedure MenuItemHandbookClick(Sender: TObject);
|
procedure MenuItemHandbookClick(Sender: TObject);
|
||||||
procedure MenuItemColourHistoryClick(Sender: TObject);
|
procedure MenuItemColourHistoryClick(Sender: TObject);
|
||||||
@ -459,6 +461,7 @@ uses
|
|||||||
debugimage,
|
debugimage,
|
||||||
files,
|
files,
|
||||||
InterfaceBase,
|
InterfaceBase,
|
||||||
|
bitmapconv,
|
||||||
extensionmanagergui,
|
extensionmanagergui,
|
||||||
colourhistory,
|
colourhistory,
|
||||||
math;
|
math;
|
||||||
@ -1888,9 +1891,18 @@ begin
|
|||||||
frmFunctionList.LoadScriptTree(CurrScript.SynEdit.Text);
|
frmFunctionList.LoadScriptTree(CurrScript.SynEdit.Text);
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
procedure TSimbaForm.MenuItemBitmapConvClick(Sender: TObject);
|
||||||
|
begin
|
||||||
|
BitmapConvForm.Show;
|
||||||
|
end;
|
||||||
|
|
||||||
procedure TSimbaForm.MenuItemExtensionsClick(Sender: TObject);
|
procedure TSimbaForm.MenuItemExtensionsClick(Sender: TObject);
|
||||||
begin
|
begin
|
||||||
ExtensionsForm.Show;
|
MenuItemExtensions.Checked := not ExtensionsForm.Visible;
|
||||||
|
if MenuItemExtensions.Checked then
|
||||||
|
ExtensionsForm.Show
|
||||||
|
else
|
||||||
|
ExtensionsForm.Hide;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TSimbaForm.MenuItemHandbookClick(Sender: TObject);
|
procedure TSimbaForm.MenuItemHandbookClick(Sender: TObject);
|
||||||
@ -2972,7 +2984,7 @@ end;
|
|||||||
|
|
||||||
destructor TMufasaTab.Destroy;
|
destructor TMufasaTab.Destroy;
|
||||||
begin
|
begin
|
||||||
ScriptFrame.Free;
|
// ScriptFrame.Free;
|
||||||
TabSheet.Free;
|
TabSheet.Free;
|
||||||
inherited Destroy;
|
inherited Destroy;
|
||||||
end;
|
end;
|
||||||
|
Loading…
Reference in New Issue
Block a user