| 2196 |
|
|
| 2197 |
static BOOL CALLBACK hosts_updatekey_dlg_proc(HWND dlg, UINT msg, WPARAM wParam, LPARAM lParam) |
static BOOL CALLBACK hosts_updatekey_dlg_proc(HWND dlg, UINT msg, WPARAM wParam, LPARAM lParam) |
| 2198 |
{ |
{ |
|
// static HFONT DlgHostsAddFont; |
|
| 2199 |
PTInstVar pvar; |
PTInstVar pvar; |
|
// LOGFONT logfont; |
|
|
// HFONT font; |
|
| 2200 |
char buf[1024]; |
char buf[1024]; |
| 2201 |
char *host; |
char *host; |
| 2202 |
struct hostkeys_update_ctx *ctx; |
struct hostkeys_update_ctx *ctx; |
| 2244 |
GetDlgItemText(dlg, IDCANCEL, uimsg, sizeof(uimsg)); |
GetDlgItemText(dlg, IDCANCEL, uimsg, sizeof(uimsg)); |
| 2245 |
UTIL_get_lang_msg("BTN_NO", pvar, uimsg); |
UTIL_get_lang_msg("BTN_NO", pvar, uimsg); |
| 2246 |
SetDlgItemText(dlg, IDCANCEL, pvar->ts->UIMsg); |
SetDlgItemText(dlg, IDCANCEL, pvar->ts->UIMsg); |
| 2247 |
#if 0 |
|
|
font = (HFONT)SendMessage(dlg, WM_GETFONT, 0, 0); |
|
|
GetObject(font, sizeof(LOGFONT), &logfont); |
|
|
if (UTIL_get_lang_font("DLG_TAHOMA_FONT", dlg, &logfont, &DlgHostsAddFont, pvar)) { |
|
|
SendDlgItemMessage(dlg, IDC_HOSTKEY_MESSAGE, WM_SETFONT, (WPARAM)DlgHostsAddFont, MAKELPARAM(TRUE, 0)); |
|
|
SendDlgItemMessage(dlg, IDC_ADDKEY_TEXT, WM_SETFONT, (WPARAM)DlgHostsAddFont, MAKELPARAM(TRUE, 0)); |
|
|
SendDlgItemMessage(dlg, IDC_FP_HASH_ALG, WM_SETFONT, (WPARAM)DlgHostsAddFont, MAKELPARAM(TRUE, 0)); |
|
|
SendDlgItemMessage(dlg, IDC_FP_HASH_ALG_MD5, WM_SETFONT, (WPARAM)DlgHostsAddFont, MAKELPARAM(TRUE, 0)); |
|
|
SendDlgItemMessage(dlg, IDC_FP_HASH_ALG_SHA256, WM_SETFONT, (WPARAM)DlgHostsAddFont, MAKELPARAM(TRUE, 0)); |
|
|
SendDlgItemMessage(dlg, IDC_ADDKEY_EDIT, WM_SETFONT, (WPARAM)DlgHostsAddFont, MAKELPARAM(TRUE, 0)); |
|
|
SendDlgItemMessage(dlg, IDC_REMOVEKEY_TEXT, WM_SETFONT, (WPARAM)DlgHostsAddFont, MAKELPARAM(TRUE, 0)); |
|
|
SendDlgItemMessage(dlg, IDC_REMOVEKEY_EDIT, WM_SETFONT, (WPARAM)DlgHostsAddFont, MAKELPARAM(TRUE, 0)); |
|
|
SendDlgItemMessage(dlg, IDOK, WM_SETFONT, (WPARAM)DlgHostsAddFont, MAKELPARAM(TRUE, 0)); |
|
|
SendDlgItemMessage(dlg, IDCANCEL, WM_SETFONT, (WPARAM)DlgHostsAddFont, MAKELPARAM(TRUE, 0)); |
|
|
} |
|
|
else { |
|
|
DlgHostsAddFont = NULL; |
|
|
} |
|
|
#endif |
|
| 2248 |
CenterWindow(dlg, GetParent(dlg)); |
CenterWindow(dlg, GetParent(dlg)); |
| 2249 |
return TRUE; /* because we do not set the focus */ |
return TRUE; /* because we do not set the focus */ |
| 2250 |
|
|
| 2253 |
|
|
| 2254 |
switch (LOWORD(wParam)) { |
switch (LOWORD(wParam)) { |
| 2255 |
case IDOK: |
case IDOK: |
|
|
|
| 2256 |
EndDialog(dlg, 1); |
EndDialog(dlg, 1); |
|
#if 0 |
|
|
if (DlgHostsAddFont != NULL) { |
|
|
DeleteObject(DlgHostsAddFont); |
|
|
} |
|
|
#endif |
|
| 2257 |
return TRUE; |
return TRUE; |
| 2258 |
|
|
| 2259 |
case IDCANCEL: /* kill the connection */ |
case IDCANCEL: /* kill the connection */ |
| 2260 |
EndDialog(dlg, 0); |
EndDialog(dlg, 0); |
|
#if 0 |
|
|
if (DlgHostsAddFont != NULL) { |
|
|
DeleteObject(DlgHostsAddFont); |
|
|
} |
|
|
#endif |
|
| 2261 |
return TRUE; |
return TRUE; |
| 2262 |
|
|
| 2263 |
case IDC_FP_HASH_ALG_MD5: |
case IDC_FP_HASH_ALG_MD5: |