iCub-main
qavimator.h
Go to the documentation of this file.
1 /*
2  * qavimator.h
3  */
4 
5 /*
6  * Copyright (C) 2009 RobotCub Consortium
7  * Copyright (c) 2014 iCub Facility - Istituto Italiano di Tecnologia
8  * Authors: Alessandro Scalzo <alessandro.scalzo@iit.it>
9  * Davide Perrone <dperrone@aitek.it>
10  * CopyPolicy: Released under the terms of the GNU GPL v2.0.
11  *
12  * Based on:
13  *
14  * Qavimator
15  * Copyright (C) 2006 by Zi Ree *
16  * Zi Ree @ SecondLife *
17  * Released under the terms of the GNU GPL v2.0.
18  */
19 
20 
21 #ifndef QAVIMATOR_H
22 #define QAVIMATOR_H
23 
24 #include <QMainWindow>
25 #define UNTITLED_NAME "Untitled.avm"
26 
27 #include <yarp/os/ResourceFinder.h>
28 #include <yarp/os/Value.h>
29 #include <yarp/os/Bottle.h>
30 #include <yarp/os/RpcClient.h>
31 #include <yarp/os/RpcServer.h>
32 #include "playstate.h"
33 
34 #include <QLineEdit>
35 
36 namespace Ui {
37 class qavimator;
38 }
39 
40 class qavimator : public QMainWindow
41 {
42  Q_OBJECT
43 
44 public:
45  explicit qavimator(yarp::os::ResourceFinder& config,QWidget *parent = 0);
46  ~qavimator();
47  void fileExit();
48 
49 private:
50  Ui::qavimator *ui;
51  int nFPS;
52  int width;
53  int height;
54 
55 protected:
56  // prevent closing of main window if there are unsaved changes
57  virtual void closeEvent(QCloseEvent* event);
58  void configure();
59  void helpAbout();
60  void setupToolBar();
61  void setFPS(int fps);
62 
63 signals:
64  void enableRotation(bool);
65  void resetCamera();
66 
67 protected slots:
68  void readSettings();
69  void configChanged();
70  void backgroundClicked();
74  void onResetCamera();
75  void onFpsSpinValueChanged(int num);
76 };
77 
78 #endif // QAVIMATOR_H
void enableRotation(bool)
void onFpsSpinValueChanged(int num)
Definition: qavimator.cpp:264
void on_optionsConfigureiCubGUIAction_triggered()
Definition: qavimator.cpp:246
void on_helpAboutAction_triggered()
Definition: qavimator.cpp:251
void backgroundClicked()
Definition: qavimator.cpp:169
void resetCamera()
void onResetCamera()
Definition: qavimator.cpp:257
virtual void closeEvent(QCloseEvent *event)
Definition: qavimator.cpp:233
void helpAbout()
Definition: qavimator.cpp:226
void configChanged()
Definition: qavimator.cpp:220
void readSettings()
Definition: qavimator.cpp:134
qavimator(yarp::os::ResourceFinder &config, QWidget *parent=0)
Definition: qavimator.cpp:44
void setFPS(int fps)
Definition: qavimator.cpp:268
void configure()
Definition: qavimator.cpp:212
void fileExit()
Definition: qavimator.cpp:180
void on_fileExitAction_triggered()
Definition: qavimator.cpp:240
void setupToolBar()
Definition: qavimator.cpp:113