Return a valid name for "Other" page sizes.

This commit is contained in:
Jim Evins
2013-11-17 18:01:37 -05:00
parent f5bdbb98f9
commit eff40a7600
2 changed files with 9 additions and 0 deletions
+8
View File
@@ -53,10 +53,13 @@ namespace libglabels
QStringList Db::mVendorNames;
QList<Template*> Db::mTemplates;
QString Db::mPaperNameOther;
QString Db::mEmpty = "";
Db::Db()
{
mPaperNameOther = tr("Other");
readPapers();
readCategories();
readVendors();
@@ -141,6 +144,11 @@ namespace libglabels
{
if ( !id.isNull() && !id.isEmpty() )
{
if ( isPaperIdOther( id ) )
{
return mPaperNameOther;
}
const Paper *paper = lookupPaperFromId( id );
if ( paper != NULL )
{
+1
View File
@@ -128,6 +128,7 @@ namespace libglabels
static QList<Template*> mTemplates;
static QString mPaperNameOther;
static QString mEmpty;
};