1 /***********************************************************************/
2 /* Open Visualization Data Explorer                                    */
3 /* (C) Copyright IBM Corp. 1989,1999                                   */
4 /* ALL RIGHTS RESERVED                                                 */
5 /* This code licensed under the                                        */
6 /*    "IBM PUBLIC LICENSE - Open Visualization Data Explorer"          */
7 /***********************************************************************/
8 
9 #include <dxconfig.h>
10 
11 
12 /* Revision 9.1  1997/05/22 18:48:46  svs
13  * Copy of release 3.1.4 code
14  *
15  * Revision 8.0  1995/10/03  18:50:20  nsc
16  * Copy of release 3.1 code
17  *
18  * Revision 7.1  1994/01/18  19:02:57  svs
19  * changes since release 2.0.1
20  *
21  * Revision 6.1  93/11/16  10:51:17  svs
22  * ship level code, release 2.0
23  *
24  * Revision 1.3  93/08/10  14:39:53  jvergo
25  * Added XmNincSensitive resource.
26  *
27  * Revision 1.2  93/07/16  15:05:26  jvergo
28  * Added min/max sensitive control.
29  *
30  * Revision 1.1  93/02/26  16:29:29  danz
31  * Initial revision
32  *
33  *
34  */
35 
36 #ifndef _VCRControlP_h
37 #define _VCRControlP_h
38 
39 #if defined(__cplusplus) || defined(c_plusplus)
40 extern "C" {
41 #endif
42 
43 
44 #include <stdio.h>
45 #include <X11/IntrinsicP.h>
46 #include <X11/Intrinsic.h>
47 #include <X11/StringDefs.h>
48 #include <X11/CoreP.h>
49 #include <X11/Shell.h>
50 #include <X11/CompositeP.h>
51 #include <X11/Composite.h>
52 #include <X11/Constraint.h>
53 #include <Xm/XmP.h>
54 #include <Xm/Xm.h>
55 #include <Xm/BulletinBP.h>
56 #include <Xm/FormP.h>
57 #include <Xm/Form.h>
58 #include <Xm/PushB.h>
59 #include <Xm/PushBG.h>
60 #include <Xm/Frame.h>
61 #include <Xm/FrameP.h>
62 #include <Xm/Label.h>
63 #include <Xm/LabelP.h>
64 #include <Xm/LabelG.h>
65 #include <Xm/LabelGP.h>
66 #include <Xm/DrawingA.h>
67 #include <Xm/DrawingAP.h>
68 #include <Number.h>
69 #include <NumberP.h>
70 #include <Stepper.h>
71 #include <FrameControl.h>
72 
73 typedef struct
74 {
75 	XtPointer	mumble;
76 } XmVCRControlClassPart;
77 
78 typedef struct _XmVCRControlClassRec
79 {
80 	CoreClassPart			core_class;
81 	CompositeClassPart		composite_class;
82 	ConstraintClassPart		constraint_class;
83 	XmManagerClassPart		manager_class;
84 	XmBulletinBoardClassPart	bulletin_board_class;
85 	XmFormClassPart			form_class;
86 	XmVCRControlClassPart		vcr_control_class;
87 } XmVCRControlClassRec;
88 
89 extern XmVCRControlClassRec xmVCRControlClassRec;
90 
91 typedef struct ButtonImageRec {
92     XImage*	 image;
93     GC		 gc;
94     unsigned int background;
95     short	 width, height;
96     Pixmap pixid;
97 } ButtonImage;
98 
99 typedef struct _XmVCRControlPart {
100     Widget              parent;
101     short		min_value;		/* Min app frame number i.e.1 */
102     short		max_value;
103     short		start_value;
104     short		next_value;
105     short		current_value;
106     short		stop_value;
107     short		frame_increment;
108     XtCallbackList	action_callback;	/* Callback for VCR switches  */
109     XtCallbackList	frame_callback;		/* Callback for frame numbers */
110     void *		user_data;		/* To be passed with callback */
111     XmPushButtonWidget	title_bar;
112     XmFrameWidget	frame[10];
113     XmDrawingAreaWidget	button[10];
114     XmLabelWidget	label;
115     XmLabelWidget	dot_dot_dot;
116     XmFrameControlWidget	frame_control;
117     ButtonImage		button_image[10];
118     Boolean		button_is_in[10];
119     XtIntervalId	button_timeout;		/* Delay pushbutton release   */
120     Boolean		step_being_held;	/* Don't release while held   */
121     Widget		shell;
122     Boolean		frame_control_is_up;
123     Pixel		limit_color;
124     Pixel		next_color;
125     Pixel		current_color;
126     Boolean		frame_sensitive;
127     Boolean		min_sensitive;
128     Boolean		max_sensitive;
129     Boolean		inc_sensitive;
130     Boolean		current_visible;
131     Time		last_frame_control_press; /* used to ignore 2x clicks */
132 } XmVCRControlPart;
133 
134 typedef struct _XmVCRControlRec
135 {
136 	CorePart		core;
137 	CompositePart		composite;
138 	ConstraintPart		constraint;
139 	XmManagerPart		manager;
140 	XmBulletinBoardPart	bulletin_board;
141 	XmFormPart		form;
142 	XmVCRControlPart	vcr_control;
143 } XmVCRControlRec;
144 
145 #if defined(__cplusplus) || defined(c_plusplus)
146 }
147 #endif
148 
149 
150 #endif
151