Devel #56
@@ -8,17 +8,11 @@
|
||||
#include "absencesmodel.h"
|
||||
|
||||
AbsenceDialog::AbsenceDialog(int userId, const QDate &date, ZeiterfassungApi &erfassung, QWidget *parent) :
|
||||
QDialog(parent),
|
||||
ZeiterfassungDialog(parent),
|
||||
ui(new Ui::AbsenceDialog)
|
||||
{
|
||||
ui->setupUi(this);
|
||||
|
||||
#if (QT_VERSION >= QT_VERSION_CHECK(5, 9, 0))
|
||||
setWindowFlag(Qt::WindowContextHelpButtonHint, false);
|
||||
#else
|
||||
setWindowFlags(windowFlags() & ~Qt::WindowContextHelpButtonHint);
|
||||
#endif
|
||||
|
||||
ui->labelTitle->setText(tr("Absences for %0").arg(date.toString(tr("dd.MM.yyyy"))));
|
||||
|
||||
m_model = new AbsencesModel(userId, date, erfassung, this);
|
||||
|
@@ -1,6 +1,6 @@
|
||||
#pragma once
|
||||
|
||||
#include <QDialog>
|
||||
#include "zeiterfassungdialog.h"
|
||||
|
||||
class QDate;
|
||||
|
||||
@@ -9,7 +9,7 @@ class ZeiterfassungApi;
|
||||
class AbsencesModel;
|
||||
namespace Ui { class AbsenceDialog; }
|
||||
|
||||
class AbsenceDialog : public QDialog
|
||||
class AbsenceDialog : public ZeiterfassungDialog
|
||||
{
|
||||
Q_OBJECT
|
||||
|
||||
|
@@ -1,7 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<ui version="4.0">
|
||||
<class>AbsenceDialog</class>
|
||||
<widget class="QDialog" name="AbsenceDialog">
|
||||
<widget class="ZeiterfassungDialog" name="AbsenceDialog">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>0</x>
|
||||
|
13
zeiterfassungguilib/zeiterfassungdialog.cpp
Normal file
13
zeiterfassungguilib/zeiterfassungdialog.cpp
Normal file
@@ -0,0 +1,13 @@
|
||||
#include "zeiterfassungdialog.h"
|
||||
|
||||
#include <qnamespace.h>
|
||||
|
||||
ZeiterfassungDialog::ZeiterfassungDialog(QWidget *parent) :
|
||||
QDialog(parent)
|
||||
{
|
||||
#if (QT_VERSION >= QT_VERSION_CHECK(5, 9, 0))
|
||||
setWindowFlag(Qt::WindowContextHelpButtonHint, false);
|
||||
#else
|
||||
setWindowFlags(windowFlags() & ~Qt::WindowContextHelpButtonHint);
|
||||
#endif
|
||||
}
|
13
zeiterfassungguilib/zeiterfassungdialog.h
Normal file
13
zeiterfassungguilib/zeiterfassungdialog.h
Normal file
@@ -0,0 +1,13 @@
|
||||
#pragma once
|
||||
|
||||
#include <QDialog>
|
||||
|
||||
#include "zeiterfassungguilib_global.h"
|
||||
|
||||
class ZEITERFASSUNGGUILIBSHARED_EXPORT ZeiterfassungDialog : public QDialog
|
||||
{
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
explicit ZeiterfassungDialog(QWidget *parent = Q_NULLPTR);
|
||||
};
|
@@ -20,6 +20,7 @@ DEFINES += ZEITERFASSUNGGUILIB_LIBRARY
|
||||
SOURCES += mainwindow.cpp \
|
||||
stripfactory.cpp \
|
||||
stripswidget.cpp \
|
||||
zeiterfassungdialog.cpp \
|
||||
zeiterfassungplugin.cpp \
|
||||
dialogs/authenticationdialog.cpp \
|
||||
dialogs/languageselectiondialog.cpp \
|
||||
@@ -29,6 +30,7 @@ HEADERS += mainwindow.h \
|
||||
stripfactory.h \
|
||||
stripswidget.h \
|
||||
zeiterfassungguilib_global.h \
|
||||
zeiterfassungdialog.h \
|
||||
zeiterfassungplugin.h \
|
||||
dialogs/authenticationdialog.h \
|
||||
dialogs/languageselectiondialog.h \
|
||||
|
Reference in New Issue
Block a user