Choreonoid  1.8
Widget.h
Go to the documentation of this file.
1 #ifndef CNOID_BASE_WIDGET_H
2 #define CNOID_BASE_WIDGET_H
3 
4 #include <cnoid/Signal>
5 #include <QWidget>
6 #include "exportdecl.h"
7 
8 namespace cnoid {
9 
10 class CNOID_EXPORT Widget : public QWidget
11 {
12  Q_OBJECT
13 
14 public:
15  Widget(QWidget* parent = 0);
16 
17  SignalProxy<void(std::string name)> sigObjectNameChanged() {
18  return sigObjectNameChanged_;
19  }
20  SignalProxy<void(std::string title)> sigWindowTitleChanged() {
21  return sigWindowTitleChanged_;
22  }
23 
24 private Q_SLOTS:
25  void onObjectNameChanged(const QString& objectName);
26  void onWindowTitleChanged(const QString& title);
27 
28 private:
29  Signal<void(std::string name)> sigObjectNameChanged_;
30  Signal<void(std::string title)> sigWindowTitleChanged_;
31 
32  void initialize();
33 };
34 
35 }
36 
37 #endif
cnoid::Widget::sigWindowTitleChanged
SignalProxy< void(std::string title)> sigWindowTitleChanged()
Definition: Widget.h:20
cnoid
Definition: AbstractSceneLoader.h:11
cnoid::Widget::sigObjectNameChanged
SignalProxy< void(std::string name)> sigObjectNameChanged()
Definition: Widget.h:17
cnoid::Signal
Definition: Signal.h:165
cnoid::Widget
Definition: Widget.h:10
cnoid::SignalProxy
Definition: Signal.h:470