~ubuntu-branches/debian/jessie/eso-midas/jessie

« back to all changes in this revision

Viewing changes to prim/proc/setchan.prg

  • Committer: Package Import Robot
  • Author(s): Ole Streicher
  • Date: 2014-04-22 14:44:58 UTC
  • Revision ID: package-import@ubuntu.com-20140422144458-okiwi1assxkkiz39
Tags: upstream-13.09pl1.2+dfsg
ImportĀ upstreamĀ versionĀ 13.09pl1.2+dfsg

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
! @(#)setchan.prg       19.1 (ESO-DMD) 02/25/03 14:09:01
 
2
! ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
 
3
!
 
4
! MIDAS procedure setchan.prg
 
5
! K. Banse      880224, 910318, 920312
 
6
!
 
7
! execute as   SET/CHAN chanl
 
8
!
 
9
! ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
 
10
!
 
11
define/local lcha/i/1/1 0
 
12
 
13
branch p1(1:1) O,R,G,B,A OVERLAY,RED,GREEN,BLUE,ALL
 
14
!
 
15
define/param p1 ? N "Enter channel no.: " 0,{IDIDEV(16)}
 
16
ididev(15) = {p1}
 
17
return
 
18
!
 
19
OVERLAY:
 
20
ididev(15) = ididev(14)
 
21
return
 
22
!
 
23
RED:
 
24
ididev(15) = 0                                  !we always have a channel 0
 
25
return
 
26
 
27
GREEN:
 
28
lcha = 1
 
29
goto last
 
30
 
31
BLUE:
 
32
lcha = 2
 
33
goto last
 
34
 
35
ALL:
 
36
if ididev(18) .eq. 11 then
 
37
   write/out Invalid qualifier for X11 display...
 
38
   return/exit
 
39
else
 
40
   ididev(15) = 999
 
41
   return
 
42
endif
 
43
 
44
LAST:
 
45
if lcha .gt. ididev(16) then
 
46
   write/out Invalid channel no. ...
 
47
   return/exit
 
48
else
 
49
   ididev(15) = lcha                    !finally update the channel no.
 
50
endif