Changeset View
Changeset View
Standalone View
Standalone View
intern/ghost/intern/GHOST_WindowX11.cpp
| Show First 20 Lines • Show All 658 Lines • ▼ Show 20 Lines | |||||
| void GHOST_WindowX11::screenToClient(int32_t inX, int32_t inY, int32_t &outX, int32_t &outY) const | void GHOST_WindowX11::screenToClient(int32_t inX, int32_t inY, int32_t &outX, int32_t &outY) const | ||||
| { | { | ||||
| /* This is correct! */ | /* This is correct! */ | ||||
| int ax, ay; | int ax, ay; | ||||
| Window temp; | Window temp; | ||||
| XTranslateCoordinates( | XTranslateCoordinates( | ||||
| m_display, RootWindow(m_display, m_visualInfo->screen), m_window, inX, inY, &ax, &ay, &temp); | m_display, RootWindow(m_display, m_visualInfo->screen), m_window, 0, 0, &ax, &ay, &temp); | ||||
| outX = ax; | outX = ax + inX; | ||||
| outY = ay; | outY = ay + inY; | ||||
| } | } | ||||
| void GHOST_WindowX11::clientToScreen(int32_t inX, int32_t inY, int32_t &outX, int32_t &outY) const | void GHOST_WindowX11::clientToScreen(int32_t inX, int32_t inY, int32_t &outX, int32_t &outY) const | ||||
| { | { | ||||
| int ax, ay; | int ax, ay; | ||||
| Window temp; | Window temp; | ||||
| XTranslateCoordinates( | XTranslateCoordinates( | ||||
| ▲ Show 20 Lines • Show All 1,077 Lines • Show Last 20 Lines | |||||