cmake plugin cleanups
This commit is contained in:
@@ -16,7 +16,13 @@ set(RESOURCES
|
||||
profileplugin_resources.qrc
|
||||
)
|
||||
|
||||
add_library(zeiterfassung-plugins-profileplugin SHARED ${HEADERS} ${SOURCES} ${RESOURCES} ${FORMS})
|
||||
set(OTHER_FILES
|
||||
profileplugin.json
|
||||
)
|
||||
|
||||
add_library(zeiterfassung-plugins-profileplugin SHARED ${HEADERS} ${SOURCES} ${RESOURCES} ${FORMS} ${OTHER_FILES})
|
||||
|
||||
set_target_properties(zeiterfassung-plugins-profileplugin PROPERTIES OUTPUT_NAME profileplugin PREFIX "")
|
||||
|
||||
target_link_libraries(zeiterfassung-plugins-profileplugin Qt5::Core Qt5::Gui Qt5::Widgets zeiterfassungguilib zeiterfassungnetworklib)
|
||||
|
||||
|
@@ -7,6 +7,8 @@
|
||||
#include <QMenu>
|
||||
#include <QAction>
|
||||
|
||||
#include "utils/fileutils.h"
|
||||
|
||||
#include "mainwindow.h"
|
||||
|
||||
#include "profiledialog.h"
|
||||
@@ -16,9 +18,7 @@ ProfilePlugin::ProfilePlugin(QObject *parent) :
|
||||
{
|
||||
qDebug() << "called";
|
||||
|
||||
static auto dir = QDir(QCoreApplication::applicationDirPath()).absoluteFilePath(QStringLiteral("translations"));
|
||||
|
||||
if(m_translator.load(QLocale(), QStringLiteral("profileplugin"), QStringLiteral("_"), dir))
|
||||
if(m_translator.load(QLocale(), QStringLiteral("profileplugin"), QStringLiteral("_"), translationsDir()))
|
||||
{
|
||||
if(!QCoreApplication::installTranslator(&m_translator))
|
||||
{
|
||||
|
Reference in New Issue
Block a user