summaryrefslogtreecommitdiffstats
path: root/src/gui/widgets
diff options
context:
space:
mode:
authorQt Continuous Integration System <qt-info@nokia.com>2011-07-22 20:11:20 (GMT)
committerQt Continuous Integration System <qt-info@nokia.com>2011-07-22 20:11:20 (GMT)
commitd625663620fd28dbd76bc423ff9deb7c7733b1dd (patch)
tree906a663c757463529cdf02e314be2c4e13d5b897 /src/gui/widgets
parentcfa6c0921a0832af1e01576be9688b9f7015e323 (diff)
parent75a891109a9fc7006ee241616a85290334b17012 (diff)
downloadQt-d625663620fd28dbd76bc423ff9deb7c7733b1dd.zip
Qt-d625663620fd28dbd76bc423ff9deb7c7733b1dd.tar.gz
Qt-d625663620fd28dbd76bc423ff9deb7c7733b1dd.tar.bz2
Merge branch 'master' of scm.dev.nokia.troll.no:qt/qt-water-staging into master-integration
* 'master' of scm.dev.nokia.troll.no:qt/qt-water-staging: Remove testing for Hide of mainwindow. Fix accessibility test for QWS. Fix test for win and mac. Add constants to QAccessible::Event enum. Call QAccessible::updateAccessibility when setText is called on QLabel Fix autotest for accessible tables. Style cleanup - space after flow control keywords. Add IAccessible2 table2 implementation. Fix a crash with QGraphicsScene. Use name for combobox on Unix. QProgressBar: transparent background on Windows Vista (partId: PP_BAR -> PP_TRANSPARENTBAR)
Diffstat (limited to 'src/gui/widgets')
-rw-r--r--src/gui/widgets/qcombobox.cpp18
-rw-r--r--src/gui/widgets/qlabel.cpp9
2 files changed, 27 insertions, 0 deletions
diff --git a/src/gui/widgets/qcombobox.cpp b/src/gui/widgets/qcombobox.cpp
index 621cae9..41394e3 100644
--- a/src/gui/widgets/qcombobox.cpp
+++ b/src/gui/widgets/qcombobox.cpp
@@ -80,6 +80,9 @@
#if defined(Q_WS_S60)
#include "private/qt_s60_p.h"
#endif
+#ifndef QT_NO_ACCESSIBILITY
+#include "qaccessible.h"
+#endif
QT_BEGIN_NAMESPACE
@@ -1018,6 +1021,9 @@ void QComboBoxPrivate::_q_dataChanged(const QModelIndex &topLeft, const QModelIn
}
q->update();
}
+#ifndef QT_NO_ACCESSIBILITY
+ QAccessible::updateAccessibility(q, 0, QAccessible::NameChanged);
+#endif
}
void QComboBoxPrivate::_q_rowsInserted(const QModelIndex &parent, int start, int end)
@@ -1271,6 +1277,9 @@ void QComboBoxPrivate::_q_emitCurrentIndexChanged(const QModelIndex &index)
Q_Q(QComboBox);
emit q->currentIndexChanged(index.row());
emit q->currentIndexChanged(itemText(index));
+#ifndef QT_NO_ACCESSIBILITY
+ QAccessible::updateAccessibility(q, 0, QAccessible::NameChanged);
+#endif
}
QString QComboBoxPrivate::itemText(const QModelIndex &index) const
@@ -2635,6 +2644,9 @@ void QComboBox::clear()
{
Q_D(QComboBox);
d->model->removeRows(0, d->model->rowCount(d->root), d->root);
+#ifndef QT_NO_ACCESSIBILITY
+ QAccessible::updateAccessibility(this, 0, QAccessible::NameChanged);
+#endif
}
/*!
@@ -2651,6 +2663,9 @@ void QComboBox::clearEditText()
Q_D(QComboBox);
if (d->lineEdit)
d->lineEdit->clear();
+#ifndef QT_NO_ACCESSIBILITY
+ QAccessible::updateAccessibility(this, 0, QAccessible::NameChanged);
+#endif
}
/*!
@@ -2661,6 +2676,9 @@ void QComboBox::setEditText(const QString &text)
Q_D(QComboBox);
if (d->lineEdit)
d->lineEdit->setText(text);
+#ifndef QT_NO_ACCESSIBILITY
+ QAccessible::updateAccessibility(this, 0, QAccessible::NameChanged);
+#endif
}
/*!
diff --git a/src/gui/widgets/qlabel.cpp b/src/gui/widgets/qlabel.cpp
index 26dd0e1..dcf35aa 100644
--- a/src/gui/widgets/qlabel.cpp
+++ b/src/gui/widgets/qlabel.cpp
@@ -55,6 +55,10 @@
#include "private/qstylesheetstyle_p.h"
#include <qmath.h>
+#ifndef QT_NO_ACCESSIBILITY
+#include <qaccessible.h>
+#endif
+
QT_BEGIN_NAMESPACE
/*!
@@ -370,6 +374,11 @@ void QLabel::setText(const QString &text)
#endif
d->updateLabel();
+
+#ifndef QT_NO_ACCESSIBILITY
+ if (accessibleName().isEmpty())
+ QAccessible::updateAccessibility(this, 0, QAccessible::NameChanged);
+#endif
}
QString QLabel::text() const