diff options
Diffstat (limited to 'win32/ScintillaWin.cxx')
-rw-r--r-- | win32/ScintillaWin.cxx | 25 |
1 files changed, 19 insertions, 6 deletions
diff --git a/win32/ScintillaWin.cxx b/win32/ScintillaWin.cxx index 9307373e3..3c35234c6 100644 --- a/win32/ScintillaWin.cxx +++ b/win32/ScintillaWin.cxx @@ -512,6 +512,8 @@ sptr_t ScintillaWin::WndProc(unsigned int iMessage, uptr_t wParam, sptr_t lParam if (cmd != LBN_SETFOCUS) ::SetFocus(MainHWND()); } + } else if (LoWord(wParam) == idCallTip) { + CallTipClick(); } Command(LoWord(wParam)); #endif @@ -1080,12 +1082,14 @@ void ScintillaWin::Paste() { void ScintillaWin::CreateCallTipWindow(PRectangle) { #ifdef TOTAL_CONTROL - ct.wCallTip = ::CreateWindow(callClassName, "ACallTip", - WS_VISIBLE | WS_CHILD, 100, 100, 150, 20, - MainHWND(), reinterpret_cast<HMENU>(idCallTip), - GetWindowInstance(MainHWND()), - &ct); - ct.wDraw = ct.wCallTip; + if (!ct.wCallTip.Created()) { + ct.wCallTip = ::CreateWindow(callClassName, "ACallTip", + WS_VISIBLE | WS_CHILD, 100, 100, 150, 20, + MainHWND(), reinterpret_cast<HMENU>(idCallTip), + GetWindowInstance(MainHWND()), + &ct); + ct.wDraw = ct.wCallTip; + } #endif } @@ -1951,6 +1955,15 @@ sptr_t PASCAL ScintillaWin::CTWndProc( } ::EndPaint(hWnd, &ps); return 0; + } else if (iMessage == WM_LBUTTONDOWN) { + ctp->MouseClick(Point::FromLong(lParam)); + ::SendMessage(::GetParent(hWnd), WM_COMMAND, + MAKELONG(::GetDlgCtrlID(hWnd), SCEN_CHANGE), + reinterpret_cast<LPARAM>(hWnd)); + return 0; + } else if (iMessage == WM_SETCURSOR) { + ::SetCursor(::LoadCursor(NULL,IDC_ARROW)); + return 0; } else { return ::DefWindowProc(hWnd, iMessage, wParam, lParam); } |