From 2e6acc23cd9a22166b704d9def02568be5f9f0ec Mon Sep 17 00:00:00 2001 From: Albert Astals Cid Date: Wed, 19 Mar 2025 00:33:55 +0100 Subject: [PATCH] macOS: Remove check for NSAccessibilityCellRole when synthesizing role We check for `!synthesizedRole` before entering this code, which means the role can not be NSAccessibilityCellRole either, as the synthesized role is initialized from the role. Change-Id: I8ea4a09f770901f34f41f52c8d736d70152d3312 Reviewed-by: Volker Hilsheimer --- src/plugins/platforms/cocoa/qcocoaaccessibilityelement.mm | 4 ---- 1 file changed, 4 deletions(-) diff --git a/src/plugins/platforms/cocoa/qcocoaaccessibilityelement.mm b/src/plugins/platforms/cocoa/qcocoaaccessibilityelement.mm index 7a05205c248..196ea3c3ea7 100644 --- a/src/plugins/platforms/cocoa/qcocoaaccessibilityelement.mm +++ b/src/plugins/platforms/cocoa/qcocoaaccessibilityelement.mm @@ -125,10 +125,6 @@ static void convertLineOffset(QAccessibleTextInterface *text, int *line, int *of if (iface->tableInterface()) { [self updateTableModel]; } else if (const auto *cell = iface->tableCellInterface()) { - // Called with role when populating a row with placeholder cells. The caller - // inserts us into the correct array, so we don't have to look for it. - if (role == NSAccessibilityCellRole) - return self; // If we create an element for a table cell, initialize it with row/column // and insert it into the corresponding row's columns array. m_rowIndex = cell->rowIndex();