From 4b450ea4b601cdb2fe0a2ee42170a6b552738a52 Mon Sep 17 00:00:00 2001 From: Gluzskiy Alexandr Date: Mon, 16 Aug 2010 03:49:17 +0300 Subject: modified: main.cpp modified: new_gpg.rc modified: options.cpp --- main.cpp | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) (limited to 'main.cpp') diff --git a/main.cpp b/main.cpp index a339d6d..5c98c2c 100644 --- a/main.cpp +++ b/main.cpp @@ -355,7 +355,9 @@ static BOOL CALLBACK DlgProcKeyGenDialog(HWND hwndDlg, UINT msg, WPARAM wParam, { TranslateDialogDefault(hwndDlg); ComboBoxAddStringUtf(GetDlgItem(hwndDlg, IDC_KEY_TYPE), _T("RSA"), 0); - ComboBoxAddStringUtf(GetDlgItem(hwndDlg, IDC_KEY_TYPE), _T("DSA"), 0); + ComboBoxAddStringUtf(GetDlgItem(hwndDlg, IDC_KEY_TYPE), _T("DSA"), 1); + SetDlgItemInt(hwndDlg, IDC_KEY_EXPIRE_DATE, 0, 0); + SetDlgItemInt(hwndDlg, IDC_KEY_LENGTH, 2048, 0); return TRUE; } @@ -655,7 +657,7 @@ static BOOL CALLBACK DlgProcLoadExistingKey(HWND hwndDlg,UINT msg,WPARAM wParam, DWORD code; string::size_type p = 0, p2 = 0, stop = 0; { - wstring cmd = _T("--list-secret-keys"); + wstring cmd = _T("--list-keys"); if(pxExecute(&cmd, "", &out, &code) == pxNotFound) { MessageBox(0, _T("Set path to gpg.exe first!"), _T("Warning"), MB_OK); @@ -665,7 +667,7 @@ static BOOL CALLBACK DlgProcLoadExistingKey(HWND hwndDlg,UINT msg,WPARAM wParam, cp866_to_cp1251(&out); while(p != string::npos) { - if((p = out.find("sec ", p)) == string::npos) + if((p = out.find("pub ", p)) == string::npos) break; p += 5; if(p < stop) @@ -693,7 +695,7 @@ static BOOL CALLBACK DlgProcLoadExistingKey(HWND hwndDlg,UINT msg,WPARAM wParam, tmp = mir_a2t(out.substr(p,p2-p).c_str()); ListView_SetItemText(hwndList, iRow, 1, tmp); mir_free(tmp); - p = out.find("ssb ", p2) + 6; + p = out.find("sub ", p2) + 6; p = out.find(" ", p) + 1; p2 = out.find("\n", p); tmp = mir_a2t(out.substr(p,p2-p-1).c_str()); -- cgit v1.2.3