mirror of https://github.com/qt/qtbase.git
Handle coordinates related to component window
AtSpiAdaptor::componentInterface was not checking the coordinate type in GetAccessibleAtPoint. Now, if the coordinate type is ATSPI_COORD_TYPE_WINDOW the coordinates of the window will be added to the specified coordinates. Change-Id: Iba571109a8da300f4141d616a94ef4ac87918f98 Reviewed-by: Jesus Fernandez <Jesus.Fernandez@qt.io> Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io>
This commit is contained in:
parent
cf1b732e21
commit
a0717c60b3
|
@ -1601,7 +1601,13 @@ bool AtSpiAdaptor::componentInterface(QAccessibleInterface *interface, const QSt
|
|||
int x = message.arguments().at(0).toInt();
|
||||
int y = message.arguments().at(1).toInt();
|
||||
uint coordType = message.arguments().at(2).toUInt();
|
||||
Q_UNUSED (coordType) // FIXME
|
||||
if (coordType == ATSPI_COORD_TYPE_WINDOW) {
|
||||
QWindow * window = interface->window();
|
||||
if (window) {
|
||||
x += window->position().x();
|
||||
y += window->position().y();
|
||||
}
|
||||
}
|
||||
|
||||
QAccessibleInterface * childInterface(interface->childAt(x, y));
|
||||
QAccessibleInterface * iface = 0;
|
||||
|
|
Loading…
Reference in New Issue