Permalink
Browse files

Some MythGallery translation fixes.

- Remove contatenations as their use cause problems in some languages.
- Change translation context.
  • Loading branch information...
1 parent c53542f commit aad4f63582397ceae4206d1aaf5eac2ded5b1a13 @nriendeau nriendeau committed Jun 30, 2012
Showing with 13 additions and 13 deletions.
  1. +10 −13 mythplugins/mythgallery/mythgallery/thumbview.cpp
  2. +3 −0 mythplugins/mythgallery/mythgallery/thumbview.h
@@ -124,20 +124,17 @@ QString ThumbItem::GetDescription(const QString &status,
if (!status.isEmpty())
info += status;
- info += "\n\n" + QObject::tr("Folder: ") + fi.dir().dirName();
- info += "\n" + QObject::tr("Created: ") + fi.created().toString();
- info += "\n" + QObject::tr("Modified: ") +
- fi.lastModified().toString();
- info += "\n" + QString(QObject::tr("Bytes") + ": %1").arg(fi.size());
- info += "\n" + QString(QObject::tr("Width") + ": %1 " +
- QObject::tr("pixels")).arg(sz.width());
- info += "\n" + QString(QObject::tr("Height") + ": %1 " +
- QObject::tr("pixels")).arg(sz.height());
- info += "\n" + QString(QObject::tr("Pixel Count") + ": %1 " +
- QObject::tr("megapixels"))
+ info += "\n\n" + QString(tr("Folder: %1")).arg(fi.dir().dirName());
+ //: %1 is the creation date
+ info += "\n" + QString(tr("Created: %1")).arg(fi.created().toString());
+ //: %1 is the modification date
+ info += "\n" + QString(tr("Modified: %1")).arg(fi.lastModified().toString());
+ info += "\n" + tr("Size: %n bytes", "", fi.size());
+ info += "\n" + tr("Width: %n pixel(s)", "", sz.width());
+ info += "\n" + tr("Height: %n pixel(s)", "", sz.height());
+ info += "\n" + QString(tr("Pixel Count: %1 megapixels"))
.arg((float) sz.width() * sz.height() * (1.0f/1000000.0f), 0, 'f', 2);
- info += "\n" + QString(QObject::tr("Rotation Angle") + ": %1 " +
- QObject::tr("degrees")).arg(angle);
+ info += "\n" + tr("Rotation Angle: %n degree(s)", "", angle);
return info;
}
@@ -8,12 +8,15 @@
#include <QList>
#include <QHash>
#include <QPixmap>
+#include <QCoreApplication>
class MythMediaDevice;
class QPixmap;
class ThumbItem
{
+ Q_DECLARE_TR_FUNCTIONS (ThumbItem)
+
public:
ThumbItem() :
m_name(QString::null), m_caption(QString::null),

0 comments on commit aad4f63

Please sign in to comment.