source: trunk/SRC/ToBeReviewed/HOPE/domainpart.pro @ 157

Last change on this file since 157 was 142, checked in by navarro, 18 years ago

english and nicer header (2a)

  • Property svn:keywords set to Id
File size: 2.3 KB
Line 
1;+
2;
3; @todo seb
4;
5;-
6pro domainpart, top_uvalue, basedomain, selected, DESTROY = destroy
7;
8  compile_opt idl2, strictarrsubs
9;
10
11   if keyword_set(destroy) then BEGIN
12;       id = widget_info(basedomain,find_by_uname = 'title')
13;       IF id NE 0 THEN widget_control, id, /destroy
14      id = widget_info(basedomain,find_by_uname = 'oddsecchoice')
15      IF id NE 0 THEN widget_control, id, /destroy
16      id = widget_info(basedomain,find_by_uname = 'evensecchoice')
17      IF id NE 0 THEN widget_control, id, /destroy
18      id = widget_info(basedomain,find_by_uname = 'odd-evensecchoice')
19      IF id NE 0 THEN widget_control, id, /destroy
20      id = widget_info(basedomain,find_by_uname = 'basex')
21      IF id NE 0 THEN widget_control, id, /destroy
22      id = widget_info(basedomain,find_by_uname = 'basey')
23      IF id NE 0 THEN widget_control, id, /destroy
24      id = widget_info(basedomain,find_by_uname = 'basez')
25      IF id NE 0 THEN widget_control, id, /destroy
26      return
27   endif
28;
29; we get the size of the dimenstion id of this section
30;
31   dimvar = *top_uvalue[1, findline(top_uvalue, 'dimvar')]
32   selecteddim = dimvar[*, selected]
33   typedim = *top_uvalue[1, findline(top_uvalue, 'typedim')]
34   sorteddim = selecteddim[sortdim(typedim[selecteddim])]
35   dimlist = *top_uvalue[1, findline(top_uvalue, 'dimlist')]
36;
37;  longitude part
38;
39   basex=widget_info(basedomain,find_by_uname = 'basex')
40   IF basex NE 0 THEN widget_control, basex, /destroy
41   basex=widget_base(basedomain,/row, uname='basex')
42   nothing=widget_text(basex,value='longitude', xsize = 10)
43   nothing=cw_selectinterval(basex,dimlist.(sorteddim[0]),uname='xinterval',uvalue={name:'xinterval'})
44;
45;  latitude part
46;
47   basey=widget_info(basedomain,find_by_uname = 'basey')
48   IF basey NE 0 THEN widget_control, basey, /destroy
49   basey=widget_base(basedomain,/row, uname='basey')
50   nothing=widget_text(basey,value='latitude', xsize = 10)
51   nothing=cw_selectinterval(basey,reverse(dimlist.(sorteddim[1])), uname='yinterval',uvalue={name:'yinterval'})
52;
53;  depth part
54;
55   basez=widget_info(basedomain,find_by_uname = 'basez')
56   IF basez NE 0 THEN widget_control, basez, /destroy
57   basez=widget_base(basedomain,/row, uname='basez')
58   nothing=widget_text(basez,value='depth', xsize = 10)
59   nothing=cw_selectinterval(basez,dimlist.(sorteddim[2]),uname='zinterval',uvalue={name:'zinterval'})
60;
61end
62;
Note: See TracBrowser for help on using the repository browser.