Last change
on this file since 283 was
262,
checked in by pinsard, 17 years ago
|
corrections of some headers and parameters and keywords case. change of pro2href to replace proidl
|
-
Property svn:eol-style set to
native
-
Property svn:keywords set to
Id
|
File size:
782 bytes
|
Line | |
---|
1 | ;+ |
---|
2 | ; |
---|
3 | ; @file_comments |
---|
4 | ; Find, from an Id of widget, the Id of the widget which is |
---|
5 | ; "the top-level base" (i.e., it has no parent) |
---|
6 | ; |
---|
7 | ; categories |
---|
8 | ; widget |
---|
9 | ; |
---|
10 | ; @param WIDGET_ID |
---|
11 | ; This argument should be the widget ID of the |
---|
12 | ; widget for which information is desired. |
---|
13 | ; |
---|
14 | ; @returns |
---|
15 | ; The Id of the widget which is "the top-level base" |
---|
16 | ; |
---|
17 | ; @history |
---|
18 | ; Sebastien Masson (smasson\@lodyc.jussieu.fr) |
---|
19 | ; 22/9/1999 |
---|
20 | ; |
---|
21 | ; @version |
---|
22 | ; $Id$ |
---|
23 | ; |
---|
24 | ;- |
---|
25 | ; |
---|
26 | FUNCTION findtopid, widget_id |
---|
27 | ; |
---|
28 | compile_opt idl2, strictarrsubs |
---|
29 | ; |
---|
30 | id = long(WIDGET_ID) |
---|
31 | ; exist = widget_info(id, /managed) |
---|
32 | ; if exist EQ 0 then return, -1 |
---|
33 | topid = id |
---|
34 | topid2 = id |
---|
35 | while topid2 NE 0 do begin |
---|
36 | topid = topid2 |
---|
37 | topid2 = widget_info(topid2, /parent) |
---|
38 | endwhile |
---|
39 | return, long(topid) |
---|
40 | end |
---|
Note: See
TracBrowser
for help on using the repository browser.