summaryrefslogtreecommitdiff
path: root/UConfig.pas
diff options
context:
space:
mode:
authorTomas Bzatek <tbzatek@users.sourceforge.net>2008-11-15 13:30:43 +0100
committerTomas Bzatek <tbzatek@users.sourceforge.net>2008-11-15 13:30:43 +0100
commit7f89810e3c6ff92b0771ca11a817b82e081ccfa5 (patch)
treeb9dfae2f0e7c19e4aa4ba12af5a51fbf0a59e010 /UConfig.pas
parentf51fc44e0d479335b68650016b40813129039322 (diff)
downloadtuxcmd-7f89810e3c6ff92b0771ca11a817b82e081ccfa5.tar.xz
Connection Manager: Add ability not to save any passwords
Diffstat (limited to 'UConfig.pas')
-rw-r--r--UConfig.pas11
1 files changed, 10 insertions, 1 deletions
diff --git a/UConfig.pas b/UConfig.pas
index a23d4be..0ac1b21 100644
--- a/UConfig.pas
+++ b/UConfig.pas
@@ -113,6 +113,8 @@ var ConfPanelSep, ConfRowHeight, ConfRowHeightReal, ConfNumHistoryItems,
ApplicationShuttingDown: boolean;
ConfConnMgrActiveItem: integer;
+ ConfConnMgrDoNotSavePasswords, ConfConnMgrDoNotSynchronizeKeyring: boolean;
+
@@ -254,6 +256,8 @@ begin
ConfQuickRenameSkipExt := True;
ConfConnMgrActiveItem := 0;
ConfRightClickSelect := False;
+ ConfConnMgrDoNotSavePasswords := False;
+ ConfConnMgrDoNotSynchronizeKeyring := False;
// Setup default values for colors
@@ -936,6 +940,8 @@ begin
for i := 0 to Sections.Count - 1 do
if Sections[i] = '__General' then begin
ConfConnMgrActiveItem := IniFile.ReadInteger('__General', 'ConnMgrActiveItem', ConfConnMgrActiveItem);
+ ConfConnMgrDoNotSavePasswords := IniFile.ReadBool('__General', 'ConnMgrDoNotSavePasswords', ConfConnMgrDoNotSavePasswords);
+ ConfConnMgrDoNotSynchronizeKeyring := IniFile.ReadBool('__General', 'ConnMgrDoNotSynchronizeKeyring', ConfConnMgrDoNotSynchronizeKeyring);
end else begin
Item := TConnMgrItem.Create;
with Item do begin
@@ -976,6 +982,8 @@ begin
IniFile := TMyIniFile.Create(s, False);
try try
IniFile.WriteInteger('__General', 'ConnMgrActiveItem', ConfConnMgrActiveItem);
+ IniFile.WriteBool('__General', 'ConnMgrDoNotSavePasswords', ConfConnMgrDoNotSavePasswords);
+ IniFile.WriteBool('__General', 'ConnMgrDoNotSynchronizeKeyring', ConfConnMgrDoNotSynchronizeKeyring);
if ConnectionMgrList.Count > 0 then
for i := 0 to ConnectionMgrList.Count - 1 do
with TConnMgrItem(ConnectionMgrList[i]) do begin
@@ -984,7 +992,8 @@ begin
IniFile.WriteString(SectionTitle, 'ServiceType', ServiceType);
IniFile.WriteString(SectionTitle, 'Server', Server);
IniFile.WriteString(SectionTitle, 'Username', Username);
- IniFile.WriteString(SectionTitle, 'Password', Password);
+ if not ConfConnMgrDoNotSavePasswords then IniFile.WriteString(SectionTitle, 'Password', Password)
+ else IniFile.WriteString(SectionTitle, 'Password', '');
IniFile.WriteString(SectionTitle, 'TargetDir', TargetDir);
IniFile.WriteString(SectionTitle, 'PluginID', PluginID);
end;