diff options
-rw-r--r-- | src/plugins/accessible/widgets/complexwidgets.cpp | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/src/plugins/accessible/widgets/complexwidgets.cpp b/src/plugins/accessible/widgets/complexwidgets.cpp index 8be1560..803786f 100644 --- a/src/plugins/accessible/widgets/complexwidgets.cpp +++ b/src/plugins/accessible/widgets/complexwidgets.cpp @@ -1512,10 +1512,14 @@ QString QAccessibleTabBar::text(Text t, int child) const default: break; } - } else if (child > 0) { + } else { switch (t) { case Name: - return qt_accStripAmp(tabBar()->tabText(child - 1)); + if (child > 0) + return qt_accStripAmp(tabBar()->tabText(child - 1)); + else if (tabBar()->currentIndex() != -1) + return qt_accStripAmp(tabBar()->tabText(tabBar()->currentIndex())); + break; default: break; } |