| 854 |
SendDlgItemMessage(dlg, IDC_SSH_VERSION, EM_LIMITTEXT, |
SendDlgItemMessage(dlg, IDC_SSH_VERSION, EM_LIMITTEXT, |
| 855 |
NUM_ELEM(ssh_version) - 1, 0); |
NUM_ELEM(ssh_version) - 1, 0); |
| 856 |
|
|
| 857 |
if (pvar->settings.ssh_protocol_version == 2) { |
if (pvar->settings.ssh_protocol_version == 1) { |
|
SendDlgItemMessage(dlg, IDC_SSH_VERSION, CB_SETCURSEL, 1, 0); // SSH2 |
|
|
} else { |
|
| 858 |
SendDlgItemMessage(dlg, IDC_SSH_VERSION, CB_SETCURSEL, 0, 0); // SSH1 |
SendDlgItemMessage(dlg, IDC_SSH_VERSION, CB_SETCURSEL, 0, 0); // SSH1 |
| 859 |
|
} else { |
| 860 |
|
SendDlgItemMessage(dlg, IDC_SSH_VERSION, CB_SETCURSEL, 1, 0); // SSH2 |
| 861 |
} |
} |
| 862 |
|
|
| 863 |
if (IsDlgButtonChecked(dlg, IDC_HOSTSSH)) { |
if (IsDlgButtonChecked(dlg, IDC_HOSTSSH)) { |
| 902 |
// Host dialogにフォーカスをあてる (2004.10.2 yutaka) |
// Host dialogにフォーカスをあてる (2004.10.2 yutaka) |
| 903 |
{ |
{ |
| 904 |
HWND hwnd = GetDlgItem(dlg, IDC_HOSTNAME); |
HWND hwnd = GetDlgItem(dlg, IDC_HOSTNAME); |
| 905 |
SetFocus(dlg); |
|
| 906 |
SetFocus(hwnd); |
SetFocus(hwnd); |
| 907 |
//SendMessage(dlg, WM_COMMAND, IDC_HOSTTCPIP, 0); |
//SendMessage(hwnd, BM_SETCHECK, BST_CHECKED, 0); |
| 908 |
|
//style = GetClassLongPtr(hwnd, GCL_STYLE); |
| 909 |
|
//SetClassLongPtr(hwnd, GCL_STYLE, style | WS_TABSTOP); |
| 910 |
} |
} |
| 911 |
|
|
| 912 |
return TRUE; |
// SetFocus()でフォーカスをあわせた場合、FALSEを返す必要がある。 |
| 913 |
|
// TRUEを返すと、TABSTOP対象の一番はじめのコントロールが選ばれる。 |
| 914 |
|
// (2004.11.23 yutaka) |
| 915 |
|
return FALSE; |
| 916 |
|
//return TRUE; |
| 917 |
|
|
| 918 |
case WM_COMMAND: |
case WM_COMMAND: |
| 919 |
switch (LOWORD(wParam)) { |
switch (LOWORD(wParam)) { |
| 991 |
#endif /* INET6 */ |
#endif /* INET6 */ |
| 992 |
enable_dlg_items(dlg, IDC_HOSTCOMLABEL, IDC_HOSTCOM, FALSE); |
enable_dlg_items(dlg, IDC_HOSTCOMLABEL, IDC_HOSTCOM, FALSE); |
| 993 |
|
|
| 994 |
|
enable_dlg_items(dlg, IDC_SSH_VERSION_LABEL, IDC_SSH_VERSION_LABEL, TRUE); // disabled (2004.11.23 yutaka) |
| 995 |
if (IsDlgButtonChecked(dlg, IDC_HOSTSSH)) { |
if (IsDlgButtonChecked(dlg, IDC_HOSTSSH)) { |
| 996 |
enable_dlg_items(dlg, IDC_SSH_VERSION, IDC_SSH_VERSION, TRUE); |
enable_dlg_items(dlg, IDC_SSH_VERSION, IDC_SSH_VERSION, TRUE); |
| 997 |
} else { |
} else { |
| 998 |
enable_dlg_items(dlg, IDC_SSH_VERSION, IDC_SSH_VERSION, FALSE); // disabled |
enable_dlg_items(dlg, IDC_SSH_VERSION, IDC_SSH_VERSION, FALSE); // disabled |
| 999 |
} |
} |
| 1000 |
|
|
|
// Host dialogにフォーカスをあてる (2004.10.2 yutaka) |
|
|
{ |
|
|
HWND hwnd = GetDlgItem(dlg, IDC_HOSTNAME); |
|
|
SetFocus(dlg); |
|
|
SetFocus(hwnd); |
|
|
} |
|
|
|
|
| 1001 |
return TRUE; |
return TRUE; |
| 1002 |
|
|
| 1003 |
case IDC_HOSTSERIAL: |
case IDC_HOSTSERIAL: |
| 1009 |
IDC_HOSTTCPPROTOCOL, FALSE); |
IDC_HOSTTCPPROTOCOL, FALSE); |
| 1010 |
#endif /* INET6 */ |
#endif /* INET6 */ |
| 1011 |
enable_dlg_items(dlg, IDC_SSH_VERSION, IDC_SSH_VERSION, FALSE); // disabled |
enable_dlg_items(dlg, IDC_SSH_VERSION, IDC_SSH_VERSION, FALSE); // disabled |
| 1012 |
|
enable_dlg_items(dlg, IDC_SSH_VERSION_LABEL, IDC_SSH_VERSION_LABEL, FALSE); // disabled (2004.11.23 yutaka) |
| 1013 |
|
|
| 1014 |
return TRUE; |
return TRUE; |
| 1015 |
|
|
| 1972 |
return (1); |
return (1); |
| 1973 |
} |
} |
| 1974 |
#endif |
#endif |
| 1975 |
|
|
| 1976 |
|
|
| 1977 |
|
/* |
| 1978 |
|
* $Log: not supported by cvs2svn $ |
| 1979 |
|
* |
| 1980 |
|
*/ |