~ubuntu-branches/ubuntu/trusty/kdepimlibs/trusty

« back to all changes in this revision

Viewing changes to akonadi/itemfetchjob.cpp

  • Committer: Package Import Robot
  • Author(s): Jonathan Riddell
  • Date: 2014-04-10 21:53:31 UTC
  • mfrom: (1.1.112)
  • Revision ID: package-import@ubuntu.com-20140410215331-4skq50lp0ru1pdxo
Tags: 4:4.13.0-0ubuntu1
New upstream KDE Software Compilation release

Show diffs side-by-side

added added

removed removed

Lines of Context:
61
61
      mEmitTimer->setSingleShot( true );
62
62
      mEmitTimer->setInterval( 100 );
63
63
      q->connect( mEmitTimer, SIGNAL(timeout()), q, SLOT(timeout()) );
64
 
      q->connect( q, SIGNAL(result(KJob*)), q, SLOT(timeout()) );
 
64
    }
 
65
 
 
66
    void aboutToFinish()
 
67
    {
 
68
      timeout();
65
69
    }
66
70
 
67
71
    void timeout()
68
72
    {
69
73
      Q_Q( ItemFetchJob );
70
74
 
71
 
      mEmitTimer->stop(); // in case we are called by result()
 
75
      mEmitTimer->stop(); // in case we are called by aboutToFinish()
72
76
      if ( !mPendingItems.isEmpty() ) {
73
77
        if ( !q->error() )
74
78
          emit q->itemsReceived( mPendingItems );