mirror of
https://github.com/HeidiSQL/HeidiSQL.git
synced 2026-03-13 09:24:25 +08:00
Add textbox to store session comments. Fixes issue #3492.
This commit is contained in:
@@ -145,6 +145,12 @@ object connform: Tconnform
|
||||
Options = [coAllowClick, coDraggable, coEnabled, coParentBidiMode, coParentColor, coResizable, coShowDropMark, coAllowFocus]
|
||||
Position = 5
|
||||
WideText = 'Counter'
|
||||
end
|
||||
item
|
||||
Options = [coAllowClick, coDraggable, coEnabled, coParentBidiMode, coParentColor, coResizable, coShowDropMark, coAllowFocus]
|
||||
Position = 6
|
||||
Width = 10
|
||||
WideText = 'Comment'
|
||||
end>
|
||||
end
|
||||
object btnNew: TButton
|
||||
@@ -264,6 +270,13 @@ object connform: Tconnform
|
||||
Height = 13
|
||||
Caption = 'Databases:'
|
||||
end
|
||||
object lblComment: TLabel
|
||||
Left = 3
|
||||
Top = 241
|
||||
Width = 49
|
||||
Height = 13
|
||||
Caption = 'Comment:'
|
||||
end
|
||||
object chkCompressed: TCheckBox
|
||||
Left = 120
|
||||
Top = 190
|
||||
@@ -371,6 +384,15 @@ object connform: Tconnform
|
||||
TabOrder = 3
|
||||
OnClick = chkLoginPromptClick
|
||||
end
|
||||
object memoComment: TMemo
|
||||
Left = 120
|
||||
Top = 238
|
||||
Width = 172
|
||||
Height = 44
|
||||
Anchors = [akLeft, akTop, akRight, akBottom]
|
||||
TabOrder = 10
|
||||
OnChange = Modification
|
||||
end
|
||||
end
|
||||
object tabSSHtunnel: TTabSheet
|
||||
Caption = 'SSH tunnel'
|
||||
|
||||
@@ -93,6 +93,8 @@ type
|
||||
editStartupScript: TButtonedEdit;
|
||||
lblStartupScript: TLabel;
|
||||
chkFullTableStatus: TCheckBox;
|
||||
lblComment: TLabel;
|
||||
memoComment: TMemo;
|
||||
procedure FormCreate(Sender: TObject);
|
||||
procedure btnOpenClick(Sender: TObject);
|
||||
procedure FormShow(Sender: TObject);
|
||||
@@ -316,6 +318,7 @@ begin
|
||||
Sess.LocalTimeZone := chkLocalTimeZone.Checked;
|
||||
Sess.FullTableStatus := chkFullTableStatus.Checked;
|
||||
Sess.AllDatabasesStr := comboDatabases.Text;
|
||||
Sess.Comment := memoComment.Text;
|
||||
Sess.StartupScriptFilename := editStartupScript.Text;
|
||||
Sess.SSHPlinkExe := editSSHPlinkExe.Text;
|
||||
Sess.SSHHost := editSSHhost.Text;
|
||||
@@ -497,6 +500,7 @@ begin
|
||||
else
|
||||
Result.Port := 0;
|
||||
Result.AllDatabasesStr := comboDatabases.Text;
|
||||
Result.Comment := memoComment.Text;
|
||||
Result.SSHHost := editSSHHost.Text;
|
||||
Result.SSHPort := MakeInt(editSSHPort.Text);
|
||||
Result.SSHUser := editSSHuser.Text;
|
||||
@@ -575,6 +579,7 @@ begin
|
||||
else
|
||||
CellText := '';
|
||||
5: CellText := FormatNumber(Sess.Counter);
|
||||
6: CellText := Sess.Comment;
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
@@ -751,6 +756,7 @@ begin
|
||||
chkLocalTimeZone.Checked := Sess.LocalTimeZone;
|
||||
chkFullTableStatus.Checked := Sess.FullTableStatus;
|
||||
comboDatabases.Text := Sess.AllDatabasesStr;
|
||||
memoComment.Text := Sess.Comment;
|
||||
editStartupScript.Text := Sess.StartupScriptFilename;
|
||||
editSSHPlinkExe.Text := Sess.SSHPlinkExe;
|
||||
editSSHHost.Text := Sess.SSHHost;
|
||||
@@ -956,6 +962,7 @@ begin
|
||||
or (Sess.NetType <> TNetType(comboNetType.ItemIndex))
|
||||
or (Sess.StartupScriptFilename <> editStartupScript.Text)
|
||||
or (Sess.AllDatabasesStr <> comboDatabases.Text)
|
||||
or (Sess.Comment <> memoComment.Text)
|
||||
or (Sess.SSHHost <> editSSHHost.Text)
|
||||
or (IntToStr(Sess.SSHPort) <> editSSHPort.Text)
|
||||
or (Sess.SSHPlinkExe <> editSSHPlinkExe.Text)
|
||||
|
||||
@@ -172,7 +172,7 @@ type
|
||||
TConnectionParameters = class(TObject)
|
||||
strict private
|
||||
FNetType: TNetType;
|
||||
FHostname, FUsername, FPassword, FAllDatabases, FStartupScriptFilename,
|
||||
FHostname, FUsername, FPassword, FAllDatabases, FComment, FStartupScriptFilename,
|
||||
FSessionPath, FSSLPrivateKey, FSSLCertificate, FSSLCACertificate, FServerVersion,
|
||||
FSSHHost, FSSHUser, FSSHPassword, FSSHPlinkExe, FSSHPrivateKey: String;
|
||||
FPort, FSSHPort, FSSHLocalPort, FSSHTimeout, FCounter: Integer;
|
||||
@@ -214,6 +214,7 @@ type
|
||||
property LoginPrompt: Boolean read FLoginPrompt write FLoginPrompt;
|
||||
property WindowsAuth: Boolean read FWindowsAuth write FWindowsAuth;
|
||||
property AllDatabasesStr: String read FAllDatabases write FAllDatabases;
|
||||
property Comment: String read FComment write FComment;
|
||||
property StartupScriptFilename: String read FStartupScriptFilename write FStartupScriptFilename;
|
||||
property Compressed: Boolean read FCompressed write FCompressed;
|
||||
property LocalTimeZone: Boolean read FLocalTimeZone write FLocalTimeZone;
|
||||
@@ -694,6 +695,7 @@ begin
|
||||
FWindowsAuth := AppSettings.ReadBool(asWindowsAuth);
|
||||
FPort := MakeInt(AppSettings.ReadString(asPort));
|
||||
FAllDatabases := AppSettings.ReadString(asDatabases);
|
||||
FComment := AppSettings.ReadString(asComment);
|
||||
FSSHHost := AppSettings.ReadString(asSSHtunnelHost);
|
||||
FSSHPort := AppSettings.ReadInt(asSSHtunnelHostPort);
|
||||
FSSHUser := AppSettings.ReadString(asSSHtunnelUser);
|
||||
@@ -743,6 +745,7 @@ begin
|
||||
AppSettings.WriteBool(asLocalTimeZone, FLocalTimeZone);
|
||||
AppSettings.WriteBool(asFullTableStatus, FFullTableStatus);
|
||||
AppSettings.WriteString(asDatabases, FAllDatabases);
|
||||
AppSettings.WriteString(asComment, FComment);
|
||||
AppSettings.WriteString(asStartupScriptFilename, FStartupScriptFilename);
|
||||
AppSettings.WriteString(asSSHtunnelHost, FSSHHost);
|
||||
AppSettings.WriteInt(asSSHtunnelHostPort, FSSHPort);
|
||||
|
||||
@@ -141,7 +141,7 @@ type
|
||||
asPlinkExecutable, asSSHtunnelHost, asSSHtunnelHostPort, asSSHtunnelPort, asSSHtunnelUser,
|
||||
asSSHtunnelPassword, asSSHtunnelTimeout, asSSHtunnelPrivateKey, asSSLActive, asSSLKey,
|
||||
asSSLCert, asSSLCA, asNetType, asCompressed, asLocalTimeZone,
|
||||
asStartupScriptFilename, asDatabases, asDatabaseFilter, asTableFilter, asExportSQLCreateDatabases,
|
||||
asStartupScriptFilename, asDatabases, asComment, asDatabaseFilter, asTableFilter, asExportSQLCreateDatabases,
|
||||
asExportSQLCreateTables, asExportSQLDataHow, asExportSQLFilenames, asExportZIPFilenames, asExportSQLDirectories,
|
||||
asExportSQLDatabase, asExportSQLServerDatabase, asExportSQLOutput, asGridExportOutputCopy, asGridExportOutputFile,
|
||||
asGridExportFilename, asGridExportRecentFiles, asGridExportEncoding, asGridExportFormat, asGridExportSelection,
|
||||
@@ -3144,6 +3144,7 @@ begin
|
||||
InitSetting(asLocalTimeZone, 'LocalTimeZone', 0, False, '', True);
|
||||
InitSetting(asStartupScriptFilename, 'StartupScriptFilename', 0, False, '', True);
|
||||
InitSetting(asDatabases, 'Databases', 0, False, '', True);
|
||||
InitSetting(asComment, 'Comment', 0, False, '', True);
|
||||
InitSetting(asDatabaseFilter, 'DatabaseFilter', 0, False, '');
|
||||
InitSetting(asTableFilter, 'TableFilter', 0, False, '');
|
||||
InitSetting(asExportSQLCreateDatabases, 'ExportSQL_CreateDatabases', 0, False);
|
||||
|
||||
Reference in New Issue
Block a user