<> <> <> <> <<>> DIRECTORY Buttons, Imager, Rope, TiogaButtons, ViewerClasses; AtomButtonsTypes: CEDAR DEFINITIONS = BEGIN Viewer: TYPE = ViewerClasses.Viewer; <> FeedbackData: TYPE = REF FeedbackDataObj; FeedbackDataObj: TYPE = RECORD [ label: Viewer, atomName: ATOM ]; <<>> <> GBChoiceList: TYPE = LIST OF GraphicsButtonChoice; GraphicsButtonChoice: TYPE = RECORD [ event: LIST OF REF ANY ]; UpdateGraphicsButtonProc: TYPE = PROC [clientData: REF ANY, stateInfo: GraphicsState]; RepaintProc: TYPE = PROC [dc: Imager.Context, clientData: REF ANY, buttonData: REF ANY, button: Viewer]; GraphicsState: TYPE = REF GraphicsStateObj; GraphicsStateObj: TYPE = RECORD [ button: Viewer _ NIL, clientData: REF ANY, buttonData: REF ANY, atom: ATOM, repaintProc: RepaintProc, handleProc: HandleButtonProc, choices: GBChoiceList ]; <> HandleButtonProc: TYPE = PROC [clientData: REF ANY, event: LIST OF REF ANY]; InitButtonProc: TYPE = PROC [name: Rope.ROPE, clientData: REF ANY, button: Viewer]; ConfirmProc: TYPE = PROC [clientData: REF ANY]; <> StateType: TYPE = {off, on}; TwoState: TYPE = REF TwoStateObj; TwoStateObj: TYPE = RECORD [button: Buttons.Button _ NIL, state: StateType _ off, action: LIST OF REF ANY, clientData: REF ANY, handleProc: HandleButtonProc]; <<>> <> ButtonList: TYPE = LIST OF Rope.ROPE; EnumTypeRef: TYPE = REF EnumTypeRec; EnumTypeRec: TYPE = RECORD [ atom: ATOM, namesOfButtons: ButtonList _ NIL, -- list of names of buttons in this Enumerated type nextx: CARDINAL, -- next x position in container that client may begin displaying info so that it wont overwrite the buttons nexty: CARDINAL, -- similar to nextx type: DisplayStyle, buttonOn: Buttons.Button _ NIL, -- the button currently on for a given enumerated type flipLabel: Viewer _ NIL, -- points to the Viewer to re-label clientData: REF ANY _ NIL, -- optional data provided by the client and used when the selection notifier procedure is called handleProc: HandleButtonProc ]; StyleChoice: TYPE = {menuSelection, flipThru}; DisplayStyle: TYPE = {menuStyle, flipThruWithTitle, flipThruNoTitle}; ScalarButtonHandle: TYPE = REF ScalarButtonHandleObj; ScalarButtonHandleObj: TYPE = RECORD [viewer: Viewer, headerButton: TiogaButtons.TiogaButton, scalarButtons: ScalarButtonClient, handleProc: HandleButtonProc]; ScalarButtonClient: TYPE = REF ScalarButtonClientObj; ScalarButtonClientObj: TYPE = RECORD [button: TiogaButtons.TiogaButton, name: Rope.ROPE, value: REAL, action: LIST OF REF ANY, on: BOOL, next: ScalarButtonClient, clientData: REF ANY, handleProc: HandleButtonProc]; END.