source: projectionDesigner/trunk/projdesignerplugins/defaultplugin/DefaultCubemapSceneWidget.h @ 373

Last change on this file since 373 was 4, checked in by Torben Dannhauer, 15 years ago
File size: 3.7 KB
Line 
1#ifndef __DEFAULT_CUBEMAP_SCENE_WIDGET_H__
2#define __DEFAULT_CUBEMAP_SCENE_WIDGET_H__
3
4
5// Includes Projection Designer headers
6#include <projdesigner/include/interfaces.h>
7
8// Includes the ui_ header
9#include "ui_defaultcubemapscenewidget.h"
10
11// Includes local headers
12#include "DefaultCubemapSceneContent.h"
13
14
15/**
16 * Implementation of the DefaultCubemapSceneWidget class.
17 *
18 * This widget is used in a stacked widget with all the other scenes,
19 * to configure the CubeMap.
20 *
21 */
22class DefaultCubemapSceneWidget : public SceneWidget, private Ui::DefaultCubemapSceneWidget
23{
24    Q_OBJECT
25               
26
27public:
28
29
30    /**
31     * Default constructor.
32     *
33     */
34    DefaultCubemapSceneWidget(SceneInterface *plugin, QWidget* pParent=0, Qt::WFlags flag=0);
35
36
37    /**
38     * Destructor.
39     *
40     */
41    ~DefaultCubemapSceneWidget();
42
43
44    /**
45     * Updates the widget.
46     *
47     * This method can be used it two ways: to force a refresh or to update the
48     * data of the widget.
49     *
50     * @param content A const pointer on the contents to be used for the widget.
51     *                This contents will be duplicated in the widget. If content
52     *                is NULL, the current content are used and the refresh is
53     *                forced. If no content are given, NULL is used.
54     *
55     */
56    void updateGUI(const SceneContent* content=NULL);
57
58
59    /**
60     * Gets the widget contents.
61     *
62     * @return A const reference on the content of the widget.
63     *
64     */
65    const SceneContent& content(void) const {return m_content;}
66
67
68signals:
69
70
71    /**
72     * [signal] Notify that the contents of the widget have changed.
73     *
74     * This signal is emitted each time that a field is changed.
75     *
76     * @param content A const reference on the new contents (the same as
77     *                returned by the content() method).
78     *
79     */
80    virtual void dataChanged(const SceneContent& content);
81
82
83private slots:
84
85
86    /**
87     * [private slot] Called when the "front file" field is edited.
88     *
89     */
90    void on_frontFileNameEdit_editingFinished(void);
91
92
93    /**
94     * [private slot] Called when the "front file" button is pressed.
95     *
96     */
97    void on_frontBrowseButton_clicked(void);
98
99
100    /**
101     * [private slot] Called when the "back file" field is edited.
102     *
103     */
104    void on_backFileNameEdit_editingFinished(void);
105
106
107    /**
108     * [private slot] Called when the "back file" button is pressed.
109     *
110     */
111    void on_backBrowseButton_clicked(void);
112
113
114    /**
115     * [private slot] Called when the "left file" field is edited.
116     *
117     */
118    void on_leftFileNameEdit_editingFinished(void);
119
120
121    /**
122     * [private slot] Called when the "left file" button is pressed.
123     *
124     */
125    void on_leftBrowseButton_clicked(void);
126
127
128    /**
129     * [private slot] Called when the "right file" field is edited.
130     *
131     */
132    void on_rightFileNameEdit_editingFinished(void);
133
134
135    /**
136     * [private slot] Called when the "right file" button is pressed.
137     *
138     */
139    void on_rightBrowseButton_clicked(void);
140
141
142    /**
143     * [private slot] Called when the "top file" field is edited.
144     *
145     */
146    void on_topFileNameEdit_editingFinished(void);
147
148
149    /**
150     * [private slot] Called when the "top file" button is pressed.
151     *
152     */
153    void on_topBrowseButton_clicked(void);
154
155
156    /**
157     * [private slot] Called when the "bottom file" field is edited.
158     *
159     */
160    void on_bottomFileNameEdit_editingFinished(void);
161
162
163    /**
164     * [private slot] Called when the "bottom file" button is pressed.
165     *
166     */
167    void on_bottomBrowseButton_clicked(void);
168
169
170private:
171
172
173    /// The current DefaultCubemapSceneContent of the widget.
174    DefaultCubemapSceneContent m_content;
175
176
177};
178
179#endif // __DEFAULT_CUBEMAP_SCENE_WIDGET_H__
Note: See TracBrowser for help on using the repository browser.