Added sketchplugin project
This commit is contained in:
1 parent
9d3853fc07
commit
40168628c2
8 files changed
+80
No files matched your search
@@ -0,0 +1,26 @@
|
||||
#include "sketchplugin.h"
|
||||
|
||||
#include <QDebug>
|
||||
#include <QDir>
|
||||
#include <QCoreApplication>
|
||||
#include <QLocale>
|
||||
|
||||
SketchPlugin::SketchPlugin(QObject *parent) :
|
||||
ZeiterfassungPlugin(parent)
|
||||
{
|
||||
qDebug() << "called";
|
||||
|
||||
static auto dir = QDir(QCoreApplication::applicationDirPath()).absoluteFilePath(QStringLiteral("translations"));
|
||||
|
||||
if(m_translator.load(QLocale(), QStringLiteral("sketchplugin"), QStringLiteral("_"), dir))
|
||||
{
|
||||
if(!QCoreApplication::installTranslator(&m_translator))
|
||||
{
|
||||
qWarning() << "could not install translation sketchplugin";
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
qWarning() << "could not load translation sketchplugin";
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user