forked from OpenDDS/OpenDDS
-
Notifications
You must be signed in to change notification settings - Fork 0
/
ShapesDialog.hpp
78 lines (62 loc) · 1.74 KB
/
ShapesDialog.hpp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
#ifndef _ISHAPESFORM_HPP
#define _ISHAPESFORM_HPP
#include "ShapeTypeTypeSupportC.h"
#include <QtGui/QtGui>
#include <ui_iShapesForm.h>
#include <WriterQosDialog.hpp>
#include <ReaderQosDialog.hpp>
#include <FilterDialog.hpp>
#include <ShapesWidget.hpp>
#include <Circle.hpp>
#define CN 9
//#include <topic-traits.hpp>
class ShapesDialog : public QDialog {
Q_OBJECT
public:
enum { CIRCLE = 0, SQUARE = 1, TRIANGLE = 2 };
enum {
BLUE = 0,
RED = 1,
GREEN = 2,
ORANGE = 3,
YELLOW = 4,
MAGENTA = 5,
CYAN = 6,
GRAY = 7,
BLACK = 8
};
struct QosConfig {
QosConfig(const std::string& partition, bool xcdr1)
: partition_(partition)
, xcdr1_(xcdr1)
{}
std::string partition_;
bool xcdr1_;
};
ShapesDialog(DDS::DomainParticipant_var participant, const QosConfig& config, int defaultSize);
virtual ~ShapesDialog();
public slots:
virtual void onPublishButtonClicked();
virtual void onSubscribeButtonClicked();
virtual void onReaderQosButtonClicked();
virtual void onWriterQosButtonClicked();
virtual void onFilterButtonClicked();
private:
ShapesDialog(const ShapesDialog& orig);
private:
Ui::ShapesDialog mainWidget;
ShapesWidget* shapesWidget;
ReaderQosDialog readerQos_;
WriterQosDialog writerQos_;
FilterDialog* filterDialog_;
QTimer timer;
DDS::Topic_var circleTopic_;
DDS::Topic_var squareTopic_;
DDS::Topic_var triangleTopic_;
DDS::DomainParticipant_var participant_;
DDS::Publisher_var publisher_;
DDS::Subscriber_var subscriber_;
std::string filterExpression_;
DDS::StringSeq filterParams_;
};
#endif /* _ISHAPESFORM_HPP */