From 2672d9880a586abb2007faa3a0691375e06a9fc1 Mon Sep 17 00:00:00 2001 From: Marcin Miklas Date: Fri, 2 Apr 2010 15:40:44 +0200 Subject: New: Progress bar added to MComboBox. RevBy: Daniel d'Andrada Details: Now, for long taking selections, MComboBox can display progress indicator. I've added ProgressIndicatorVisible property to MComboBox and helper functions: showProgressIndicator, hideProgressIndicator My changes also required to update MContentItem, so I moved additionalItem to MContentItemModel class, and changed MContentItemView to update layout when additionalItem property is changed. WidgetsGallery comboboxpage updated to show new feature of MComboBox. --- src/corelib/widgets/mcombobox.cpp | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'src/corelib/widgets/mcombobox.cpp') diff --git a/src/corelib/widgets/mcombobox.cpp b/src/corelib/widgets/mcombobox.cpp index 262c17dc..ce6bfb7e 100644 --- a/src/corelib/widgets/mcombobox.cpp +++ b/src/corelib/widgets/mcombobox.cpp @@ -183,6 +183,11 @@ QString MComboBox::title() const return model()->title(); } +bool MComboBox::isProgressIndicatorVisible() const +{ + return model()->progressIndicatorVisible(); +} + void MComboBox::addItem(const QString &text) { insertItem(count(), text); @@ -351,6 +356,11 @@ void MComboBox::setTitle(const QString &title) model()->setTitle(title); } +void MComboBox::setProgressIndicatorVisible(bool enable) +{ + model()->setProgressIndicatorVisible(enable); +} + void MComboBox::setCurrentIndex(int index) { if (index == currentIndex()) return; -- cgit v1.2.3