This commit was generated by cvs2svn to compensate for changes in r2,
[u/mrichter/AliRoot.git] / GEANT321 / gdraw / gdelet.F
1 *
2 * $Id$
3 *
4 * $Log$
5 * Revision 1.1.1.1  1995/10/24 10:20:22  cernlib
6 * Geant
7 *
8 *
9 #include "geant321/pilot.h"
10 *CMZ :  3.21/02 29/03/94  15.41.26  by  S.Giani
11 *-- Author :
12       SUBROUTINE GDELET(IVIEW)
13 C.
14 C.    ******************************************************************
15 C.    *                                                                *
16 C.    *       Delete view number IVIEW from view banks                 *
17 C.    *                                                                *
18 C.    *    ==>Called by : <USER>, <GXINT>, GDTR0, GDTR99               *
19 C.    *       Author : P.Zanarini   *********                          *
20 C.    *                                                                *
21 C.    ******************************************************************
22 C.
23 #include "geant321/gcbank.inc"
24 #include "geant321/gcdraw.inc"
25 #include "geant321/gcunit.inc"
26 C.
27 C.    ------------------------------------------------------------------
28 C.
29       IF (IVIEW.GE.1.AND.IVIEW.LE.NKVIEW) THEN
30          IF (LQ(JDRAW-IVIEW).NE.0) THEN
31             IF (Q(JDRAW+IVIEW).NE.3.) THEN
32                Q(JDRAW+IVIEW)=1.
33                CALL MZDROP(IXCONS,LQ(JDRAW-IVIEW),' ')
34 *
35 *             Reset view number to 0 (screen)
36                IF (IDVIEW.EQ.IVIEW) IDVIEW = 0
37 *
38             ELSE
39                WRITE (CHMAIL,10000)
40                CALL GMAIL(0,0)
41 *
42             ENDIF
43 *
44          ENDIF
45 *
46       ENDIF
47 10000 FORMAT (' ERROR IN GDELET: CANNOT DELETE PROTECTED VIEW')
48       END