mirror of
https://github.com/subsurface/subsurface.git
synced 2024-11-28 05:00:20 +00:00
Fix broken translations in dive list filter plus simplify strings
Fix some broken translations in the dive list filter UI by adding Q_OBJECT line to the class definitions of filter classes. Plus simplify some strings given to translation by separating parts like ": ". Suggested-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at> Suggested-by: Jan Mulder <jlmulder@xs4all.nl> Signed-off-by: Stefan Fuchs <sfuchs@gmx.de>
This commit is contained in:
parent
d1060319d7
commit
56fda691ec
2 changed files with 9 additions and 4 deletions
|
@ -541,23 +541,23 @@ void FilterBase::hideEvent(QHideEvent *event)
|
|||
|
||||
TagFilter::TagFilter(QWidget *parent) : FilterBase(TagFilterModel::instance(), parent)
|
||||
{
|
||||
ui.label->setText(tr("Tags: "));
|
||||
ui.label->setText(tr("Tags") + QStringLiteral(": "));
|
||||
}
|
||||
|
||||
BuddyFilter::BuddyFilter(QWidget *parent) : FilterBase(BuddyFilterModel::instance(), parent)
|
||||
{
|
||||
ui.label->setText(tr("Person: "));
|
||||
ui.label->setText(tr("Person") + QStringLiteral(": "));
|
||||
ui.label->setToolTip(tr("Searches for buddies and divemasters"));
|
||||
}
|
||||
|
||||
LocationFilter::LocationFilter(QWidget *parent) : FilterBase(LocationFilterModel::instance(), parent)
|
||||
{
|
||||
ui.label->setText(tr("Location: "));
|
||||
ui.label->setText(tr("Location") + QStringLiteral(": "));
|
||||
}
|
||||
|
||||
SuitFilter::SuitFilter(QWidget *parent) : FilterBase(SuitsFilterModel::instance(), parent)
|
||||
{
|
||||
ui.label->setText(tr("Suits: "));
|
||||
ui.label->setText(tr("Suits") + QStringLiteral(": "));
|
||||
}
|
||||
|
||||
MultiFilter::MultiFilter(QWidget *parent) : QWidget(parent)
|
||||
|
|
|
@ -167,6 +167,7 @@ public:
|
|||
};
|
||||
|
||||
class FilterBase : public QWidget {
|
||||
Q_OBJECT
|
||||
void addContextMenuEntry(const QString &s, void (FilterModelBase::*)());
|
||||
protected:
|
||||
FilterBase(FilterModelBase *model, QWidget *parent = 0);
|
||||
|
@ -178,21 +179,25 @@ protected:
|
|||
};
|
||||
|
||||
class TagFilter : public FilterBase {
|
||||
Q_OBJECT
|
||||
public:
|
||||
TagFilter(QWidget *parent = 0);
|
||||
};
|
||||
|
||||
class BuddyFilter : public FilterBase {
|
||||
Q_OBJECT
|
||||
public:
|
||||
BuddyFilter(QWidget *parent = 0);
|
||||
};
|
||||
|
||||
class SuitFilter : public FilterBase {
|
||||
Q_OBJECT
|
||||
public:
|
||||
SuitFilter(QWidget *parent = 0);
|
||||
};
|
||||
|
||||
class LocationFilter : public FilterBase {
|
||||
Q_OBJECT
|
||||
public:
|
||||
LocationFilter(QWidget *parent = 0);
|
||||
};
|
||||
|
|
Loading…
Reference in a new issue