From: Sebastian Trueg Date: Thu, 17 Apr 2008 12:03:10 +0000 (+0000) Subject: Fallback to filename after all if no proper fileitem is available. Sorry, the code... X-Git-Url: https://cloud.milkyroute.net/gitweb/dolphin.git/commitdiff_plain/16b9d9bc197aad5e33c2f1957ba782f5097253cb?ds=inline Fallback to filename after all if no proper fileitem is available. Sorry, the code is a bit confusing svn path=/trunk/KDE/kdebase/apps/; revision=798078 --- diff --git a/src/infosidebarpage.cpp b/src/infosidebarpage.cpp index 9d5ce0f6a..c783252f7 100644 --- a/src/infosidebarpage.cpp +++ b/src/infosidebarpage.cpp @@ -261,7 +261,7 @@ void InfoSidebarPage::showItemInfo() connect(job, SIGNAL(failed(const KFileItem&)), this, SLOT(showIcon(const KFileItem&))); - m_nameLabel->setText( !m_fileItem.isNull() && selectedItems.isEmpty() ? m_fileItem.text() : selectedItems[0].text() ); + m_nameLabel->setText( !m_fileItem.isNull() && selectedItems.isEmpty() ? m_fileItem.text() : ( !selectedItems.isEmpty() ? selectedItems[0].text() : file.fileName() ) ); } showMetaInfo();