Developer documentation | Axl-2.5.1

axlInspectorObjectFactory.h
Go to the documentation of this file.
1 /* axlInspectorObjectFactory.h ---
2  *
3  * Author: Meriadeg Perrinel
4  * Copyright (C) 2008 - Julien Wintz, Inria.
5  * Created: mar. mars 29 12:29:01 2011 (+0200)
6  * Version: $Id$
7  * Last-Updated: Fri Oct 28 15:57:20 2011 (+0200)
8  * By: Julien Wintz
9  * Update #: 34
10  */
11 
12 /* Commentary:
13  *
14  */
15 
16 /* Change log:
17  *
18  */
19 
20 
21 #ifndef AXLINSPECTOROBJECTFACTORY_H
22 #define AXLINSPECTOROBJECTFACTORY_H
23 
24 #include "axlGuiExport.h"
25 #include "axlInspectorUtils.h"
26 
27 #include <QtCore>
28 #include <QtGui>
29 #include <QtWidgets>
30 
31 class dtkAbstractData;
32 
33 class axlAbstractView;
36 
37 // /////////////////////////////////////////////////////////////////
38 //
39 // /////////////////////////////////////////////////////////////////
40 
42 {
43  Q_OBJECT
44 public:
45  axlInspectorObjectInterface(QWidget *parent = 0);
46  virtual ~axlInspectorObjectInterface(void);
47 
48  void setObjectFactorySingleton(axlInspectorObjectFactory *objectFactorySingleton);
49  axlInspectorObjectFactory *objectFactorySingleton(void);
50 
51 
52 signals :
53  //void dataChanged(dtkAbstractData *data);
54  void dataChangedByGeometry(dtkAbstractData *data);
55 // void dataChangedByShader(dtkAbstractData *data, QString isophoteShaderXml);
56 // void dataChangedByShaderFromString(dtkAbstractData *data, QString isophoteShaderXml);
57 // void dataChangedByOpacity(dtkAbstractData *data, double opacity);
58  void showCurrentPoint(double u, double v, dtkAbstractData *data);
59  void hideCurrentPoint(double u, double v, dtkAbstractData *data);
60  void moveCurrentPoint(double u, double v, dtkAbstractData *data);
61  void tubeFilterRadiusChanged(dtkAbstractData *data, double radius);
62 
63  void updateStateColor(dtkAbstractData *data, int i);
64 
65  void modifiedProperty(dtkAbstractData *, int);
66  void update();
67 
68 public slots:
69  virtual void setData(dtkAbstractData *data);
70 
71 public:
72  void initComboBoxShaderValue(QComboBox *comboBoxShader, QLineEdit *lineEditShader);
73  QString filePath(const QString& shader);
74 
75 protected :
77 };
78 
79 // /////////////////////////////////////////////////////////////////
80 //
81 // /////////////////////////////////////////////////////////////////
82 
83 class axlInspectorObjectFactoryPrivate;
84 
86 {
87  Q_OBJECT
88 
89 public:
90  typedef axlInspectorObjectInterface *(*axlInspectorObjectCreator)(void);
91 
92  typedef QHash<QString, axlInspectorObjectCreator> axlInspectorObjectCreatorHash;
93 
94 public:
95  static axlInspectorObjectFactory *instance(void);
96 
97  bool registerInspectorObject(const QString& interface_name, axlInspectorObjectCreator func);
98 
99  axlInspectorObjectInterface *create(const QString& interface_name);
100 
101 protected:
103 
104 private:
107 
108 private:
109  axlInspectorObjectFactoryPrivate *d;
110 };
111 
112 #endif //AXLINSPECTOROBJECTFACTORY_H
#define AXLGUI_EXPORT
Definition: axlGuiExport2.h:15
static axlInspectorObjectFactory * s_instance
QHash< QString, axlInspectorObjectCreator > axlInspectorObjectCreatorHash
axlInspectorObjectFactory * m_objectFactorySingleton