QWindowsVistaStyle: fix QTextBrowser frame

Check for QAccessible::StaticText role in addition to EditableText, to
get correct frame for non-editable text widgets, such as QTextBrowser.

Task-number: QTBUG-24783
Change-Id: I2c3e4f4fa06c8122485b1bc6c1da04c7565c7223
Reviewed-by: Andy Shaw <andy.shaw@digia.com>
Reviewed-by: Jens Bache-Wiig <jens.bache-wiig@digia.com>
This commit is contained in:
J-P Nurmi 2013-03-20 12:30:49 +01:00 committed by The Qt Project
parent f9d856b3f5
commit 3a6d0bbde6

View File

@ -521,7 +521,8 @@ void QWindowsVistaStyle::drawPrimitive(PrimitiveElement element, const QStyleOpt
break;
case PE_Frame: {
#ifndef QT_NO_ACCESSIBILITY
if (QStyleHelper::isInstanceOf(option->styleObject, QAccessible::EditableText)) {
if (QStyleHelper::isInstanceOf(option->styleObject, QAccessible::EditableText)
|| QStyleHelper::isInstanceOf(option->styleObject, QAccessible::StaticText)) {
#else
if (false) {
#endif