• R/O
  • SSH
  • HTTPS

ttssh2: Commit


Commit MetaInfo

Revision9181 (tree)
Time2021-02-23 01:00:55
Authorzmatsuo

Log Message

altを押しながらのキー入力ができなかったので修正

- r9152 からの不具合

Change Summary

Incremental Difference

--- trunk/teraterm/teraterm/vtwin.cpp (revision 9180)
+++ trunk/teraterm/teraterm/vtwin.cpp (revision 9181)
@@ -2562,16 +2562,28 @@
25622562 if (MetaKey(ts.MetaKey)) {
25632563 if (!KeybEnabled || (TalkStatus != IdTalkKeyb))
25642564 return;
2565+
25652566 char Code = nChar;
25662567 wchar_t u16;
2567- if (ts.Meta8Bit != IdMeta8BitRaw) {
2568- const char mb_str[2] = {(char)nChar | 0x80, 0};
2569- unsigned int u32;
2570- size_t mb_len = MBCPToUTF32(mb_str, 1, CP_ACP, &u32);
2571- if (mb_len == 0) {
2572- return;
2568+ switch (ts.Meta8Bit) {
2569+ case IdMeta8BitRaw:
2570+ Code = nChar;
2571+ break;
2572+ default:
2573+ if (IsWindowUnicode(HVTWin) == TRUE) {
2574+ u16 = nChar;
25732575 }
2574- u16 = (wchar_t)u32;
2576+ else {
2577+ if (ts.Meta8Bit != IdMeta8BitRaw) {
2578+ const char mb_str[2] = {(char)nChar, 0};
2579+ unsigned int u32;
2580+ size_t mb_len = MBCPToUTF32(mb_str, 1, CP_ACP, &u32);
2581+ if (mb_len == 0) {
2582+ return;
2583+ }
2584+ u16 = (wchar_t)u32;
2585+ }
2586+ }
25752587 }
25762588 for (unsigned int i = 1; i <= nRepCnt; i++) {
25772589 switch (ts.Meta8Bit) {
@@ -2583,7 +2595,7 @@
25832595 }
25842596 break;
25852597 case IdMeta8BitText:
2586- Code |= 0x80;
2598+ u16 |= 0x80;
25872599 CommTextOutW(&cv, &u16, 1);
25882600 if (ts.LocalEcho) {
25892601 CommTextEchoW(&cv, &u16, 1);
Show on old repository browser