summaryrefslogtreecommitdiffstats
path: root/libkdepim/progressmanager.cpp
diff options
context:
space:
mode:
authortpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2010-09-01 00:37:02 +0000
committertpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2010-09-01 00:37:02 +0000
commitcc29364f06178f8f6b457384f2ec37a042bd9d43 (patch)
tree7c77a3184c698bbf9d98cef09fb1ba8124daceba /libkdepim/progressmanager.cpp
parent4f6c584bacc8c3c694228f36ada3de77a76614a6 (diff)
downloadtdepim-cc29364f06178f8f6b457384f2ec37a042bd9d43.tar.gz
tdepim-cc29364f06178f8f6b457384f2ec37a042bd9d43.zip
* Massive set of changes to bring in all fixes and enhancements from the Enterprise PIM branch
* Ensured that the Trinity changes were applied on top of those enhancements, and any redundancy removed * Added journal read support to the CalDAV resource * Fixed CalDAV resource to use events URL for tasks and journals when separate URL checkbox unchecked git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdepim@1170461 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'libkdepim/progressmanager.cpp')
-rw-r--r--libkdepim/progressmanager.cpp17
1 files changed, 15 insertions, 2 deletions
diff --git a/libkdepim/progressmanager.cpp b/libkdepim/progressmanager.cpp
index 0c73e0c55..2e5f4d6eb 100644
--- a/libkdepim/progressmanager.cpp
+++ b/libkdepim/progressmanager.cpp
@@ -41,7 +41,7 @@ ProgressItem::ProgressItem(
:mId( id ), mLabel( label ), mStatus( status ), mParent( parent ),
mCanBeCanceled( canBeCanceled ), mProgress( 0 ), mTotal( 0 ),
mCompleted( 0 ), mWaitingForKids( false ), mCanceled( false ),
- mUsesCrypto( usesCrypto )
+ mUsesCrypto( usesCrypto ), mUsesBusyIndicator( false )
{}
ProgressItem::~ProgressItem()
@@ -123,6 +123,12 @@ void ProgressItem::setUsesCrypto( bool v )
emit progressItemUsesCrypto( this, v );
}
+void ProgressItem::setUsesBusyIndicator( bool useBusyIndicator )
+{
+ mUsesBusyIndicator = useBusyIndicator;
+ emit progressItemUsesBusyIndicator( this, useBusyIndicator );
+}
+
// ======================================
ProgressManager::ProgressManager() :TQObject() {
@@ -170,6 +176,8 @@ ProgressItem* ProgressManager::createProgressItemImpl(
this, TQT_SIGNAL( progressItemLabel(KPIM::ProgressItem*, const TQString&) ) );
connect ( t, TQT_SIGNAL( progressItemUsesCrypto(KPIM::ProgressItem*, bool) ),
this, TQT_SIGNAL( progressItemUsesCrypto(KPIM::ProgressItem*, bool) ) );
+ connect ( t, TQT_SIGNAL( progressItemUsesBusyIndicator(KPIM::ProgressItem*, bool) ),
+ this, TQT_SIGNAL( progressItemUsesBusyIndicator(KPIM::ProgressItem*, bool) ) );
emit progressItemAdded( t );
} else {
@@ -212,7 +220,12 @@ ProgressItem* ProgressManager::singleItem() const
ProgressItem *item = 0;
TQDictIterator< ProgressItem > it( mTransactions );
for ( ; it.current(); ++it ) {
- if ( !(*it)->parent() ) { // if it's a top level one, only those count
+
+ // No single item for progress possible, as one of them is a busy indicator one.
+ if ( (*it)->usesBusyIndicator() )
+ return 0;
+
+ if ( !(*it)->parent() ) { // if it's a top level one, only those count
if ( item )
return 0; // we found more than one
else