]> SALOME platform Git repositories - modules/geom.git/blob - src/DlgRef/GEOM_DlgRef.cxx
Salome HOME
*** empty log message ***
[modules/geom.git] / src / DlgRef / GEOM_DlgRef.cxx
1 // Copyright (C) 2003  OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
2 // CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS 
3 // 
4 // This library is free software; you can redistribute it and/or 
5 // modify it under the terms of the GNU Lesser General Public 
6 // License as published by the Free Software Foundation; either 
7 // version 2.1 of the License. 
8 // 
9 // This library is distributed in the hope that it will be useful, 
10 // but WITHOUT ANY WARRANTY; without even the implied warranty of 
11 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU 
12 // Lesser General Public License for more details. 
13 // 
14 // You should have received a copy of the GNU Lesser General Public 
15 // License along with this library; if not, write to the Free Software 
16 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA 
17 // 
18 // See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org 
19 //
20 // File   : GEOM_DlgRef.cxx
21 // Author : Vadim SANDLER, Open CASCADE S.A.S. (vadim.sandler@opencascade.com)
22 //
23
24 #include "GEOM_DlgRef.h"
25
26 //////////////////////////////////////////
27 // DlgRef_1List1Spin1Btn
28 //////////////////////////////////////////
29
30 DlgRef_1List1Spin1Btn::DlgRef_1List1Spin1Btn( QWidget* parent, Qt::WindowFlags f )
31 : QWidget( parent, f )
32 {
33   setupUi( this );
34 }
35
36 DlgRef_1List1Spin1Btn::~DlgRef_1List1Spin1Btn()
37 {
38 }
39
40 //////////////////////////////////////////
41 // DlgRef_1Sel1Check1List
42 //////////////////////////////////////////
43
44 DlgRef_1Sel1Check1List::DlgRef_1Sel1Check1List( QWidget* parent, Qt::WindowFlags f )
45 : QWidget( parent, f )
46 {
47   setupUi( this );
48 }
49
50 DlgRef_1Sel1Check1List::~DlgRef_1Sel1Check1List()
51 {
52 }
53
54 //////////////////////////////////////////
55 // DlgRef_1Sel1Check
56 //////////////////////////////////////////
57
58 DlgRef_1Sel1Check::DlgRef_1Sel1Check( QWidget* parent, Qt::WindowFlags f )
59 : QWidget( parent, f )
60 {
61   setupUi( this );
62 }
63
64 DlgRef_1Sel1Check::~DlgRef_1Sel1Check()
65 {
66 }
67
68 //////////////////////////////////////////
69 // DlgRef_1Sel1Spin1Check
70 //////////////////////////////////////////
71
72 DlgRef_1Sel1Spin1Check::DlgRef_1Sel1Spin1Check( QWidget* parent, Qt::WindowFlags f )
73 : QWidget( parent, f )
74 {
75   setupUi( this );
76 }
77
78 DlgRef_1Sel1Spin1Check::~DlgRef_1Sel1Spin1Check()
79 {
80 }
81
82 //////////////////////////////////////////
83 // DlgRef_1Sel1Spin
84 //////////////////////////////////////////
85
86 DlgRef_1Sel1Spin::DlgRef_1Sel1Spin( QWidget* parent, Qt::WindowFlags f )
87 : QWidget( parent, f )
88 {
89   setupUi( this );
90 }
91
92 DlgRef_1Sel1Spin::~DlgRef_1Sel1Spin()
93 {
94 }
95
96 //////////////////////////////////////////
97 // DlgRef_1Sel2Spin
98 //////////////////////////////////////////
99
100 DlgRef_1Sel2Spin::DlgRef_1Sel2Spin( QWidget* parent, Qt::WindowFlags f )
101 : QWidget( parent, f )
102 {
103   setupUi( this );
104 }
105
106 DlgRef_1Sel2Spin::~DlgRef_1Sel2Spin()
107 {
108 }
109
110 //////////////////////////////////////////
111 // DlgRef_1Sel3Check
112 //////////////////////////////////////////
113
114 DlgRef_1Sel3Check::DlgRef_1Sel3Check( QWidget* parent, Qt::WindowFlags f )
115 : QWidget( parent, f )
116 {
117   setupUi( this );
118 }
119
120 DlgRef_1Sel3Check::~DlgRef_1Sel3Check()
121 {
122 }
123
124 //////////////////////////////////////////
125 // DlgRef_1Sel3Spin
126 //////////////////////////////////////////
127
128 DlgRef_1Sel3Spin::DlgRef_1Sel3Spin( QWidget* parent, Qt::WindowFlags f )
129 : QWidget( parent, f )
130 {
131   setupUi( this );
132 }
133
134 DlgRef_1Sel3Spin::~DlgRef_1Sel3Spin()
135 {
136 }
137
138 //////////////////////////////////////////
139 // DlgRef_1Sel4Spin
140 //////////////////////////////////////////
141
142 DlgRef_1Sel4Spin::DlgRef_1Sel4Spin( QWidget* parent, Qt::WindowFlags f )
143 : QWidget( parent, f )
144 {
145   setupUi( this );
146 }
147
148 DlgRef_1Sel4Spin::~DlgRef_1Sel4Spin()
149 {
150 }
151
152 //////////////////////////////////////////
153 // DlgRef_1Sel5Spin
154 //////////////////////////////////////////
155
156 DlgRef_1Sel5Spin::DlgRef_1Sel5Spin( QWidget* parent, Qt::WindowFlags f )
157 : QWidget( parent, f )
158 {
159   setupUi( this );
160 }
161
162 DlgRef_1Sel5Spin::~DlgRef_1Sel5Spin()
163 {
164 }
165
166 //////////////////////////////////////////
167 // DlgRef_1Spin
168 //////////////////////////////////////////
169
170 DlgRef_1Spin::DlgRef_1Spin( QWidget* parent, Qt::WindowFlags f )
171 : QWidget( parent, f )
172 {
173   setupUi( this );
174 }
175
176 DlgRef_1Spin::~DlgRef_1Spin()
177 {
178 }
179
180 //////////////////////////////////////////
181 // DlgRef_1Sel
182 //////////////////////////////////////////
183
184 DlgRef_1Sel::DlgRef_1Sel( QWidget* parent, Qt::WindowFlags f )
185 : QWidget( parent, f )
186 {
187   setupUi( this );
188 }
189
190 DlgRef_1Sel::~DlgRef_1Sel()
191 {
192 }
193
194 //////////////////////////////////////////
195 // DlgRef_2Sel1List
196 //////////////////////////////////////////
197
198 DlgRef_2Sel1List::DlgRef_2Sel1List( QWidget* parent, Qt::WindowFlags f )
199 : QWidget( parent, f )
200 {
201   setupUi( this );
202 }
203
204 DlgRef_2Sel1List::~DlgRef_2Sel1List()
205 {
206 }
207
208 //////////////////////////////////////////
209 // DlgRef_2Sel1Spin2Check
210 //////////////////////////////////////////
211
212 DlgRef_2Sel1Spin2Check::DlgRef_2Sel1Spin2Check( QWidget* parent, Qt::WindowFlags f )
213 : QWidget( parent, f )
214 {
215   setupUi( this );
216 }
217
218 DlgRef_2Sel1Spin2Check::~DlgRef_2Sel1Spin2Check()
219 {
220 }
221
222 //////////////////////////////////////////
223 // DlgRef_2Sel1Spin
224 //////////////////////////////////////////
225
226 DlgRef_2Sel1Spin::DlgRef_2Sel1Spin( QWidget* parent, Qt::WindowFlags f )
227 : QWidget( parent, f )
228 {
229   setupUi( this );
230 }
231
232 DlgRef_2Sel1Spin::~DlgRef_2Sel1Spin()
233 {
234 }
235
236 //////////////////////////////////////////
237 // DlgRef_2Sel2Spin1Check
238 //////////////////////////////////////////
239
240 DlgRef_2Sel2Spin1Check::DlgRef_2Sel2Spin1Check( QWidget* parent, Qt::WindowFlags f )
241 : QWidget( parent, f )
242 {
243   setupUi( this );
244 }
245
246 DlgRef_2Sel2Spin1Check::~DlgRef_2Sel2Spin1Check()
247 {
248 }
249
250 //////////////////////////////////////////
251 // DlgRef_2Sel2Spin
252 //////////////////////////////////////////
253
254 DlgRef_2Sel2Spin::DlgRef_2Sel2Spin( QWidget* parent, Qt::WindowFlags f )
255 : QWidget( parent, f )
256 {
257   setupUi( this );
258 }
259
260 DlgRef_2Sel2Spin::~DlgRef_2Sel2Spin()
261 {
262 }
263
264 //////////////////////////////////////////
265 // DlgRef_2Sel3Spin
266 //////////////////////////////////////////
267
268 DlgRef_2Sel3Spin::DlgRef_2Sel3Spin( QWidget* parent, Qt::WindowFlags f )
269 : QWidget( parent, f )
270 {
271   setupUi( this );
272 }
273
274 DlgRef_2Sel3Spin::~DlgRef_2Sel3Spin()
275 {
276 }
277
278 //////////////////////////////////////////
279 // DlgRef_2Sel4Spin1Check
280 //////////////////////////////////////////
281
282 DlgRef_2Sel4Spin1Check::DlgRef_2Sel4Spin1Check( QWidget* parent, Qt::WindowFlags f )
283 : QWidget( parent, f )
284 {
285   setupUi( this );
286 }
287
288 DlgRef_2Sel4Spin1Check::~DlgRef_2Sel4Spin1Check()
289 {
290 }
291
292 //////////////////////////////////////////
293 // DlgRef_2Sel
294 //////////////////////////////////////////
295
296 DlgRef_2Sel::DlgRef_2Sel( QWidget* parent, Qt::WindowFlags f )
297 : QWidget( parent, f )
298 {
299   setupUi( this );
300 }
301
302 DlgRef_2Sel::~DlgRef_2Sel()
303 {
304 }
305
306 //////////////////////////////////////////
307 // DlgRef_2Spin
308 //////////////////////////////////////////
309
310 DlgRef_2Spin::DlgRef_2Spin( QWidget* parent, Qt::WindowFlags f )
311 : QWidget( parent, f )
312 {
313   setupUi( this );
314 }
315
316 DlgRef_2Spin::~DlgRef_2Spin()
317 {
318 }
319
320 //////////////////////////////////////////
321 // DlgRef_3Check
322 //////////////////////////////////////////
323
324 DlgRef_3Check::DlgRef_3Check( QWidget* parent, Qt::WindowFlags f )
325 : QWidget( parent, f )
326 {
327   setupUi( this );
328 }
329
330 DlgRef_3Check::~DlgRef_3Check()
331 {
332 }
333
334 //////////////////////////////////////////
335 // DlgRef_3Sel1Check
336 //////////////////////////////////////////
337
338 DlgRef_3Sel1Check::DlgRef_3Sel1Check( QWidget* parent, Qt::WindowFlags f )
339 : QWidget( parent, f )
340 {
341   setupUi( this );
342 }
343
344 DlgRef_3Sel1Check::~DlgRef_3Sel1Check()
345 {
346 }
347
348 //////////////////////////////////////////
349 // DlgRef_3Sel1Spin
350 //////////////////////////////////////////
351
352 DlgRef_3Sel1Spin::DlgRef_3Sel1Spin( QWidget* parent, Qt::WindowFlags f )
353 : QWidget( parent, f )
354 {
355   setupUi( this );
356 }
357
358 DlgRef_3Sel1Spin::~DlgRef_3Sel1Spin()
359 {
360 }
361
362 //////////////////////////////////////////
363 // DlgRef_3Sel3Spin1Check
364 //////////////////////////////////////////
365
366 DlgRef_3Sel3Spin1Check::DlgRef_3Sel3Spin1Check( QWidget* parent, Qt::WindowFlags f )
367 : QWidget( parent, f )
368 {
369   setupUi( this );
370 }
371
372 DlgRef_3Sel3Spin1Check::~DlgRef_3Sel3Spin1Check()
373 {
374 }
375
376 void DlgRef_3Sel3Spin1Check::ShowRows( int fromRow, int toRow, bool toShow )
377 {
378   const int maxRows = 6;
379   
380   if ( toRow >= fromRow && fromRow >= 0 && toRow <= maxRows ) {
381     int c = gridLayout1->count();
382     for ( int i = 0; i < c; i++ ) {
383       QWidget* w = gridLayout1->itemAt( i )->widget();
384       int row, col, rowspan, colspan;
385       gridLayout1->getItemPosition( i, &row, &col, &rowspan, &colspan );
386       if ( w && row >= fromRow && row <= toRow )
387         w->setVisible( toShow );
388     }
389   }
390 }
391
392 //////////////////////////////////////////
393 // DlgRef_3Sel4Spin2Check
394 //////////////////////////////////////////
395
396 DlgRef_3Sel4Spin2Check::DlgRef_3Sel4Spin2Check( QWidget* parent, Qt::WindowFlags f )
397 : QWidget( parent, f )
398 {
399   setupUi( this );
400 }
401
402 DlgRef_3Sel4Spin2Check::~DlgRef_3Sel4Spin2Check()
403 {
404 }
405
406 //////////////////////////////////////////
407 // DlgRef_3Sel
408 //////////////////////////////////////////
409
410 DlgRef_3Sel::DlgRef_3Sel( QWidget* parent, Qt::WindowFlags f )
411 : QWidget( parent, f )
412 {
413   setupUi( this );
414 }
415
416 DlgRef_3Sel::~DlgRef_3Sel()
417 {
418 }
419
420 //////////////////////////////////////////
421 // DlgRef_3Spin1Check
422 //////////////////////////////////////////
423
424 DlgRef_3Spin1Check::DlgRef_3Spin1Check( QWidget* parent, Qt::WindowFlags f )
425 : QWidget( parent, f )
426 {
427   setupUi( this );
428 }
429
430 DlgRef_3Spin1Check::~DlgRef_3Spin1Check()
431 {
432 }
433
434 //////////////////////////////////////////
435 // DlgRef_3Spin
436 //////////////////////////////////////////
437
438 DlgRef_3Spin::DlgRef_3Spin( QWidget* parent, Qt::WindowFlags f )
439 : QWidget( parent, f )
440 {
441   setupUi( this );
442 }
443
444 DlgRef_3Spin::~DlgRef_3Spin()
445 {
446 }
447
448 //////////////////////////////////////////
449 // DlgRef_4Sel1List1Check
450 //////////////////////////////////////////
451
452 DlgRef_4Sel1List1Check::DlgRef_4Sel1List1Check( QWidget* parent, Qt::WindowFlags f )
453 : QWidget( parent, f )
454 {
455   setupUi( this );
456 }
457
458 DlgRef_4Sel1List1Check::~DlgRef_4Sel1List1Check()
459 {
460 }
461
462 //////////////////////////////////////////
463 // DlgRef_4Sel1List
464 //////////////////////////////////////////
465
466 DlgRef_4Sel1List::DlgRef_4Sel1List( QWidget* parent, Qt::WindowFlags f )
467 : QWidget( parent, f )
468 {
469   setupUi( this );
470 }
471
472 DlgRef_4Sel1List::~DlgRef_4Sel1List()
473 {
474 }
475
476 //////////////////////////////////////////
477 // DlgRef_4Sel1Spin2Check
478 //////////////////////////////////////////
479
480 DlgRef_4Sel1Spin2Check::DlgRef_4Sel1Spin2Check( QWidget* parent, Qt::WindowFlags f )
481 : QWidget( parent, f )
482 {
483   setupUi( this );
484 }
485
486 DlgRef_4Sel1Spin2Check::~DlgRef_4Sel1Spin2Check()
487 {
488 }
489
490 void DlgRef_4Sel1Spin2Check::ShowRows( int fromRow, int toRow, bool toShow )
491 {
492   const int maxRows = 6;
493   
494   if ( toRow >= fromRow && fromRow >= 0 && toRow <= maxRows ) {
495     int c = gridLayout1->count();
496     for ( int i = 0; i < c; i++ ) {
497       QWidget* w = gridLayout1->itemAt( i )->widget();
498       int row, col, rowspan, colspan;
499       gridLayout1->getItemPosition( i, &row, &col, &rowspan, &colspan );
500       if ( w && row >= fromRow && row <= toRow )
501         w->setVisible( toShow );
502     }
503   }
504 }
505
506 //////////////////////////////////////////
507 // DlgRef_6Sel
508 //////////////////////////////////////////
509
510 DlgRef_6Sel::DlgRef_6Sel( QWidget* parent, Qt::WindowFlags f )
511 : QWidget( parent, f )
512 {
513   setupUi( this );
514 }
515
516 DlgRef_6Sel::~DlgRef_6Sel()
517 {
518 }
519
520 //////////////////////////////////////////
521 // DlgRef_Skeleton
522 //////////////////////////////////////////
523
524 DlgRef_Skeleton::DlgRef_Skeleton( QWidget* parent, Qt::WindowFlags f )
525 : QDialog( parent, f )
526 {
527   setupUi( this );
528 }
529
530 DlgRef_Skeleton::DlgRef_Skeleton( QWidget* parent, bool modal, Qt::WindowFlags f )
531 : QDialog( parent, f )
532 {
533   setupUi( this );
534   setModal( modal );
535 }
536
537 DlgRef_Skeleton::~DlgRef_Skeleton()
538 {
539 }