cisst-saw
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
mtsQtWidgetEvent.h
Go to the documentation of this file.
1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 /* ex: set filetype=cpp softtabstop=4 shiftwidth=4 tabstop=4 cindent expandtab: */
3 
4 /*
5 
6  Author(s): Praneeth Sadda, Anton Deguet
7  Created on: 2011-11-11
8 
9  (C) Copyright 2011 Johns Hopkins University (JHU), All Rights
10  Reserved.
11 
12 --- begin cisst license - do not edit ---
13 
14 This software is provided "as is" under an open source license, with
15 no warranty. The complete license can be found in license.txt and
16 http://www.cisst.org/cisst/license.txt.
17 
18 --- end cisst license ---
19 
20 */
21 
22 #ifndef _mtsQtWidgetEvent_h
23 #define _mtsQtWidgetEvent_h
24 
25 #include <map>
26 
29 
36 
38 
39 #include <QWidget>
40 #include <QTime>
41 
42 class QLabel;
43 class QVBoxLayout;
44 
45 // Always include last
47 
48 /* ! A widget that wraps a single mtsCommand, allowing the user to execute the command and view its output. */
49 class CISST_EXPORT mtsQtWidgetEvent: public QWidget, public cmnGenericObject
50 {
51  Q_OBJECT;
53 
54  private:
55  QLabel * Info;
56 
57  protected:
58  QVBoxLayout * MainLayout;
59  void UpdateInfo(void);
60  unsigned long long int Counter;
61 
62  public:
63  mtsQtWidgetEvent(void);
64 };
65 
67 
68 
70 {
71  Q_OBJECT;
72  public:
73  explicit mtsQtWidgetEventVoid(void);
74  void EventHandler(void);
75 };
76 
77 
79 {
80  Q_OBJECT;
81  QWidget * PayloadWidget;
82  const mtsCommandWriteBase * Command;
83  public:
84  explicit mtsQtWidgetEventWrite(void);
85  void EventHandler(const mtsGenericObject & payload);
86  void SetCommand(const mtsCommandWriteBase * command);
87  void CreateArgumentsWidgets(void);
88 };
89 
90 
91 #endif // _mtsQtWidgetEvent_h
Defines the command interfaces.
Defines a function object to use a void command (mtsCommandVoid)
#define CISST_EXPORT
Definition: cmnExportMacros.h:50
Defines the command interfaces.
Base class for high level objects.
Definition: cmnGenericObject.h:51
Base class for data object in cisstMultiTask.
Definition: mtsGenericObject.h:56
Defines the command interfaces.
QVBoxLayout * MainLayout
Definition: mtsQtWidgetEvent.h:58
Definition: mtsCommandWriteBase.h:40
Defines a function object to use a void command (mtsCommandWriteReturn)
Defines mtsGenericObject.
Defines a function object to use a void command (mtsCommandVoidReturn)
#define CMN_DECLARE_SERVICES(hasDynamicCreation, lod)
Definition: cmnClassRegisterMacros.h:116
Definition: mtsQtWidgetGenericObject.h:35
Definition: mtsQtWidgetEvent.h:78
unsigned long long int Counter
Definition: mtsQtWidgetEvent.h:60
Definition: mtsQtWidgetGenericObject.h:48
const int CMN_NO_DYNAMIC_CREATION
Definition: cmnClassRegisterMacros.h:328
Rules of exporting.
#define CMN_DECLARE_SERVICES_INSTANTIATION(className)
Definition: cmnClassRegisterMacros.h:202
Definition: mtsQtWidgetEvent.h:49
#define CMN_LOG_ALLOW_DEFAULT
Definition: cmnLogLoD.h:76
Definition: mtsQtWidgetEvent.h:69