summaryrefslogtreecommitdiff
path: root/main.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'main.cpp')
-rw-r--r--main.cpp51
1 files changed, 26 insertions, 25 deletions
diff --git a/main.cpp b/main.cpp
index 8d12350..43c78e3 100644
--- a/main.cpp
+++ b/main.cpp
@@ -1,4 +1,4 @@
-// Copyright © 2010 sss
+// Copyright � 2010 sss
//
// This program is free software; you can redistribute it and/or
// modify it under the terms of the GNU General Public License
@@ -604,6 +604,7 @@ static BOOL CALLBACK DlgProcGpgBinOpts(HWND hwndDlg, UINT msg, WPARAM wParam, LP
mir_free(tmp);
if(gpg_exists && lang_exists && !bad_version)
MessageBox(0, _T("You have supported version of gpg binary, and gpg language file in place!\ngpg plugin should work fine on your installation!\njust press ok in wollowing diallog."), _T("Info"), MB_OK);
+ CheckDlgButton(hwndDlg, IDC_AUTO_EXCHANGE, 1);
extern bool bIsMiranda09;
EnableWindow(GetDlgItem(hwndDlg, IDC_AUTO_EXCHANGE), bIsMiranda09);
return TRUE;
@@ -717,15 +718,15 @@ static BOOL CALLBACK DlgProcGpgBinOpts(HWND hwndDlg, UINT msg, WPARAM wParam, LP
MessageBox(0, _T("please set keyring's home directory"), _T("Warning"), MB_OK);
break;
}
- DBWriteContactSettingTString(NULL, szGPGModuleName, "szHomePath", tmp);
- {
- TCHAR *path = UniGetContactSettingUtf(NULL, szGPGModuleName, "szHomePath", _T(""));
- DWORD dwFileAttr = GetFileAttributes(path);
- if (dwFileAttr != INVALID_FILE_ATTRIBUTES)
- {
- dwFileAttr &=~ FILE_ATTRIBUTE_READONLY;
- SetFileAttributes(path, dwFileAttr);
- }
+ DBWriteContactSettingTString(NULL, szGPGModuleName, "szHomePath", tmp);
+ {
+ TCHAR *path = UniGetContactSettingUtf(NULL, szGPGModuleName, "szHomePath", _T(""));
+ DWORD dwFileAttr = GetFileAttributes(path);
+ if (dwFileAttr != INVALID_FILE_ATTRIBUTES)
+ {
+ dwFileAttr &=~ FILE_ATTRIBUTE_READONLY;
+ SetFileAttributes(path, dwFileAttr);
+ }
mir_free(path);
}
gpg_configured = true;
@@ -800,15 +801,15 @@ static BOOL CALLBACK DlgProcGpgBinOpts(HWND hwndDlg, UINT msg, WPARAM wParam, LP
{
MessageBox(0, _T("please set keyring's home directory"), _T("Warning"), MB_OK);
break;
- }
- DBWriteContactSettingTString(NULL, szGPGModuleName, "szHomePath", tmp);
- {
- TCHAR *path = UniGetContactSettingUtf(NULL, szGPGModuleName, "szHomePath", _T(""));
- DWORD dwFileAttr = GetFileAttributes(path);
- if (dwFileAttr != INVALID_FILE_ATTRIBUTES)
- {
- dwFileAttr &=~ FILE_ATTRIBUTE_READONLY;
- SetFileAttributes(path, dwFileAttr);
+ }
+ DBWriteContactSettingTString(NULL, szGPGModuleName, "szHomePath", tmp);
+ {
+ TCHAR *path = UniGetContactSettingUtf(NULL, szGPGModuleName, "szHomePath", _T(""));
+ DWORD dwFileAttr = GetFileAttributes(path);
+ if (dwFileAttr != INVALID_FILE_ATTRIBUTES)
+ {
+ dwFileAttr &=~ FILE_ATTRIBUTE_READONLY;
+ SetFileAttributes(path, dwFileAttr);
}
mir_free(path);
}
@@ -1700,12 +1701,12 @@ void InitCheck()
if(MessageBoxA(0, question.c_str(), "Own secret key warning", MB_YESNO) == IDYES)
ShowFirstRunDialog();
}
- {
- TCHAR *path = UniGetContactSettingUtf(NULL, szGPGModuleName, "szHomePath", _T(""));
- DWORD dwFileAttr = GetFileAttributes(path);
- if (dwFileAttr != INVALID_FILE_ATTRIBUTES)
- {
- dwFileAttr &=~ FILE_ATTRIBUTE_READONLY;
+ {
+ TCHAR *path = UniGetContactSettingUtf(NULL, szGPGModuleName, "szHomePath", _T(""));
+ DWORD dwFileAttr = GetFileAttributes(path);
+ if (dwFileAttr != INVALID_FILE_ATTRIBUTES)
+ {
+ dwFileAttr &=~ FILE_ATTRIBUTE_READONLY;
SetFileAttributes(path, dwFileAttr);
}
mir_free(path);