Commit ca35c71f authored by Nicolas Fella's avatar Nicolas Fella Committed by Nate Graham
Browse files

Improve placeholder message for unassigned tag

When opening tags:/ we show 'No tags' when there are no tags found.

When opening a tag that exists but doesn't have any files associated we show the same message, which isnt't appropriate.

Instead show "No files tagged with 'foo'", which makes more sense
parent 1c5b6d4d
Pipeline #131324 passed with stage
in 6 minutes and 14 seconds
......@@ -2166,7 +2166,13 @@ void DolphinView::updatePlaceholderLabel()
} else if (m_url.scheme() == QLatin1String("trash") && m_url.path() == QLatin1String("/")) {
m_placeholderLabel->setText(i18n("Trash is empty"));
} else if (m_url.scheme() == QLatin1String("tags")) {
m_placeholderLabel->setText(i18n("No tags"));
if (m_url.path() == QLatin1Char('/')) {
m_placeholderLabel->setText(i18n("No tags"));
} else {
const QString tagName = m_url.path().mid(1); // Remove leading /
m_placeholderLabel->setText(i18n("No files tagged with \"%1\"", tagName));
} else if (m_url.scheme() == QLatin1String("recentlyused")) {
m_placeholderLabel->setText(i18n("No recently used items"));
} else if (m_url.scheme() == QLatin1String("smb")) {
Supports Markdown
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