connect(m_view, SIGNAL(redirection(KUrl,KUrl)), this, SLOT(redirect(KUrl,KUrl)));
connect(m_view, SIGNAL(directoryLoadingStarted()), this, SLOT(slotDirectoryLoadingStarted()));
connect(m_view, SIGNAL(directoryLoadingCompleted()), this, SLOT(slotDirectoryLoadingCompleted()));
+ connect(m_view, SIGNAL(directoryLoadingCanceled()), this, SLOT(slotDirectoryLoadingCanceled()));
connect(m_view, SIGNAL(itemCountChanged()), this, SLOT(delayedStatusBarUpdate()));
connect(m_view, SIGNAL(directoryLoadingProgress(int)), this, SLOT(updateDirectoryLoadingProgress(int)));
connect(m_view, SIGNAL(directorySortingProgress(int)), this, SLOT(updateDirectorySortingProgress(int)));
}
}
+void DolphinViewContainer::slotDirectoryLoadingCanceled()
+{
+ if (!m_statusBar->progressText().isEmpty()) {
+ m_statusBar->setProgressText(QString());
+ m_statusBar->setProgress(100);
+ }
+
+ showErrorMessage("Directory loading has been canceled.");
+}
+
void DolphinViewContainer::slotUrlIsFileError(const KUrl& url)
{
const KFileItem item(KFileItem::Unknown, KFileItem::Unknown, url);
*/
void slotDirectoryLoadingCompleted();
+ /**
+ * Updates the statusbar to show, that the directory loading has
+ * been canceled.
+ */
+ void slotDirectoryLoadingCanceled();
+
/**
* Is called if the URL set by DolphinView::setUrl() represents
* a file and not a directory. Takes care to activate the file.
{
m_maximumUpdateIntervalTimer->stop();
dispatchPendingItemsToInsert();
+
+ emit directoryLoadingCanceled();
}
void KFileItemModel::slotNewItems(const KFileItemList& items)
*/
void directoryLoadingCompleted();
+ /**
+ * Is emitted after the loading of a directory has been canceled.
+ */
+ void directoryLoadingCanceled();
+
/**
* Informs about the progress in percent when loading a directory. It is assured
* that the signal directoryLoadingStarted() has been emitted before.
connect(m_model, SIGNAL(directoryLoadingStarted()), this, SLOT(slotDirectoryLoadingStarted()));
connect(m_model, SIGNAL(directoryLoadingCompleted()), this, SLOT(slotDirectoryLoadingCompleted()));
+ connect(m_model, SIGNAL(directoryLoadingCanceled()), this, SIGNAL(directoryLoadingCanceled()));
connect(m_model, SIGNAL(directoryLoadingProgress(int)), this, SIGNAL(directoryLoadingProgress(int)));
connect(m_model, SIGNAL(directorySortingProgress(int)), this, SIGNAL(directorySortingProgress(int)));
connect(m_model, SIGNAL(itemsChanged(KItemRangeList,QSet<QByteArray>)),
*/
void directoryLoadingCompleted();
+ /**
+ * Is emitted after the directory loading triggered by DolphinView::setUrl()
+ * has been canceled.
+ */
+ void directoryLoadingCanceled();
+
/**
* Is emitted after DolphinView::setUrl() has been invoked and provides
* the information how much percent of the current directory have been loaded.