diff options
author | Giuseppe D'Angelo <giuseppe.dangelo@kdab.com> | 2012-12-18 00:31:11 +0100 |
---|---|---|
committer | The Qt Project <gerrit-noreply@qt-project.org> | 2013-05-27 15:19:41 +0200 |
commit | cada1fb4ef04b64593156be1190884c314d7c041 (patch) | |
tree | 5a57ed170b15fa05754b3592641f945bd273f222 /tests/manual | |
parent | 24466d354219048b808393a094fcf80ae5c99e39 (diff) |
Add QComboBox::currentData
Convenience function that returns user data for the current item,
analogous to currentText().
This avoids to having to write the cumbersome
QVariant variant = comboBox->itemData(comboBox->currentIndex());
(It's quite common to put strings as text and the corresponding
enum values as user data.)
Change-Id: I8c7632c647c5583d18e4e22703aeb4447d73162d
Reviewed-by: David Faure <david.faure@kdab.com>
Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
Diffstat (limited to 'tests/manual')
0 files changed, 0 insertions, 0 deletions