Commit 6aea1aac authored by Scott Wheeler's avatar Scott Wheeler

Update the status bar while loading.

svn path=/trunk/kdemultimedia/juk/; revision=335828
parent c3adc45a
......@@ -1414,7 +1414,8 @@ void Playlist::calculateColumnWeights()
PlaylistItem *Playlist::addFile(const QString &file, bool importPlaylists,
PlaylistItem *after)
{
processEvents();
if(processEvents())
m_collection->dataChanged();
const QFileInfo fileInfo = QDir::cleanDirPath(file);
......@@ -1893,14 +1894,16 @@ QDataStream &operator>>(QDataStream &s, Playlist &p)
return s;
}
void processEvents()
bool processEvents()
{
static QTime time = QTime::currentTime();
if(time.elapsed() > 200) {
time.restart();
kapp->processEvents();
return true;
}
return false;
}
#include "playlist.moc"
......@@ -598,7 +598,7 @@ private:
static QMap<int, PlaylistItem *> m_backMenuItems;
};
void processEvents();
bool processEvents();
QDataStream &operator<<(QDataStream &s, Playlist &p);
QDataStream &operator>>(QDataStream &s, Playlist &p);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment