Commit af3ba6c2 authored by Elvis Angelaccio's avatar Elvis Angelaccio

Merge branch 'Applications/16.04'

* Applications/16.04:
  Fix starting Ark from Plasma 5.7
  archivemodel: check for ListJob errors
parents fefce76c 132743e5
......@@ -154,7 +154,6 @@ Type=Application
Terminal=false
X-DBUS-StartupType=Multi
X-DBUS-ServiceName=org.kde.ark
X-KDE-HasTempFileOption=true
Categories=Qt;KDE;Utility;Archiving;Compression;X-KDE-Utilities-File;
InitialPreference=3
Comment=Work with file archives
......
......@@ -833,16 +833,18 @@ void ArchiveModel::newEntry(const ArchiveEntry& receivedEntry, InsertBehaviour b
void ArchiveModel::slotLoadingFinished(KJob *job)
{
int i = 0;
foreach(const ArchiveEntry &entry, m_newArchiveEntries) {
newEntry(entry, DoNotNotifyViews);
i++;
}
beginResetModel();
endResetModel();
m_newArchiveEntries.clear();
if (!job->error()) {
int i = 0;
foreach(const ArchiveEntry &entry, m_newArchiveEntries) {
newEntry(entry, DoNotNotifyViews);
i++;
}
beginResetModel();
endResetModel();
m_newArchiveEntries.clear();
qCDebug(ARK) << "Added" << i << "entries to model";
qCDebug(ARK) << "Added" << i << "entries to model";
}
emit loadingFinished(job);
}
......
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