Roll back parts of r4681 for getting the selected table into the trigger name, as this broke keeping the data tab active when switching tables. See http://www.heidisql.com/forum.php?t=14399 . Instead, introduce and make use of MainForm.FocusedTables. Fixes issue #3477.

This commit is contained in:
Ansgar Becker
2013-12-26 05:38:27 +00:00
parent 35e809ae32
commit fd63e5e840
3 changed files with 8 additions and 19 deletions

View File

@ -29,9 +29,7 @@ type
private
FModified: Boolean;
FDefiners: TStringList;
FFocusedTables: TDBObjectList;
procedure SetModified(Value: Boolean);
procedure SetFocusedTables(Value: TDBObjectList);
protected
public
DBObject: TDBObject;
@ -41,7 +39,6 @@ type
function DeInit: TModalResult;
function GetDefiners: TStringList;
property Modified: Boolean read FModified write SetModified;
property FocusedTables: TDBObjectList read FFocusedTables write SetFocusedTables;
function ApplyModifications: TModalResult; virtual; abstract;
end;
TDBObjectEditorClass = class of TDBObjectEditor;
@ -1803,12 +1800,10 @@ begin
Align := alClient;
InheritFont(Font);
ScaleControls(Screen.PixelsPerInch, FORMS_DPI);
FocusedTables := nil;
end;
destructor TDBObjectEditor.Destroy;
begin
FFocusedTables.Free;
inherited;
end;
@ -1817,14 +1812,6 @@ begin
FModified := Value;
end;
procedure TDBObjectEditor.SetFocusedTables(Value: TDBObjectList);
begin
if Value = nil then
FFocusedTables := TDBObjectList.Create(False)
else
FFocusedTables := Value;
end;
procedure TDBObjectEditor.Init(Obj: TDBObject);
var
editName: TWinControl;