summaryrefslogtreecommitdiff
path: root/support/dktools/wxpqdic.h
blob: 2cbddeb59d8f7bd08f138384c4e74c68b8b30545 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
#ifndef H_INCLUDED_wxpqdic
/**	Include file only once.
*/
#define	H_INCLUDED_wxpqdic 1

#ifndef DK4CONF_H_INCLUDED
#include <dk4conf.h>
#endif

#ifndef DK4TYPES_H_INCLUDED
#include <dk4types.h>
#endif

#ifndef	DK4ERROR_H_INCLUDED
#include <dk4error.h>
#endif

#ifndef	DK4MEM_H_INCLUDED
#include <dk4mem.h>
#endif

#ifndef	DK4SOCK_H_INCLUDED
#include <dk4sock.h>
#endif

#ifndef	DK4TIME_H_INCLUDED
#include <dk4time.h>
#endif

#ifndef WX_WXPREC_H_INCLUDED
#include <wx/wxprec.h>
#define	WX_WXPREC_H_INCLUDED 1
#endif

#ifdef __BORLANDC__
#pragma hdrstop
#endif

#ifndef WX_PRECOMP
#ifndef WX_WX_H_INCLUDED
#include <wx/wx.h>
#define	WX_WX_H_INCLUDED 1
#endif
#endif

#ifndef WX_ARRSTR_H_INCLUDED
#include <wx/arrstr.h>
#define	WX_ARRSTR_H_INCLUDED 1
#endif

#ifndef WX_CONFIG_H_INCLUDED
#include <wx/config.h>
#define	WX_CONFIG_H_INCLUDED 1
#endif

#ifndef WX_FILENAME_H_INCLUDED
#include <wx/filename.h>
#define	WX_FILENAME_H_INCLUDED 1
#endif

#ifndef WX_GBSIZER_H_INCLUDED
#include <wx/gbsizer.h>
#define	WX_GBSIZER_H_INCLUDED 1
#endif

#ifndef WX_THREAD_H_INCLUDED
#include <wx/thread.h>
#define	WX_THREAD_H_INCLUDED 1
#endif

#ifndef WX_GAUGE_H_INCLUDED
#include <wx/gauge.h>
#define	WX_GAUGE_H_INCLUDED 1
#endif

#ifndef WX_HELP_H_INCLUDED
#include <wx/help.h>
#define	WX_HELP_H_INCLUDED 1
#endif

#ifndef WX_FS_ZIP_H_INCLUDED
#include <wx/fs_zip.h>
#define	WX_FS_ZIP_H_INCLUDED 1
#endif

#ifndef WX_CMDLINE_H_INCLUDED
#include <wx/cmdline.h>
#define	WX_CMDLINE_H_INCLUDED 1
#endif

#ifndef WX_DIR_H_INCLUDED
#include <wx/dir.h>
#define	WX_DIR_H_INCLUDED 1
#endif

/*	__CHANGE__ 018:	Add futher wxWidgets header files.
*/


#ifndef DK4WXAPPLICTIONHELPER_H_INCLUDED
#include <Dk4WxApplicationHelper.h>
#endif

#ifndef DK4WXFRAME_H_INCLUDED
#include <Dk4WxFrame.h>
#endif

#ifndef DK4WXPROGRESSDIALOG_H_INCLUDED
#include <Dk4WxProgressDialog.h>
#endif

#ifndef DK4WXHELPCONTROLLER_H_INCLUDED
#include <Dk4WxHelpController.h>
#endif

#include "WxpqdicApp.h"

#include "WxpqdicFrame.h"

/*	__CHANGE__ 018:	Add header files for further classes and modules.
*/



/**	IDs for menu items, buttons and other elements.
*/
enum {

				/**	Exit the application.
				*/
  WxpqdicFrame_Quit			= wxID_EXIT ,

				/**	Main window ID.
				*/
  WxpqdicFrame_MainWindow		= ((wxID_HIGHEST) + 1) ,

				/**	Show version dialog box.
				*/
  WxpqdicFrame_Help_About ,

				/**	Open table of conents for online help.
				*/
  WxpqdicFrame_Help_Contents ,

				/**	Update view.
				*/
  WxpqdicFrame_View_Update ,

				/**	Timer event to handle.
				*/
  WxpqdicFrame_Timer
};



/**	Error codes during configuration phase.
*/
enum {

				/**	No error occured.
				*/
  WXPQDIC_FRAME_ERROR_NONE	= 0 ,

				/**	Failed to parse command line arguments.
				*/
  WXPQDIC_FRAME_ERROR_PARSE ,

				/**	Not enough memory.
				*/
  WXPQDIC_FRAME_ERROR_MEMORY ,

				/**	String conversion failed for host name.
				*/
  WXPQDIC_FRAME_ERROR_STRCONV_HOSTNAME ,

				/**	No host name specified.
				*/
  WXPQDIC_FRAME_ERROR_HOSTNAME ,

				/**	String conversion failed for queue name.
				*/
  WXPQDIC_FRAME_ERROR_STRCONV_QUEUENAME ,

				/**	Queue name missing.
				*/
  WXPQDIC_FRAME_ERROR_QUEUENAME ,

				/**	Port number out of range.
				*/
  WXPQDIC_FRAME_ERROR_PORT_OOR ,

				/**	Port number is zero.
				*/
  WXPQDIC_FRAME_ERROR_PORT_ZERO ,


				/**	String conversion failed for user name.
				*/
  WXPQDIC_FRAME_ERROR_STRCONV_USERNAME ,

				/**	User name not found.
				*/
  WXPQDIC_FRAME_ERROR_USERNAME ,

				/**	Local port number out of range.
				*/
  WXPQDIC_FRAME_ERROR_LOCALPORT_OOR ,

				/**	Local port number 0.
				*/
  WXPQDIC_FRAME_ERROR_LOCALPORT_ZERO ,

				/**	Bug: Failed to copy string to request.
				*/
  WXPQDIC_FRAME_ERROR_BUG ,

				/**	Numeric overflow in size calculation.
				*/
  WXPQDIC_FRAME_ERROR_SIZE_CALC_OVERFLOW ,

				/**	Failed to create UDP socket.
				*/
  WXPQDIC_FRAME_ERROR_SOCKET
 
};



/**	States.
*/
enum {
			/**	Have response for previous request.
			*/
  WXPQDIC_STATE_OK	= 0 ,

			/**	Request was sended, no response yet.
			*/
  WXPQDIC_STATE_SENDED ,

			/**	Waiting too long for response.
			*/
  WXPQDIC_STATE_TIMEOUT ,

			/**	Failed to send request.
			*/
  WXPQDIC_STATE_SEND_FAILED

};



/**	Error to show in status text.
*/
enum {
			/**	Failed to send request.
			*/
  WXPQDIC_E_SEND_FAILED	= 1 ,

			/**	No response from server.
			*/
  WXPQDIC_E_NO_RESPONSE = 2
};

#endif