Windowsでコンパイルエラーの修正
諏訪子 <suwako@076.moe>、2026-05-03 19:30
コミット 8fa73f993816ebedd8b584aa0ace8eb0b44706a8
・親 07d377f
・ファイルを見る
1個のファイル、+10 -0
| @@ -763,12 +763,22 @@ | ||
| 763 | 763 | } |
| 764 | 764 | |
| 765 | 765 | void HexEditor::handleMouse() { |
| 766 | +#ifdef _WIN32 | |
| 767 | + if (getmouse() == 0) return; | |
| 768 | + | |
| 769 | + int mx = Mouse_status.x; | |
| 770 | + int my = Mouse_status.y; | |
| 771 | + | |
| 772 | + if (!(Mouse_status.button[0] & BUTTON1_PRESSED) | |
| 773 | + || (Mouse_status.changes & 0x01)) return; | |
| 774 | +#else | |
| 766 | 775 | MEVENT event; |
| 767 | 776 | if (getmouse(&event) != OK) return; |
| 768 | 777 | if (!(event.bstate & BUTTON1_PRESSED)) return; |
| 769 | 778 | |
| 770 | 779 | int mx = event.x; |
| 771 | 780 | int my = event.y; |
| 781 | +#endif | |
| 772 | 782 | if (my == 0 || my == rows - 1) return; |
| 773 | 783 | |
| 774 | 784 | if (my >= 1 && my < rows - 2 && mx < cols / 2) { |