4 * [Generated from drag, 25 September 1996]
7 #if !defined(__CC_NORCROFT) || !defined(__arm)
8 #error You must use the Norcroft ARM Compiler for Sapphire programs
11 #pragma include_only_once
12 #pragma force_top_level
21 /*----- Overview ----------------------------------------------------------*
33 /* --- drag_start --- *
35 * On entry: R0 == window containing the drag
36 * R1 == flags word (see flags below)
37 * R2 == pointer to drag routine
38 * R3 == magic number to pass in R9
39 * R4 == value to pass to routine in R10
40 * R5 == value to pass to routine in R12
44 * Use: Starts a drag operation. Any outstanding drag operation
45 * is cancelled on the assumption that someone stole our
49 extern routine drag_start;
51 /* --- drag_scroll --- *
53 * On entry: R1 == pointer to window state block
55 * On exit: R2,R3 == new scroll positions to set
56 * R14 == R1+20 (pointer to scroll offsets)
58 * Use: Works out the scroll positions which should be set to auto-
59 * scroll the window. The algorithm is simple: the window is
60 * scrolled so that the point beneath the mouse pointer is
61 * within the window's visible work area.
64 extern routine drag_scroll;
66 /* --- drag_setDash --- *
68 * On entry: R0 == dash pattern byte
72 * Use: Sets the dash pattern to be the given value.
75 extern routine drag_setDash;
77 /* --- drag_cancel --- *
83 * Use: Cancels the current drag operation.
86 extern routine drag_cancel;
88 /* --- drag_redraw --- *
90 * On entry: R1 == pointer to redraw block
94 * Use: Redraws the drag box, if the redraw takes place in the
95 * currently dragging window.
98 extern routine drag_redraw;
100 /* --- drag_eorColour --- *
102 * On entry: R0 == colour A
107 * Use: Sets the foreground colour to be an EOR colour such that
108 * when painted over Wimp colour A, it appears as Wimp colour B.
111 extern routine drag_eorColour;
113 /*----- Flags -------------------------------------------------------------*/
115 #define drFlag_noUpdate ((1<<0))
117 /*----- Drag handler events -----------------------------------------------*/
121 * The events which request that you draw something are called for each
122 * rectangle of the draw operation -- i.e. do not call Wimp_GetRectangle
123 * because this is done for you.
126 #define drEvent_draw 0
128 #define drEvent_undraw 1
130 #define drEvent_update 2
132 #define drEvent_trans 3
134 #define drEvent_getPos 4
136 #define drEvent_done 5
138 #define drEvent_cancel 6
140 /*----- That's all, folks -------------------------------------------------*/