< prev index next >

src/java.desktop/windows/native/libawt/windows/awt_Component.cpp

Print this page

        

*** 3877,3899 **** void AwtComponent::OpenCandidateWindow(int x, int y) { UINT bits = 1; POINT p = {0, 0}; // upper left corner of the client area ! HWND hWnd = GetHWnd(); if (!::IsWindowVisible(hWnd)) { return; } HWND hTop = GetTopLevelParentForWindow(hWnd); ::ClientToScreen(hTop, &p); if (!m_bitsCandType) { ! SetCandidateWindow(m_bitsCandType, x - p.x, y - p.y); return; } for (int iCandType=0; iCandType<32; iCandType++, bits<<=1) { if ( m_bitsCandType & bits ) ! SetCandidateWindow(iCandType, x - p.x, y - p.y); } } void AwtComponent::SetCandidateWindow(int iCandType, int x, int y) { --- 3877,3901 ---- void AwtComponent::OpenCandidateWindow(int x, int y) { UINT bits = 1; POINT p = {0, 0}; // upper left corner of the client area ! HWND hWnd = ImmGetHWnd(); if (!::IsWindowVisible(hWnd)) { return; } HWND hTop = GetTopLevelParentForWindow(hWnd); ::ClientToScreen(hTop, &p); + int sx = ScaleUpX(x) - p.x; + int sy = ScaleUpX(y) - p.y; if (!m_bitsCandType) { ! SetCandidateWindow(m_bitsCandType, sx, sy); return; } for (int iCandType=0; iCandType<32; iCandType++, bits<<=1) { if ( m_bitsCandType & bits ) ! SetCandidateWindow(iCandType, sx, sy); } } void AwtComponent::SetCandidateWindow(int iCandType, int x, int y) {
< prev index next >