Commit 94792b17 authored by Albert Astals Cid's avatar Albert Astals Cid
Browse files

Make free/used in the summary view translatable

This is not a super great way to detect when the translation should
happen but the same "text comparison" is happening
RadialMap::Widget::mouseMoveEvent so it's not worse than existing code
parent d493aab3
Pipeline #159622 passed with stage
in 2 minutes and 23 seconds
......@@ -10,6 +10,8 @@
#include <QPainter>
#include <QVector>
#include <KLocalizedString>
#include "Config.h"
#include "fileTree.h"
#include "radialMap.h"
......@@ -295,7 +297,10 @@ void RadialMap::Widget::paintExplodedLabels(QPainter &paint) const
paint.drawLine(label->targetX, label->targetY, label->middleX, label->startY);
paint.drawLine(label->middleX, label->startY, label->startX, label->startY);
paint.drawText(label->textX, label->textY, label->qs);
QString text = label->qs;
if (isSummary() && text == QLatin1String("free")) text = i18nc("Free as in part of the disk that is free", "free");
else if (isSummary() && text == QLatin1String("used")) text = i18nc("Used as in part of the disk that is used", "used");
paint.drawText(label->textX, label->textY, text);
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