NimbRo ROS Soccer Package
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
basicspace.h
1 // Base class for space view
2 // Author: Dmytro Pavlichenko <dm.mark999@gmail.com>
3 
4 #ifndef BASICSPACE_H
5 #define BASICSPACE_H
6 
7 #include <QWidget>
8 #include <QFrame>
9 #include <QLayoutItem>
10 #include <QLayout>
11 
12 #include <boost/shared_ptr.hpp>
13 #include <motion_file/motionfile.h>
14 
15 #include <trajectory_editor/jointperspective.h>
16 
17 class BasicSpace : public QWidget
18 {
19 Q_OBJECT
20 public:
21  typedef boost::shared_ptr<motionfile::Keyframe> KeyframePtr;
22 
23  BasicSpace(const std::vector<std::string> &joint_list, QWidget *parent = 0);
24  ~BasicSpace(){};
25 
26 public Q_SLOTS:
27  void setFrame(KeyframePtr frame);
28  void updateJointList(const std::vector<std::string>& jointList);
29 
30  virtual void handlePerspectiveUpdate(const joint_perspective::JointPerspective &perspective){};
31  virtual void handleApplyRulePart(KeyframePtr frame, const motionfile::RulePart &part, double delta){};
32 
33 Q_SIGNALS:
34  void updateRobot(); // Emitted when robot view has to be updated
35 
36 protected:
37  virtual void updateFrame();
38  QFrame* createLine();
39  void clearlayout(QLayout *layout);
40 
41 protected:
42  KeyframePtr m_current_frame;
43  std::vector<std::string> m_joint_list;
44 };
45 
46 
47 #endif