kplato

kptrelationdialog.h
1/* This file is part of the KDE project
2 Copyright (C) 2002 The koffice team <koffice@kde.org>
3 Copyright (C) 2003, 2004 Dag Andersen <danders@get2net.dk>
4
5 This library is free software; you can redistribute it and/or
6 modify it under the terms of the GNU Library General Public
7 License as published by the Free Software Foundation; either
8 version 2 of the License, or (at your option) any later version.
9
10 This library is distributed in the hope that it will be useful,
11 but WITHOUT ANY WARRANTY; without even the implied warranty of
12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 Library General Public License for more details.
14
15 You should have received a copy of the GNU Library General Public License
16 along with this library; see the file COPYING.LIB. If not, write to
17 the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
18 * Boston, MA 02110-1301, USA.
19*/
20
21#ifndef KPTRELATIONDIALOG_H
22#define KPTRELATIONDIALOG_H
23
24#include <kdialogbase.h>
25
26class TQButtonGroup;
27class KCommand;
28
29namespace KPlato
30{
31
32class RelationPanel;
33class DurationWidget;
34
35class Node;
36class Relation;
37class Part;
38class ModifyRelationTypeCmd;
39
40class AddRelationDialog : public KDialogBase
41{
42 TQ_OBJECT
43
44public:
45 AddRelationDialog(Relation *rel, TQWidget *p, TQString caption=TQString(), int buttons=Ok|Cancel, const char *n=0);
46
47 virtual KCommand *buildCommand(Part *part);
48
49protected slots:
50 void slotOk();
51 void lagChanged();
52 void typeClicked(int);
53
54protected:
55 RelationPanel *m_panel;
56 TQButtonGroup *relationType;
57 Relation *m_relation;
58 DurationWidget *m_lag;
59};
60
61
62class ModifyRelationDialog : public AddRelationDialog
63{
64 TQ_OBJECT
65
66public:
67 ModifyRelationDialog(Relation *rel, TQWidget *p=0, const char *n=0);
68
69 virtual KCommand *buildCommand(Part *part);
70 bool relationIsDeleted() { return m_deleted; }
71
72protected slots:
73 void slotUser1();
74
75private:
76 bool m_deleted;
77};
78
79} //KPlato namespace
80
81#endif // RELATIONDIALOG_H
This class represents any node in the project, a node can be a project or a subproject or any task.
Definition kptnode.h:57
The relation class couples a 2 nodes together which are dependent on each other.
Definition kptrelation.h:45