Incidenceeditor

schedulingdialog.h
1/*
2 SPDX-FileCopyrightText: 2010 Casey Link <unnamedrambler@gmail.com>
3 SPDX-FileCopyrightText: 2009-2010 Klaralvdalens Datakonsult AB, a KDAB Group company <info@kdab.net>
4
5 SPDX-License-Identifier: LGPL-2.0-or-later
6*/
7
8#pragma once
9
10#include "ui_schedulingdialog.h"
11
12#include <QDateTime>
13#include <QDialog>
14
15namespace CalendarSupport
16{
17class FreePeriodModel;
18}
19
20namespace IncidenceEditorNG
21{
22class ConflictResolver;
23class VisualFreeBusyWidget;
24
25class SchedulingDialog : public QDialog, private Ui_Dialog
26{
28public:
29 explicit SchedulingDialog(QDate startDate, QTime startTime, int duration, ConflictResolver *resolver, QWidget *parent);
30 ~SchedulingDialog() override;
31
32 [[nodiscard]] QDate selectedStartDate() const;
33 [[nodiscard]] QTime selectedStartTime() const;
34
35public Q_SLOTS:
36 void slotUpdateIncidenceStartEnd(const QDateTime &startDateTime, const QDateTime &endDateTime);
37
39 void startDateChanged(const QDate &newDate);
40 void startTimeChanged(const QTime &newTime);
41 void endDateChanged(const QDate &newDate);
42 void endTimeChanged(const QTime &newTime);
43
44private:
45 void slotWeekdaysChanged();
46 void slotMandatoryRolesChanged();
47 void slotStartDateChanged(const QDate &newDate);
48
49 void slotRowSelectionChanged(const QModelIndex &current, const QModelIndex &previous);
50 void slotSetEndTimeLabel(const QTime &startTime);
51 void updateWeekDays(const QDate &oldDate);
52 void fillCombos();
53
54 QDate mStDate;
55 QDate mSelectedDate;
56 QTime mSelectedTime;
57 int mDuration; //!< In seconds
58
59 ConflictResolver *const mResolver;
60 CalendarSupport::FreePeriodModel *const mPeriodModel;
61 VisualFreeBusyWidget *mVisualWidget = nullptr;
62};
63}
Q_OBJECTQ_OBJECT
Q_SIGNALSQ_SIGNALS
Q_SLOTSQ_SLOTS
QObject * parent() const const
T qobject_cast(QObject *object)
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Tue Mar 26 2024 11:19:37 by doxygen 1.10.0 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.