Listing: 1 IMPLEMENTATION MODULE InputManager; 2 (* 3 * REPERTOIRE 4 * Release 1.6 5 * By Charles Bradford and Cole Brecheen 6 * (c) Copyright 1985-1992 PMI 7 * Green Bay, Wisconsin 8 * All rights reserved 9 * (414) 468-6040 10 * 11 * $Header: D:/logfiles/mods/inputman.mov 1.5 10 Mar 1991 15:28:34 coleb $ 12 * 13 *) 14 15 16 17 IMPORT BigSets; 18 IMPORT ErrorManager; 19 IMPORT ErrorNames; 20 IMPORT FieldTypes; 21 IMPORT FrameManager; 22 IMPORT FramePainter; 23 IMPORT GenLists; 24 IMPORT KbdInput; 25 IMPORT Key; 26 IMPORT ListUtils; 27 IMPORT M2Strings; 28 IMPORT MsgBox2; 29 IMPORT Numbers; 30 IMPORT PosUtils; 31 IMPORT Rectangles; 32 IMPORT ScrnTypes; 33 IMPORT ScrnUtl1; 34 IMPORT StrConv; 35 IMPORT StrEdit; 36 IMPORT SYSTEM; 37 IMPORT UserOps; 38 IMPORT VWindows; 39 40 VAR 41 Initialized : BOOLEAN; 42 43 PROCEDURE Init(); 44 BEGIN 45 IF Initialized THEN 46 RETURN; 47 ELSE 48 Initialized := TRUE; 49 END; 50 BigSets.Init(); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 51 ErrorManager.Init(); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 52 ErrorNames.Init(); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 53 FieldTypes.Init(); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 54 FrameManager.Init(); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 55 FramePainter.Init(); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 56 GenLists.Init(); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 57 KbdInput.Init(); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 58 Key.Init(); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 59 ListUtils.Init(); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 60 M2Strings.Init(); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 61 MsgBox2.Init(); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 62 Numbers.Init(); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 63 PosUtils.Init(); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 64 Rectangles.Init(); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 65 ScrnTypes.Init(); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 66 ScrnUtl1.Init(); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 67 StrConv.Init(); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 68 StrEdit.Init(); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 69 UserOps.Init(); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 70 VWindows.Init(); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 71 END Init; ***** ^ not supported yet 72 73 CONST 74 RequiredMessage = "This field must be filled in. Press Return to continue."; ***** ^ not supported yet 75 76 PROCEDURE GetScrollableArea(TheFrame : ScrnTypes.DisplayFrame; ***** ^ not supported yet 77 VAR ScrollRect : Rectangles.ARectangle); ***** ^ not supported yet 78 (* 79 Returns a rectangle with the absolute field coordinates of 80 the scrollable area in the frame 81 *) 82 BEGIN 83 ScrnUtl1.GetVisibleArea(TheFrame, ScrollRect); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 84 (* Gets physical screen coordinates of visible part of frame. *) 85 IF TheFrame^.headline > 0 THEN ***** ^ not supported yet ***** ^ not supported yet 86 IF NOT ScrnUtl1.BoxInFrame(TheFrame) THEN ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 87 INC(ScrollRect.row1, TheFrame^.headline) ***** ^ undeclared identifier ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 88 ELSE 89 INC(ScrollRect.row1, TheFrame^.headline-1) ***** ^ undeclared identifier ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 90 END; 91 END; 92 END GetScrollableArea; ***** ^ not supported yet 93 94 95 PROCEDURE ClosestField( TheFrame: ScrnTypes.DisplayFrame; ***** ^ not supported yet 96 TheField, col, row: CARDINAL; direction: VWindows.Compass ): CARDINAL; ***** ^ not supported yet 97 98 (*Returns the number of the field closest to TheField in the 99 direction specified. If you pass 0 to col and row, it 100 figures out where TheField is automatically. If you pass 0 101 to TheField, it assumes the cursor is presently outside of 102 a field, and that col and row indicate where it is.*) 103 104 VAR 105 dist, FieldCount, BestGuess, BestDistance, 106 ListStart, ListEnd, StartField, OldField: CARDINAL; 107 p1, p2, BestPoint: Rectangles.APoint; ***** ^ not supported yet 108 109 PROCEDURE Candidate( TheFrame: ScrnTypes.DisplayFrame; ***** ^ not supported yet 110 TheField: CARDINAL; VAR Cursor, FieldSpot: 111 Rectangles.APoint; direction: VWindows.Compass; VAR dist: ***** ^ not supported yet ***** ^ not supported yet 112 CARDINAL ): BOOLEAN; 113 VAR 114 tmpcol, tmprow: CARDINAL; 115 BEGIN 116 tmpcol := ScrnUtl1.VirtualFieldCol( TheFrame, TheField ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 117 tmprow := ScrnUtl1.VirtualFieldRow( TheFrame, TheField ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 118 FieldSpot.col := INTEGER(tmpcol); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 119 FieldSpot.row := INTEGER(tmprow); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 120 121 CASE direction OF ***** ^ not supported yet 122 VWindows.North, VWindows.NE, VWindows.NW: ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 123 IF (tmprow >= CARDINAL(Cursor.row)) THEN ***** ^ not supported yet ***** ^ not supported yet 124 RETURN FALSE; 125 END 126 ELSE 127 END; 128 CASE direction OF ***** ^ not supported yet 129 VWindows.South, VWindows.SE, VWindows.SW: ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 130 IF (tmprow <= CARDINAL(Cursor.row)) THEN ***** ^ not supported yet ***** ^ not supported yet 131 RETURN FALSE; 132 END; 133 ELSE 134 END; 135 CASE direction OF ***** ^ not supported yet 136 VWindows.East, VWindows.SE, VWindows.NE: ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 137 IF (tmpcol <= CARDINAL(Cursor.col)) THEN ***** ^ not supported yet ***** ^ not supported yet 138 RETURN FALSE; 139 END 140 ELSE 141 END; 142 CASE direction OF ***** ^ not supported yet 143 VWindows.West, VWindows.NW, VWindows.SW: ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 144 IF (tmpcol >= CARDINAL(Cursor.col)) THEN ***** ^ not supported yet ***** ^ not supported yet 145 RETURN FALSE; 146 END; 147 ELSE 148 END; 149 dist := Rectangles.Distance( Cursor, p2 ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 150 RETURN TRUE; 151 END Candidate; ***** ^ not supported yet 152 153 BEGIN (*ClosestField*) 154 OldField := TheFrame^.CurrentField; ***** ^ not supported yet ***** ^ not supported yet 155 IF TheField # 0 THEN 156 col := ScrnUtl1.VirtualFieldCol( TheFrame, TheField ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 157 row := ScrnUtl1.VirtualFieldRow( TheFrame, TheField ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 158 ELSE 159 TheFrame^.CurrentField := 0; ***** ^ not supported yet ***** ^ not supported yet 160 END; 161 p1.col := INTEGER(col); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 162 p1.row := INTEGER(row); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 163 BestGuess := 0; 164 BestDistance := 65535; 165 166 CASE direction OF ***** ^ not supported yet 167 VWindows.East, VWindows.SW, VWindows.South, VWindows.SE: ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 168 ListEnd := LastInputField(TheFrame); ***** ^ undeclared identifier ***** ^ not supported yet 169 FieldCount := NextInputField( TheFrame, 0 ); ***** ^ undeclared identifier ***** ^ not supported yet ***** ^ not supported yet 170 BestPoint.col := 32767; ***** ^ not supported yet ***** ^ not supported yet 171 BestPoint.row := 32767; ***** ^ not supported yet ***** ^ not supported yet 172 LOOP 173 IF TheFrame^.CurrentField = ListEnd THEN ***** ^ not supported yet ***** ^ not supported yet 174 EXIT 175 END; 176 IF Candidate( TheFrame, FieldCount, p1, p2, direction, dist ) THEN ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 177 IF (dist < BestDistance) THEN 178 BestDistance := dist; 179 BestPoint := p2; ***** ^ not supported yet ***** ^ not supported yet 180 BestGuess := FieldCount; 181 END; 182 IF (direction = VWindows.South) ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 183 AND (p2.row > BestPoint.row) THEN ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 184 EXIT 185 ELSIF (direction = VWindows.East) AND ((p2.col > ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 186 BestPoint.col) OR (p2.row > BestPoint.row)) THEN ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 187 EXIT 188 END; 189 END; 190 TheFrame^.CurrentField := FieldCount; ***** ^ not supported yet ***** ^ not supported yet 191 FieldCount := NextInputField( TheFrame, 0 ); ***** ^ undeclared identifier ***** ^ not supported yet ***** ^ not supported yet 192 END; 193 ELSE 194 ListStart := FirstInputField(TheFrame); ***** ^ undeclared identifier ***** ^ not supported yet 195 FieldCount := PrevInputField( TheFrame, 0 ); ***** ^ undeclared identifier ***** ^ not supported yet ***** ^ not supported yet 196 BestPoint.col := 0; ***** ^ not supported yet ***** ^ not supported yet 197 BestPoint.row := 0; ***** ^ not supported yet ***** ^ not supported yet 198 LOOP 199 IF TheFrame^.CurrentField = ListStart THEN ***** ^ not supported yet ***** ^ not supported yet 200 EXIT 201 END; 202 IF Candidate( TheFrame, FieldCount, p1, p2, direction, dist ) THEN ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 203 IF (dist < BestDistance) THEN 204 BestDistance := dist; 205 BestPoint := p2; ***** ^ not supported yet ***** ^ not supported yet 206 BestGuess := FieldCount; 207 END; 208 IF (direction = VWindows.North) ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 209 AND (p2.row < BestPoint.row) THEN ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 210 EXIT 211 ELSIF (direction = VWindows.West) AND ((p2.col < ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 212 BestPoint.col) OR (p2.row < BestPoint.row)) THEN ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 213 EXIT 214 END; 215 END; 216 TheFrame^.CurrentField := FieldCount; ***** ^ not supported yet ***** ^ not supported yet 217 FieldCount := PrevInputField( TheFrame, 0 ); ***** ^ undeclared identifier ***** ^ not supported yet ***** ^ not supported yet 218 END; 219 END; 220 221 TheFrame^.CurrentField := OldField; ***** ^ not supported yet ***** ^ not supported yet 222 (* Preserve current field *) 223 IF BestGuess # 0 THEN 224 RETURN BestGuess; 225 ELSE 226 RETURN TheField; 227 END; 228 END ClosestField; ***** ^ not supported yet 229 230 231 232 PROCEDURE InSameRow( TheFrame: ScrnTypes.DisplayFrame; Field1, Field2: ***** ^ not supported yet 233 CARDINAL ): BOOLEAN; 234 BEGIN 235 RETURN (ScrnUtl1.VirtualFieldRow(TheFrame, Field1) = ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 236 ScrnUtl1.VirtualFieldRow(TheFrame, Field2) ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 237 END InSameRow; ***** ^ not supported yet 238 239 240 PROCEDURE InSameCol( TheFrame: ScrnTypes.DisplayFrame; Field1, Field2: ***** ^ not supported yet 241 CARDINAL ): BOOLEAN; 242 BEGIN 243 RETURN (ScrnUtl1.VirtualFieldCol(TheFrame, Field1) = ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 244 ScrnUtl1.VirtualFieldCol(TheFrame, Field2) ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 245 END InSameCol; ***** ^ not supported yet 246 247 248 (*Probably ought to move following two procedures to MakeFrame and 249 add Horizontal boolean to FieldRecType.*) 250 251 PROCEDURE InHorizGroup( TheFrame: ScrnTypes.DisplayFrame; TheField: ***** ^ not supported yet 252 CARDINAL ): BOOLEAN; 253 BEGIN 254 IF ScrnUtl1.FieldType( TheFrame, TheField ) # ScrnTypes.GroupMember THEN ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 255 RETURN FALSE; 256 END; 257 IF ScrnUtl1.ChoiceNumber( TheFrame, TheField ) < ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 258 ScrnUtl1.NumberOfChoices( TheFrame, TheField ) THEN ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 259 IF (NOT InSameRow( TheFrame, TheField, TheField + 1 )) THEN ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 260 RETURN FALSE; 261 END; 262 END; 263 IF ScrnUtl1.ChoiceNumber( TheFrame, TheField ) > 1 THEN ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 264 IF (NOT InSameRow( TheFrame, TheField, TheField - 1 )) THEN ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 265 RETURN FALSE; 266 END; 267 END; 268 RETURN TRUE; 269 END InHorizGroup; ***** ^ not supported yet 270 271 PROCEDURE InVerticalGroup( TheFrame: ScrnTypes.DisplayFrame; TheField: ***** ^ not supported yet 272 CARDINAL ): BOOLEAN; 273 BEGIN 274 IF ScrnUtl1.FieldType( TheFrame, TheField ) # ScrnTypes.GroupMember THEN ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 275 RETURN FALSE; 276 END; 277 IF ScrnUtl1.ChoiceNumber( TheFrame, TheField ) < ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 278 ScrnUtl1.NumberOfChoices( TheFrame, TheField ) THEN ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 279 IF (NOT InSameCol( TheFrame, TheField, TheField + 1 )) THEN ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 280 RETURN FALSE; 281 END; 282 END; 283 IF ScrnUtl1.ChoiceNumber( TheFrame, TheField ) > 1 THEN ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 284 IF (NOT InSameCol( TheFrame, TheField, TheField - 1 )) THEN ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 285 RETURN FALSE; 286 END; 287 END; 288 RETURN TRUE; 289 END InVerticalGroup; ***** ^ not supported yet 290 291 292 PROCEDURE NextSelection( TheFrame: ScrnTypes.DisplayFrame; TheField: ***** ^ not supported yet 293 CARDINAL ): CARDINAL; 294 VAR 295 TmpPtr: ScrnTypes.InputFieldPtr; ***** ^ not supported yet 296 BEGIN 297 ScrnUtl1.GetFieldPtr( TheFrame, TheField, TmpPtr ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 298 IF TmpPtr^.GroupID = TmpPtr^.GroupSize THEN ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 299 RETURN ScrnUtl1.FirstMember( TheFrame, TheField ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 300 ELSE 301 RETURN TheField + 1; 302 END; 303 END NextSelection; ***** ^ not supported yet 304 305 306 PROCEDURE PrevSelection( TheFrame: ScrnTypes.DisplayFrame; TheField: ***** ^ not supported yet 307 CARDINAL ): CARDINAL; 308 VAR 309 TmpPtr: ScrnTypes.InputFieldPtr; ***** ^ not supported yet 310 BEGIN 311 ScrnUtl1.GetFieldPtr( TheFrame, TheField, TmpPtr ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 312 IF TmpPtr^.GroupID = 1 THEN ***** ^ not supported yet ***** ^ not supported yet 313 RETURN ScrnUtl1.FirstMember( TheFrame, TheField ) ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 314 + TmpPtr^.GroupSize - 1; ***** ^ not supported yet ***** ^ not supported yet 315 ELSE 316 RETURN TheField - 1; 317 END; 318 END PrevSelection; ***** ^ not supported yet 319 320 PROCEDURE SelectionKeyMatch( TheFrame: ScrnTypes.DisplayFrame; KeyHit: ***** ^ not supported yet 321 CARDINAL; VAR SelectedFieldNum: CARDINAL ): BOOLEAN; 322 VAR 323 found: BOOLEAN; 324 ListEnd, cnt: CARDINAL; 325 FieldPtr: ScrnTypes.InputFieldPtr; ***** ^ not supported yet 326 BEGIN 327 IF KeyHit = 0 THEN 328 (*Jonathan March's 21 Jun 88 fix.*) 329 RETURN FALSE; 330 END; 331 cnt := 0; 332 found := FALSE; 333 ListEnd := GenLists.ListLength( TheFrame^.FieldList ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 334 WHILE (NOT found) AND (cnt < ListEnd) DO 335 INC( cnt ); ***** ^ undeclared identifier ***** ^ not supported yet 336 ScrnUtl1.GetFieldPtr( TheFrame, cnt, FieldPtr ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 337 IF FieldPtr^.typ = ScrnTypes.GotoCode THEN ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 338 found := KbdInput.CAPkey(KeyHit) = KbdInput.CAPkey(FieldPtr^.MenuKey); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 339 ELSIF FieldPtr^.typ = ScrnTypes.GroupMember THEN ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 340 found := KbdInput.CAPkey(KeyHit) = KbdInput.CAPkey(FieldPtr^.ChoiceKey); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 341 END; 342 END; 343 IF found THEN 344 SelectedFieldNum := cnt; 345 END; 346 RETURN found; 347 END SelectionKeyMatch; ***** ^ not supported yet 348 349 350 PROCEDURE InSameGroup( TheFrame: ScrnTypes.DisplayFrame; Field1, Field2: ***** ^ not supported yet 351 CARDINAL ): BOOLEAN; 352 BEGIN 353 IF (ScrnUtl1.FieldType(TheFrame, Field1) # ScrnTypes.GroupMember) OR ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 354 (ScrnUtl1.FieldType(TheFrame, Field2) # ScrnTypes.GroupMember) THEN ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 355 RETURN FALSE; 356 END; 357 RETURN ScrnUtl1.FirstMember( TheFrame, Field1 ) = ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 358 ScrnUtl1.FirstMember( TheFrame, Field2 ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 359 END InSameGroup; ***** ^ not supported yet 360 361 362 PROCEDURE MoveToSelected( VAR TheFrame: ScrnTypes.DisplayFrame; VAR ***** ^ not supported yet 363 TheField: CARDINAL ); 364 (* Pass this routine any field number that's a GroupMember, 365 and it moves TheFrame^.CurrentField to the selected member 366 of the group (and also sets TheField to the field number 367 of that member). We assume the caller has sense enough 368 not to call this for fields that are not GroupMembers. *) 369 VAR 370 cnt, FieldNum: CARDINAL; 371 TmpPtr: ScrnTypes.InputFieldPtr; ***** ^ not supported yet 372 BEGIN 373 FieldNum := ScrnUtl1.FirstMember( TheFrame, ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 374 TheField ); ***** ^ not supported yet 375 TheField := FieldNum; 376 (*Save the number of the first choice in TheField, in 377 case we don't find one that's selected.*) 378 cnt := 1; 379 LOOP 380 ScrnUtl1.GetFieldPtr( TheFrame, FieldNum, TmpPtr ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 381 IF (cnt = TmpPtr^.GroupSize) OR (TmpPtr^.selected) THEN ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 382 EXIT; 383 END; 384 INC( FieldNum ); ***** ^ undeclared identifier ***** ^ not supported yet 385 INC( cnt ); ***** ^ undeclared identifier ***** ^ not supported yet 386 END; 387 IF TmpPtr^.selected THEN ***** ^ not supported yet ***** ^ not supported yet 388 TheFrame^.CurrentField := FieldNum; ***** ^ not supported yet ***** ^ not supported yet 389 TheField := FieldNum; 390 ELSE 391 TheFrame^.CurrentField := TheField; ***** ^ not supported yet ***** ^ not supported yet 392 ScrnUtl1.GetFieldPtr( TheFrame, TheField, TmpPtr ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 393 (* 28 Dec 88: added this to guarantee that we're 394 setting the ^.selected field of the first choice 395 field rather than the last one. Fix contributed by 396 Ulrik Schmidt. *) 397 TmpPtr^.selected := TRUE; ***** ^ not supported yet ***** ^ not supported yet 398 END; 399 END MoveToSelected; ***** ^ not supported yet 400 401 402 PROCEDURE RequiredFilled( FrameRec: ScrnTypes.DisplayFrame; VAR FieldNum: ***** ^ not supported yet 403 CARDINAL ): BOOLEAN; 404 VAR 405 LocalList : GenLists.GenList; ***** ^ not supported yet 406 TmpPtr: ScrnTypes.InputFieldPtr; ***** ^ not supported yet 407 ImagePtr: ScrnTypes.ImageElmtPtr; ***** ^ not supported yet 408 ListEnd : CARDINAL; 409 BEGIN 410 ListEnd := ScrnUtl1.FieldListTotal( FrameRec ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 411 FieldNum := 1; 412 WHILE FieldNum <= ListEnd DO 413 (* look at each required field, until one is not filled *) 414 ScrnUtl1.GetFieldPtr( FrameRec, FieldNum, TmpPtr ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 415 IF (TmpPtr^.typ = ScrnTypes.EditorCode) AND TmpPtr^.req THEN ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 416 (*We've got a required Editor field*) 417 IF ScrnUtl1.ListFromEdField( FrameRec, ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 418 FrameRec^.CurrentField, LocalList ) AND ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 419 ListUtils.IsBlankList( LocalList ) THEN ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 420 RETURN FALSE; 421 END; 422 ELSIF TmpPtr^.req THEN ***** ^ not supported yet ***** ^ not supported yet 423 ScrnUtl1.GetFieldImagePtr( FrameRec, FieldNum, ImagePtr ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 424 (* if field is required and not filled, flag it and exit *) 425 IF PosUtils.IsBlank( ImagePtr^.text ) THEN ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 426 RETURN FALSE; 427 END; 428 END; 429 INC( FieldNum ); ***** ^ undeclared identifier ***** ^ not supported yet 430 END; 431 FieldNum := 0; 432 RETURN TRUE; 433 END RequiredFilled; ***** ^ not supported yet 434 435 436 PROCEDURE MakeLegalKeys( TheFrame: ScrnTypes.DisplayFrame; VAR ***** ^ not supported yet 437 NewLegalKeys: KbdInput.KeyNumSet ); ***** ^ not supported yet 438 (* construct the sets of legal keys for the field types *) 439 VAR 440 tmpkey, ListEnd, cnt: CARDINAL; 441 FieldPtr: ScrnTypes.InputFieldPtr; ***** ^ not supported yet 442 BEGIN 443 BigSets.SetUnion( UserOps.ScreenKeySet, ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 444 UserOps.FunctKeySet, NewLegalKeys ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 445 (*Add the FunctKeySet to the ScreenKeySet.*) 446 ListEnd := ScrnUtl1.FieldListTotal( TheFrame ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 447 IF ListEnd = 0 THEN 448 RETURN; 449 END; 450 FOR cnt := 1 TO ListEnd DO 451 ScrnUtl1.GetFieldPtr( TheFrame, cnt, FieldPtr ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 452 CASE FieldPtr^.typ OF ***** ^ not supported yet ***** ^ not supported yet 453 ScrnTypes.GotoCode, ScrnTypes.GroupMember: ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 454 IF FieldPtr^.typ = ScrnTypes.GotoCode THEN ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 455 tmpkey := FieldPtr^.MenuKey; ***** ^ not supported yet ***** ^ not supported yet 456 ELSE 457 tmpkey := FieldPtr^.ChoiceKey; ***** ^ not supported yet ***** ^ not supported yet 458 END; 459 IF (tmpkey >= ORD('a')) AND (tmpkey <= ORD('z')) THEN ***** ^ undeclared identifier ***** ^ not supported yet ***** ^ undeclared identifier ***** ^ not supported yet 460 (*This stuff gives us case insensitivity in selection 461 characters.*) 462 BigSets.InclSet( NewLegalKeys, tmpkey ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 463 BigSets.InclSet( NewLegalKeys, KbdInput.CAPkey(tmpkey) ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 464 ELSIF (tmpkey >= ORD('A')) AND (tmpkey <= ORD('Z')) THEN ***** ^ undeclared identifier ***** ^ not supported yet ***** ^ undeclared identifier ***** ^ not supported yet 465 BigSets.InclSet( NewLegalKeys, tmpkey ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 466 BigSets.InclSet( NewLegalKeys, tmpkey + 32 ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 467 ELSE 468 BigSets.InclSet( NewLegalKeys, tmpkey ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 469 END; 470 ELSE 471 (* fall through *) 472 END; 473 END; 474 END MakeLegalKeys; ***** ^ not supported yet 475 476 477 PROCEDURE MovePointerBar( FrameRec: ScrnTypes.DisplayFrame; NewField : ***** ^ not supported yet 478 CARDINAL ); 479 VAR 480 TmpStr : ARRAY [0..80] OF CHAR; ***** ^ not supported yet ***** ^ not supported yet 481 NewRowsScrolled, NewColsScrolled : CARDINAL; 482 FirstFieldCol, FirstFieldRow, LastFieldCol, LastFieldRow : CARDINAL; 483 FirstVisibleRow, FirstVisibleCol, LastVisibleRow, 484 LastVisibleCol : CARDINAL; 485 Vis : Rectangles.ARectangle; ***** ^ not supported yet 486 487 PROCEDURE ChangeSelection( TheFrame: ScrnTypes.DisplayFrame; NewField: ***** ^ not supported yet 488 CARDINAL ); 489 VAR 490 FieldPtr: ScrnTypes.InputFieldPtr; ***** ^ not supported yet 491 BEGIN 492 ScrnUtl1.GetFieldPtr( TheFrame, TheFrame^.CurrentField, ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 493 FieldPtr ); ***** ^ not supported yet 494 FieldPtr^.selected := FALSE; ***** ^ not supported yet ***** ^ not supported yet 495 FramePainter.RedrawField( FrameRec, FrameRec^.CurrentField, FALSE ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 496 (* Takes the pointer bar off the old field. *) 497 FramePainter.RedrawField( TheFrame, NewField, TRUE ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 498 TheFrame^.CurrentField := NewField; ***** ^ not supported yet ***** ^ not supported yet 499 ScrnUtl1.GetFieldPtr( TheFrame, TheFrame^.CurrentField, ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 500 FieldPtr ); ***** ^ not supported yet 501 FieldPtr^.selected := TRUE; ***** ^ not supported yet ***** ^ not supported yet 502 IF UserOps.DoPrompting THEN ***** ^ not supported yet ***** ^ not supported yet 503 GetPromptStr( FrameRec, FrameRec^.CurrentField, TmpStr ); ***** ^ undeclared identifier ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 504 ShowPrompt( FrameRec, TmpStr ); ***** ^ undeclared identifier ***** ^ not supported yet ***** ^ not supported yet 505 END; 506 END ChangeSelection; ***** ^ not supported yet 507 508 BEGIN (* MovePointerBar *) 509 IF NewField < FirstInputField(FrameRec) THEN ***** ^ undeclared identifier ***** ^ not supported yet 510 NewField := LastInputField(FrameRec); ***** ^ undeclared identifier ***** ^ not supported yet 511 ELSIF NewField > LastInputField( FrameRec ) THEN ***** ^ undeclared identifier ***** ^ not supported yet 512 NewField := FirstInputField(FrameRec); ***** ^ undeclared identifier ***** ^ not supported yet 513 ELSIF (ScrnUtl1.FieldType(FrameRec, NewField) = ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 514 ScrnTypes.DispCode) THEN ***** ^ not supported yet ***** ^ not supported yet 515 NewField := NextInputField( FrameRec, 0 ); ***** ^ undeclared identifier ***** ^ not supported yet ***** ^ not supported yet 516 END; 517 IF NewField = FrameRec^.CurrentField THEN ***** ^ not supported yet ***** ^ not supported yet 518 RETURN; 519 ELSIF FrameRec^.CurrentField = 0 THEN ***** ^ not supported yet ***** ^ not supported yet 520 FrameRec^.CurrentField := FirstInputField(FrameRec); ***** ^ not supported yet ***** ^ not supported yet ***** ^ undeclared identifier ***** ^ not supported yet 521 ELSIF InSameGroup( FrameRec, FrameRec^.CurrentField, ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 522 NewField) THEN ***** ^ not supported yet 523 ChangeSelection( FrameRec, NewField ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 524 RETURN; 525 ELSE 526 FramePainter.RedrawField( FrameRec, FrameRec^.CurrentField, FALSE ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 527 (* Takes the pointer bar off the old field. This is 528 in the ELSE clause because, if CurrentField is 0, 529 we're placing the first pointer bar, and we don't 530 need to take it off any other field.*) 531 END; 532 IF ScrnUtl1.FieldType(FrameRec, NewField) = ScrnTypes.GroupMember THEN ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 533 (* This doesn't actually redraw the new field with the 534 pointer bar on it. It just sets the variables that 535 will put us on the right field if we're moving into 536 a group from somewhere outside it; notice that we RETURN 537 above if we're moving inside the same group. *) 538 MoveToSelected( FrameRec, NewField ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 539 END; 540 541 FrameRec^.CurrentField := NewField; ***** ^ not supported yet ***** ^ not supported yet 542 (* Now we've lost track of what the old field was. *) 543 544 (* Check and see if scrolling is needed *) 545 IF NOT ScrnUtl1.EntirelyVisible(FrameRec, NewField) THEN ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 546 GetScrollableArea(FrameRec, Vis); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 547 548 FirstVisibleRow := CARDINAL(Vis.row1) + FrameRec^.RowsScrolled ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 549 - FrameRec^.startrow; ***** ^ not supported yet ***** ^ not supported yet 550 LastVisibleRow := CARDINAL(Vis.row2) + FrameRec^.RowsScrolled ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 551 - FrameRec^.startrow; ***** ^ not supported yet ***** ^ not supported yet 552 FirstVisibleCol := CARDINAL(Vis.col1) + FrameRec^.ColsScrolled ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 553 - FrameRec^.startcol; ***** ^ not supported yet ***** ^ not supported yet 554 LastVisibleCol := CARDINAL(Vis.col2) + FrameRec^.ColsScrolled ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 555 - FrameRec^.startcol; ***** ^ not supported yet ***** ^ not supported yet 556 557 FirstFieldRow := ScrnUtl1.VirtualFieldRow(FrameRec, NewField); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 558 FirstFieldCol := ScrnUtl1.VirtualFieldCol(FrameRec, NewField); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 559 LastFieldRow := FirstFieldRow + 560 ScrnUtl1.FieldHeight(FrameRec, NewField) - 1; ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 561 LastFieldCol := FirstFieldCol + 562 ScrnUtl1.FieldWidth(FrameRec, NewField) - 1; ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 563 (* Default to no scrolling *) 564 NewRowsScrolled := FrameRec^.RowsScrolled; ***** ^ not supported yet ***** ^ not supported yet 565 NewColsScrolled := FrameRec^.ColsScrolled; ***** ^ not supported yet ***** ^ not supported yet 566 (* Vertical *) 567 IF FirstFieldRow < FirstVisibleRow THEN 568 IF ScrnUtl1.InputFieldsAbove(FrameRec, NewField) THEN ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 569 DEC(NewRowsScrolled, FirstVisibleRow-FirstFieldRow); ***** ^ undeclared identifier ***** ^ not supported yet 570 ELSE 571 (* Make sure any text above first input field is 572 visible. *) 573 NewRowsScrolled := 0; 574 END (* if *); 575 ELSIF LastFieldRow > LastVisibleRow THEN 576 IF ScrnUtl1.InputFieldsBelow(FrameRec, NewField) THEN ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 577 INC(NewRowsScrolled, LastFieldRow-LastVisibleRow); ***** ^ undeclared identifier ***** ^ not supported yet 578 ELSE 579 (* Scroll to bottom of frame *) 580 INC(NewRowsScrolled, ScrnUtl1.PartOutside(FrameRec, Vis, ***** ^ undeclared identifier ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 581 VWindows.South)); ***** ^ not supported yet ***** ^ not supported yet 582 END; 583 END (* if *); 584 (* Horizontal *) 585 IF FirstFieldCol < FirstVisibleCol THEN 586 IF ScrnUtl1.InputFieldsToLeft(FrameRec, NewField) THEN ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 587 DEC(NewColsScrolled, FirstVisibleCol-FirstFieldCol); ***** ^ undeclared identifier ***** ^ not supported yet 588 ELSE 589 NewColsScrolled := 0; 590 END; 591 ELSIF LastFieldCol > LastVisibleCol THEN 592 IF ScrnUtl1.InputFieldsToRight(FrameRec, NewField) THEN ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 593 INC(NewColsScrolled, LastFieldCol-LastVisibleCol); ***** ^ undeclared identifier ***** ^ not supported yet 594 ELSE 595 INC(NewColsScrolled, ScrnUtl1.PartOutside(FrameRec, Vis, ***** ^ undeclared identifier ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 596 VWindows.East)); ***** ^ not supported yet ***** ^ not supported yet 597 END; 598 END (* if *); 599 SlideFrame(FrameRec, FrameRec^.ColsScrolled, NewColsScrolled, ***** ^ undeclared identifier ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 600 FrameRec^.RowsScrolled, NewRowsScrolled); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 601 END (* if not entirely visible *); 602 603 IF ScrnUtl1.FieldType(FrameRec, NewField) # ScrnTypes.EditorCode THEN ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 604 FramePainter.RedrawField(FrameRec, NewField, TRUE); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 605 (* Hightlight field *) 606 END; 607 IF UserOps.DoPrompting THEN ***** ^ not supported yet ***** ^ not supported yet 608 GetPromptStr( FrameRec, FrameRec^.CurrentField, TmpStr ); ***** ^ undeclared identifier ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 609 ShowPrompt( FrameRec, TmpStr ); ***** ^ undeclared identifier ***** ^ not supported yet ***** ^ not supported yet 610 END; 611 END MovePointerBar; ***** ^ not supported yet 612 613 614 PROCEDURE PageDown(TheFrame : ScrnTypes.DisplayFrame); ***** ^ not supported yet 615 (* 616 Move to the field nearest to one scroll height below 617 the current one. 618 *) 619 VAR 620 Vis : Rectangles.ARectangle; ***** ^ not supported yet 621 NewField, ScrollHeight, NewRow, NewCol, Distance : CARDINAL; 622 BEGIN 623 IF ScrnUtl1.EntirelyVisible( TheFrame, LastInputField(TheFrame) ) THEN ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ undeclared identifier ***** ^ not supported yet 624 MovePointerBar( TheFrame, LastInputField(TheFrame) ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ undeclared identifier ***** ^ not supported yet 625 RETURN; 626 END; 627 (* 628 The next field isn't currently visible, need to 629 repaint the entire frame 630 *) 631 GetScrollableArea(TheFrame, Vis); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 632 ScrollHeight := CARDINAL(Vis.row2-Vis.row1)+1; ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 633 NewRow := ScrnUtl1.VirtualFieldRow(TheFrame, TheFrame^.CurrentField) ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 634 + ScrollHeight; 635 NewCol := ScrnUtl1.VirtualFieldCol(TheFrame, TheFrame^.CurrentField); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 636 NewField := ClosestField(TheFrame, 0, NewCol, NewRow+1, ***** ^ not supported yet ***** ^ not supported yet 637 VWindows.North); ***** ^ not supported yet ***** ^ not supported yet 638 MovePointerBar( TheFrame, NewField ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 639 END PageDown; ***** ^ not supported yet 640 641 642 PROCEDURE PageUp(TheFrame : ScrnTypes.DisplayFrame); ***** ^ not supported yet 643 (* 644 Move to the field nearest to one scroll height above 645 the current one. 646 *) 647 VAR 648 Vis : Rectangles.ARectangle; ***** ^ not supported yet 649 NewField, vrow, ScrollHeight, NewRow, NewCol: CARDINAL; 650 BEGIN 651 GetScrollableArea(TheFrame, Vis); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 652 ScrollHeight := CARDINAL(Vis.row2-Vis.row1)+1; ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 653 IF TheFrame^.RowsScrolled = 0 THEN ***** ^ not supported yet ***** ^ not supported yet 654 MovePointerBar( TheFrame, FirstInputField(TheFrame) ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ undeclared identifier ***** ^ not supported yet 655 ELSE 656 vrow := ScrnUtl1.VirtualFieldRow(TheFrame, TheFrame^.CurrentField); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 657 NewRow := Numbers.IntMax( 1, INTEGER(vrow) - INTEGER(ScrollHeight) ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 658 NewCol := ScrnUtl1.VirtualFieldCol(TheFrame, TheFrame^.CurrentField); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 659 NewField := ClosestField(TheFrame, 0, NewCol, NewRow-1, ***** ^ not supported yet ***** ^ not supported yet 660 VWindows.South); ***** ^ not supported yet ***** ^ not supported yet 661 MovePointerBar( TheFrame, NewField ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 662 END; 663 END PageUp; ***** ^ not supported yet 664 665 666 (*================== Exported Procedures ========================*) 667 668 PROCEDURE FirstInputField(FrameRec : ScrnTypes.DisplayFrame) : CARDINAL; ***** ^ not supported yet 669 VAR 670 LastField, NewField : CARDINAL; 671 BEGIN 672 LastField := ScrnUtl1.FieldListTotal(FrameRec); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 673 NewField := 1; 674 WHILE (ScrnUtl1.FieldType(FrameRec, NewField) = ScrnTypes.DispCode) DO ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 675 IF NewField < LastField THEN 676 INC(NewField); ***** ^ undeclared identifier ***** ^ not supported yet 677 ELSE 678 RETURN 1; 679 END; 680 END (* while *); 681 RETURN NewField; 682 END FirstInputField; ***** ^ not supported yet 683 684 PROCEDURE LastInputField(FrameRec : ScrnTypes.DisplayFrame) : CARDINAL; ***** ^ not supported yet 685 VAR 686 NewField : CARDINAL; 687 BEGIN 688 NewField := ScrnUtl1.FieldListTotal(FrameRec); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 689 WHILE (ScrnUtl1.FieldType(FrameRec, NewField) = ScrnTypes.DispCode) DO ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 690 IF NewField > 1 THEN 691 DEC(NewField); ***** ^ undeclared identifier ***** ^ not supported yet 692 ELSE 693 RETURN ScrnUtl1.FieldListTotal(FrameRec); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 694 END (* if *); 695 END (* while *); 696 RETURN NewField; 697 END LastInputField; ***** ^ not supported yet 698 699 PROCEDURE NextInputField( FrameRec : ScrnTypes.DisplayFrame; ***** ^ not supported yet 700 skip: CARDINAL ): CARDINAL; 701 VAR 702 LastField, NewField : CARDINAL; 703 BEGIN 704 LastField := ScrnUtl1.FieldListTotal(FrameRec); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 705 IF FrameRec^.CurrentField < (LastField - skip) THEN ***** ^ not supported yet ***** ^ not supported yet 706 NewField := FrameRec^.CurrentField + skip + 1; ***** ^ not supported yet ***** ^ not supported yet 707 ELSE 708 NewField := 1; 709 END; 710 WHILE (ScrnUtl1.FieldType(FrameRec, NewField) = ScrnTypes.DispCode) ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 711 AND (NewField # FrameRec^.CurrentField) DO ***** ^ not supported yet ***** ^ not supported yet 712 IF NewField < LastField THEN 713 INC(NewField); ***** ^ undeclared identifier ***** ^ not supported yet 714 ELSE 715 NewField := 1; 716 END; 717 END (* while *); 718 RETURN NewField; 719 END NextInputField; ***** ^ not supported yet 720 721 PROCEDURE PrevInputField( VAR FrameRec : ScrnTypes.DisplayFrame; ***** ^ not supported yet 722 skip: CARDINAL ) : CARDINAL; 723 VAR 724 NewField : CARDINAL; 725 BEGIN 726 IF (FrameRec^.CurrentField + skip) > 1 THEN ***** ^ not supported yet ***** ^ not supported yet 727 NewField := (FrameRec^.CurrentField - skip) - 1; ***** ^ not supported yet ***** ^ not supported yet 728 ELSE 729 NewField := ScrnUtl1.FieldListTotal(FrameRec); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 730 END; 731 WHILE (ScrnUtl1.FieldType(FrameRec, NewField) = ScrnTypes.DispCode) ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 732 AND (NewField # FrameRec^.CurrentField) DO ***** ^ not supported yet ***** ^ not supported yet 733 IF NewField > 1 THEN 734 DEC(NewField); ***** ^ undeclared identifier ***** ^ not supported yet 735 ELSE 736 NewField := ScrnUtl1.FieldListTotal(FrameRec); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 737 END; 738 END (* while *); 739 RETURN NewField; 740 END PrevInputField; ***** ^ not supported yet 741 742 743 PROCEDURE HiLiteSelChars( TheFrame: ScrnTypes.DisplayFrame ); ***** ^ not supported yet 744 VAR 745 FieldListEnd, cnt: CARDINAL; 746 TmpType : CHAR; 747 BEGIN 748 FieldListEnd := ScrnUtl1.FieldListTotal( TheFrame ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 749 FOR cnt := 1 TO FieldListEnd DO 750 TmpType := ScrnUtl1.FieldType( TheFrame, cnt ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 751 IF (TmpType = ScrnTypes.GotoCode) OR ***** ^ not supported yet ***** ^ not supported yet 752 (TmpType = ScrnTypes.GroupMember) THEN ***** ^ not supported yet ***** ^ not supported yet 753 IF ScrnUtl1.EntirelyVisible( TheFrame, cnt ) THEN ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 754 FramePainter.RedrawField( TheFrame, cnt, FALSE ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 755 END; 756 END; 757 END; 758 END HiLiteSelChars; ***** ^ not supported yet 759 760 761 PROCEDURE LookAlive( TheFrame: ScrnTypes.DisplayFrame ); ***** ^ not supported yet 762 VAR 763 TmpStr: ARRAY [0..127] OF CHAR; ***** ^ not supported yet ***** ^ not supported yet 764 fldtype : CHAR; 765 BEGIN 766 IF TheFrame^.action <= 'Z' THEN ***** ^ not supported yet ***** ^ not supported yet 767 (* We are temporarily lowercasing the .action character 768 to tell us whether the frame is under the control of 769 ControlFrame. We use this to disable LookAlive when 770 it is called in places where it probably shouldn't be. 771 Not good. *) 772 RETURN; 773 END; 774 HiLiteSelChars( TheFrame ); ***** ^ not supported yet ***** ^ not supported yet 775 IF (TheFrame^.CurrentField > 0) AND ***** ^ not supported yet ***** ^ not supported yet 776 (TheFrame^.CurrentField <= ScrnUtl1.FieldListTotal(TheFrame)) THEN ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 777 IF UserOps.DoPrompting THEN ***** ^ not supported yet ***** ^ not supported yet 778 GetPromptStr( TheFrame, TheFrame^.CurrentField, TmpStr ); ***** ^ undeclared identifier ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 779 ShowPrompt( TheFrame, TmpStr ); ***** ^ undeclared identifier ***** ^ not supported yet ***** ^ not supported yet 780 END; 781 fldtype := ScrnUtl1.FieldType( TheFrame, TheFrame^.CurrentField ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 782 IF ScrnUtl1.EntirelyVisible( TheFrame, TheFrame^.CurrentField ) THEN ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 783 FramePainter.RedrawField( TheFrame, TheFrame^.CurrentField, TRUE ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 784 IF (fldtype # ScrnTypes.GotoCode) AND (fldtype # ***** ^ not supported yet ***** ^ not supported yet 785 ScrnTypes.GroupMember) AND (fldtype # ***** ^ not supported yet ***** ^ not supported yet 786 ScrnTypes.DispCode) THEN ***** ^ not supported yet ***** ^ not supported yet 787 VWindows.SetCursorHeight( VWindows.CurrentWindow, 2 ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 788 END; 789 END; 790 END; 791 END LookAlive; ***** ^ not supported yet 792 793 794 PROCEDURE ReconstructFrame( TheFrame: ScrnTypes.DisplayFrame ); ***** ^ not supported yet 795 VAR 796 TmpStr: ARRAY [0..127] OF CHAR; ***** ^ not supported yet ***** ^ not supported yet 797 BEGIN 798 FramePainter.ShowDisplayFrame( TheFrame, 0, 0, 0, 0 ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 799 LookAlive( TheFrame ); ***** ^ not supported yet ***** ^ not supported yet 800 END ReconstructFrame; ***** ^ not supported yet 801 802 803 PROCEDURE ShowPrompt( FrameRec: ScrnTypes.DisplayFrame; ***** ^ not supported yet 804 str : ARRAY OF CHAR ); ***** ^ not supported yet 805 (*Display the prompt centered within the prompt line 806 specified in UserOps.*) 807 VAR 808 tmp: ARRAY [0..127] OF CHAR; ***** ^ not supported yet ***** ^ not supported yet 809 (*We use tmp because the caller may not have left enough 810 room in str to pad it with blanks.*) 811 BEGIN 812 ScrnUtl1.SetPromptColors( FrameRec ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 813 M2Strings.Assign( str, tmp ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 814 StrEdit.Center( tmp, UserOps.PromptLength ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 815 816 VWindows.DrawStr( FrameRec^.WindowHandle, UserOps.PromptCol, ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 817 UserOps.PromptRow, SYSTEM.ADR(tmp), ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 818 UserOps.PromptLength ); ***** ^ not supported yet ***** ^ not supported yet 819 END ShowPrompt; ***** ^ not supported yet 820 821 822 PROCEDURE GetPromptStr( TheFrame: ScrnTypes.DisplayFrame; TheField: ***** ^ not supported yet 823 CARDINAL; VAR TheStr: ARRAY OF CHAR ); ***** ^ not supported yet 824 VAR 825 FieldRec: ScrnTypes.InputFieldRecord; ***** ^ not supported yet 826 TypeCode: CARDINAL; 827 MaxStr, MinStr: ARRAY [0..31] OF CHAR; ***** ^ not supported yet ***** ^ not supported yet 828 BEGIN 829 ScrnUtl1.GetFieldRec( TheFrame, TheField, FieldRec ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 830 IF FieldRec.PromptNum # 0 THEN ***** ^ not supported yet ***** ^ not supported yet 831 GenLists.GetElmt( TheFrame^.PromptList, FieldRec.PromptNum, ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 832 TheStr, TypeCode ); ***** ^ not supported yet ***** ^ not supported yet 833 ELSE 834 FieldTypes.GetDefaultPrompt( FieldRec.typ, TheStr ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 835 CASE FieldRec.typ OF ***** ^ not supported yet ***** ^ not supported yet 836 ScrnTypes.IntCode : ***** ^ not supported yet ***** ^ not supported yet 837 StrConv.LongIntegerToStr( FieldRec.iMax, 1, MaxStr ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 838 StrConv.LongIntegerToStr( FieldRec.iMin, 1, MinStr); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 839 | ScrnTypes.RealCode : ***** ^ not supported yet ***** ^ not supported yet 840 StrConv.RealToStr( FieldRec.rMax, 1, 0, MaxStr ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 841 StrConv.RealToStr( FieldRec.rMin, 1, 0, MinStr); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 842 ELSE 843 RETURN; 844 END; 845 StrEdit.ReplaceStr( 'MAX', MaxStr, TheStr ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 846 StrEdit.ReplaceStr( 'MIN', MinStr, TheStr ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 847 END; 848 END GetPromptStr; ***** ^ not supported yet 849 850 851 PROCEDURE SlideFrame( FrameRec: ScrnTypes.DisplayFrame; ***** ^ not supported yet 852 OldColsScrolled, NewColsScrolled, OldRowsScrolled, 853 NewRowsScrolled: CARDINAL ); 854 VAR 855 Vis: Rectangles.ARectangle; ***** ^ not supported yet 856 vdist, ScrollableHeight : INTEGER; 857 BEGIN 858 FrameRec^.ColsScrolled := NewColsScrolled; ***** ^ not supported yet ***** ^ not supported yet 859 FrameRec^.RowsScrolled := NewRowsScrolled; ***** ^ not supported yet ***** ^ not supported yet 860 vdist := INTEGER(NewRowsScrolled) - INTEGER(OldRowsScrolled); ***** ^ not supported yet ***** ^ not supported yet 861 IF (vdist = 0) AND (NewColsScrolled = OldColsScrolled) THEN 862 RETURN; 863 END; 864 ScrnUtl1.SetNormalColors( FrameRec ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 865 GetScrollableArea( FrameRec, Vis ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 866 WITH Vis DO ***** ^ not supported yet 867 IF NewColsScrolled # OldColsScrolled THEN 868 (*We repaint the whole window if we're going to have to 869 scroll horizontally.*) 870 VWindows.ClearPart( FrameRec^.WindowHandle, col1, ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ undeclared identifier 871 row1, col2, row2 ); ***** ^ undeclared identifier ***** ^ undeclared identifier ***** ^ undeclared identifier 872 FramePainter.RedrawArea( FrameRec, CARDINAL(col1), ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ undeclared identifier 873 CARDINAL(row1), CARDINAL(col2), CARDINAL(row2) ); ***** ^ undeclared identifier ***** ^ undeclared identifier ***** ^ undeclared identifier 874 RETURN; 875 END; 876 ScrollableHeight := CARDINAL(row2) - CARDINAL(row1) + 1; ***** ^ undeclared identifier ***** ^ undeclared identifier 877 IF ABS(vdist) > ScrollableHeight THEN ***** ^ undeclared identifier ***** ^ not supported yet 878 IF vdist > 0 THEN 879 vdist := ScrollableHeight; 880 ELSE 881 vdist := -ScrollableHeight; 882 END; 883 END; 884 IF NOT VWindows.ScrollVertically(FrameRec^.WindowHandle, ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 885 col1, row1, col2, row2, vdist ) THEN ***** ^ undeclared identifier ***** ^ undeclared identifier ***** ^ undeclared identifier ***** ^ undeclared identifier ***** ^ not supported yet 886 (*tough luck if the window manager doesn't support scrolling*) 887 END; 888 IF vdist > 0 THEN 889 (*Redraw the area at the bottom because we scrolled up.*) 890 FramePainter.RedrawArea( FrameRec, CARDINAL(col1), ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ undeclared identifier 891 (CARDINAL(row2) - CARDINAL(ABS(vdist))) + 1, ***** ^ undeclared identifier ***** ^ undeclared identifier ***** ^ not supported yet 892 CARDINAL(col2), CARDINAL(row2) ); ***** ^ undeclared identifier ***** ^ undeclared identifier 893 ELSE 894 (*Redraw the area at the top because we scrolled down.*) 895 FramePainter.RedrawArea( FrameRec, CARDINAL(col1), ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ undeclared identifier 896 CARDINAL(row1),CARDINAL(col2),CARDINAL(row1+ABS(vdist)-1)); ***** ^ undeclared identifier ***** ^ undeclared identifier ***** ^ undeclared identifier ***** ^ undeclared identifier ***** ^ not supported yet ***** ^ not supported yet 897 END (* if *); 898 END (* with Vis *); ***** ^ not supported yet 899 END SlideFrame; ***** ^ not supported yet 900 901 902 PROCEDURE ControlFrame(VAR FrameRec : ScrnTypes.DisplayFrame; ***** ^ not supported yet 903 LandingField : CARDINAL; message : ARRAY OF CHAR; ***** ^ not supported yet 904 RedrawFirst : BOOLEAN; VAR NextFrame: ScrnTypes.AFrameName ); ***** ^ not supported yet 905 VAR 906 MaxChoices, SavedFieldNum: CARDINAL; 907 ReturnValue, FrameAbove, FrameBelow, FrameLeft, 908 FrameRight : ScrnTypes.AFrameName; ***** ^ not supported yet 909 LastKey : CARDINAL; 910 AbsFldCol, AbsFldRow: INTEGER; 911 LocalMessage : ARRAY [0..79] OF CHAR; ***** ^ not supported yet ***** ^ not supported yet 912 TmpScreenKeys: KbdInput.KeyNumSet; ***** ^ not supported yet 913 FieldRec: ScrnTypes.InputFieldRecord; ***** ^ not supported yet 914 915 916 PROCEDURE HitAnyKey( VAR NextFrame: ScrnTypes.AFrameName ); ***** ^ not supported yet 917 (* prompt for any key to be hit and exit, returning 918 either normal next or TheKeyHandler result (keep 919 asking for input if user asks for help or time) *) 920 VAR 921 key : CARDINAL; 922 tryagain : BOOLEAN; 923 BEGIN 924 IF UserOps.DoPrompting THEN ***** ^ not supported yet ***** ^ not supported yet 925 ShowPrompt( FrameRec, 'Press Any Key To Continue.' ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 926 END; 927 REPEAT 928 key := KbdInput.KeyHit( KbdInput.AnyKeyNum ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 929 IF BigSets.InSet( UserOps.FunctKeySet, key ) THEN ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 930 (* if in special key set, execute user program *) 931 SavedFieldNum := FrameRec^.CurrentField; ***** ^ not supported yet ***** ^ not supported yet 932 UserOps.TheKeyHandler( FrameRec, key, NextFrame ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 933 ScrnUtl1.SetCurrentField( FrameRec, SavedFieldNum ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 934 tryagain := PosUtils.Equal( NextFrame, ScrnTypes.ContinueInput ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 935 ELSE 936 (* they hit a key not in the special key set, so 937 return *) 938 M2Strings.Assign( FrameRec^.normlnext, NextFrame ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 939 tryagain := FALSE; 940 END; 941 UNTIL NOT tryagain; 942 END HitAnyKey; ***** ^ not supported yet 943 944 945 PROCEDURE ShowBadType( FrameRec: ScrnTypes.DisplayFrame ); ***** ^ not supported yet 946 VAR 947 ImageRec: ScrnTypes.ImageElement; ***** ^ not supported yet 948 dumstr: ARRAY [0..79] OF CHAR; ***** ^ not supported yet ***** ^ not supported yet 949 BEGIN 950 ScrnUtl1.GetFieldImageRec( FrameRec, FrameRec^.CurrentField, ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 951 ImageRec ); ***** ^ not supported yet 952 M2Strings.Concat("Bad type in ControlFrame. Text = ", ImageRec.text, ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 953 dumstr ); ***** ^ not supported yet 954 ErrorManager.WARN( dumstr ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 955 END ShowBadType; ***** ^ not supported yet 956 957 958 PROCEDURE NormalKeyResponse( VAR FrameRec: 959 ScrnTypes.DisplayFrame; VAR TheFieldRec: ***** ^ not supported yet 960 ScrnTypes.InputFieldRecord; VAR LastKey: CARDINAL; VAR ***** ^ not supported yet 961 ReturnValue: ScrnTypes.AFrameName ); ***** ^ not supported yet 962 VAR 963 NewField: CARDINAL; 964 BEGIN 965 NewField := FrameRec^.CurrentField; ***** ^ not supported yet ***** ^ not supported yet 966 (*Just in case we don't need to move it.*) 967 IF LastKey = Key.Down THEN ***** ^ not supported yet ***** ^ not supported yet 968 IF InVerticalGroup( FrameRec, FrameRec^.CurrentField ) THEN ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 969 NewField := NextSelection( FrameRec, FrameRec^.CurrentField ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 970 ELSIF NOT ScrnUtl1.InputFieldsBelow( FrameRec, ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 971 FrameRec^.CurrentField ) THEN ***** ^ not supported yet ***** ^ not supported yet 972 IF FrameBelow[0] # 0C THEN ***** ^ not supported yet ***** ^ not supported yet 973 M2Strings.Assign( FrameBelow, ReturnValue ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 974 ELSE 975 NewField := FirstInputField(FrameRec); ***** ^ not supported yet ***** ^ not supported yet 976 END; 977 ELSE 978 NewField := ClosestField( FrameRec, ***** ^ not supported yet ***** ^ not supported yet 979 FrameRec^.CurrentField, 0, 0, VWindows.South ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 980 END; 981 MovePointerBar( FrameRec, NewField ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 982 ELSIF LastKey = Key.Up THEN ***** ^ not supported yet ***** ^ not supported yet 983 IF InVerticalGroup( FrameRec, FrameRec^.CurrentField ) THEN ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 984 NewField := PrevSelection( FrameRec, FrameRec^.CurrentField ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 985 ELSIF NOT ScrnUtl1.InputFieldsAbove( FrameRec, ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 986 FrameRec^.CurrentField ) THEN ***** ^ not supported yet ***** ^ not supported yet 987 IF FrameAbove[0] # 0C THEN ***** ^ not supported yet ***** ^ not supported yet 988 M2Strings.Assign( FrameAbove, ReturnValue ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 989 ELSE 990 NewField := LastInputField( FrameRec ); ***** ^ not supported yet ***** ^ not supported yet 991 END; 992 ELSE 993 NewField := ClosestField( FrameRec, ***** ^ not supported yet ***** ^ not supported yet 994 FrameRec^.CurrentField, 0, 0, VWindows.North ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 995 END; 996 MovePointerBar( FrameRec, NewField ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 997 (* RST Change *) 998 ELSIF LastKey = Key.CtrlPgUp THEN ***** ^ not supported yet ***** ^ not supported yet 999 MovePointerBar( FrameRec, FirstInputField(FrameRec)); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 1000 ELSIF LastKey = Key.CtrlPgDn THEN ***** ^ not supported yet ***** ^ not supported yet 1001 MovePointerBar( FrameRec, LastInputField(FrameRec)); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 1002 ELSIF LastKey = Key.PgUp THEN ***** ^ not supported yet ***** ^ not supported yet 1003 PageUp(FrameRec); ***** ^ not supported yet ***** ^ not supported yet 1004 ELSIF LastKey = Key.PgDn THEN ***** ^ not supported yet ***** ^ not supported yet 1005 PageDown(FrameRec); ***** ^ not supported yet ***** ^ not supported yet 1006 ELSIF LastKey = Key.Right THEN ***** ^ not supported yet ***** ^ not supported yet 1007 IF InHorizGroup( FrameRec, FrameRec^.CurrentField ) THEN ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 1008 NewField := NextSelection( FrameRec, FrameRec^.CurrentField ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 1009 ELSIF (NOT ScrnUtl1.InputFieldsToRight( FrameRec, ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 1010 FrameRec^.CurrentField )) AND (FrameRight[0] # 0C) THEN ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 1011 M2Strings.Assign( FrameRight, ReturnValue ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 1012 ELSE 1013 NewField := NextInputField( FrameRec, 0 ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 1014 END; 1015 MovePointerBar( FrameRec, NewField ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 1016 ELSIF LastKey = Key.Left THEN ***** ^ not supported yet ***** ^ not supported yet 1017 IF InHorizGroup( FrameRec, FrameRec^.CurrentField ) THEN ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 1018 NewField := PrevSelection( FrameRec, FrameRec^.CurrentField ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 1019 ELSIF (NOT ScrnUtl1.InputFieldsToLeft( FrameRec, ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 1020 FrameRec^.CurrentField )) AND (FrameLeft[0] # 0C) THEN ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 1021 M2Strings.Assign( FrameLeft, ReturnValue ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 1022 ELSE 1023 NewField := PrevInputField( FrameRec, 0 ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 1024 END; 1025 MovePointerBar( FrameRec, NewField ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 1026 ELSIF LastKey = Key.Tab THEN ***** ^ not supported yet ***** ^ not supported yet 1027 MovePointerBar( FrameRec, NextInputField( FrameRec, 0 )); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 1028 ELSIF LastKey = Key.BackTab THEN ***** ^ not supported yet ***** ^ not supported yet 1029 MovePointerBar( FrameRec, PrevInputField( FrameRec, 0 )); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 1030 ELSIF LastKey = Key.Return THEN ***** ^ not supported yet ***** ^ not supported yet 1031 IF TheFieldRec.typ = ScrnTypes.GotoCode THEN ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 1032 (* force jump *) 1033 M2Strings.Assign( TheFieldRec.ReturnVal, ReturnValue ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 1034 ELSIF (TheFieldRec.typ = ScrnTypes.GroupMember) THEN ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 1035 IF (MaxChoices = 1) THEN 1036 (* There are no other fields in the frame except 1037 this group. We know we have to leave, but first 1038 we have to choose a return value (for 1039 compatibility with 1.4.) *) 1040 IF M2Strings.Length(TheFieldRec.fnam) > 0 THEN ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 1041 (*This lets you store the return value in the 1042 field name of the choice. *) 1043 M2Strings.Assign( TheFieldRec.fnam, ReturnValue ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 1044 ELSE 1045 M2Strings.Assign( FrameRec^.normlnext, ReturnValue ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 1046 END; 1047 ELSE 1048 (* There are fields outside this group. Move to the 1049 first one following it.*) 1050 NewField := NextInputField( FrameRec, (TheFieldRec.GroupSize - ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 1051 TheFieldRec.GroupID) ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 1052 MovePointerBar( FrameRec, NewField ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 1053 END; 1054 ELSIF MaxChoices#1 THEN 1055 MovePointerBar( FrameRec, NextInputField( FrameRec, 0 ) ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 1056 ELSE 1057 M2Strings.Assign( FrameRec^.normlnext, ReturnValue); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 1058 (* only one field, and it's an input field; leave.*) 1059 END; 1060 ELSIF SelectionKeyMatch( FrameRec, LastKey, NewField ) THEN ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 1061 MovePointerBar( FrameRec, NewField ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 1062 ScrnUtl1.GetFieldRec( FrameRec, NewField, TheFieldRec ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 1063 IF (ScrnUtl1.AllFieldsThisType(FrameRec, ScrnTypes.GotoCode)) THEN ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 1064 (* If the user presses the selection character of a menu item 1065 and the frame contains a mixture of field types, we move the 1066 pointer bar to the goto field, but we don't submit the frame, as 1067 we do if the frame contains only goto fields. If you want to 1068 submit the frame in that case, change this IF to 1069 something like 'IF TheFieldRec.typ = ScrnTypes.GotoCode' *) 1070 M2Strings.Assign( TheFieldRec.ReturnVal, ReturnValue ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 1071 END; 1072 IF (ScrnUtl1.AllFieldsThisType(FrameRec, ScrnTypes.GroupMember)) THEN ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 1073 M2Strings.Assign( TheFieldRec.fnam, ReturnValue ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 1074 END; 1075 END; 1076 END NormalKeyResponse; ***** ^ not supported yet 1077 1078 1079 PROCEDURE NoFieldsKeyResponse( VAR FrameRec: ScrnTypes.DisplayFrame; ***** ^ not supported yet 1080 VAR LastKey: CARDINAL; VAR ReturnValue: ScrnTypes.AFrameName ); ***** ^ not supported yet 1081 VAR 1082 VisibleArea: Rectangles.ARectangle; ***** ^ not supported yet 1083 nOutside, oldcs, oldrs, WindowHeight: CARDINAL; 1084 BEGIN 1085 ScrnUtl1.GetVisibleArea( FrameRec, VisibleArea ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 1086 WindowHeight := VisibleArea.row2 - VisibleArea.row1 + 1; ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 1087 oldcs := FrameRec^.ColsScrolled; ***** ^ not supported yet ***** ^ not supported yet 1088 oldrs := FrameRec^.RowsScrolled; ***** ^ not supported yet ***** ^ not supported yet 1089 StrEdit.AssignStr( ScrnTypes.ContinueInput, ReturnValue ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 1090 IF LastKey = Key.Down THEN ***** ^ not supported yet ***** ^ not supported yet 1091 IF ScrnUtl1.PartOutside( FrameRec, VisibleArea, ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 1092 VWindows.South ) > 0 THEN ***** ^ not supported yet ***** ^ not supported yet 1093 INC( FrameRec^.RowsScrolled ); ***** ^ undeclared identifier ***** ^ not supported yet ***** ^ not supported yet 1094 END; 1095 ELSIF LastKey = Key.Up THEN ***** ^ not supported yet ***** ^ not supported yet 1096 IF ScrnUtl1.PartOutside( FrameRec, VisibleArea, ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 1097 VWindows.North ) > 0 THEN ***** ^ not supported yet ***** ^ not supported yet 1098 DEC( FrameRec^.RowsScrolled ); ***** ^ undeclared identifier ***** ^ not supported yet ***** ^ not supported yet 1099 END; 1100 ELSIF LastKey = Key.PgUp THEN ***** ^ not supported yet ***** ^ not supported yet 1101 IF ScrnUtl1.PartOutside( FrameRec, VisibleArea, ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 1102 VWindows.North ) > WindowHeight THEN ***** ^ not supported yet ***** ^ not supported yet 1103 DEC( FrameRec^.RowsScrolled, WindowHeight ); ***** ^ undeclared identifier ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 1104 ELSE 1105 FrameRec^.RowsScrolled := 0; ***** ^ not supported yet ***** ^ not supported yet 1106 END; 1107 ELSIF LastKey = Key.PgDn THEN ***** ^ not supported yet ***** ^ not supported yet 1108 IF ScrnUtl1.PartOutside( FrameRec, VisibleArea, ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 1109 VWindows.South ) > WindowHeight THEN ***** ^ not supported yet ***** ^ not supported yet 1110 INC( FrameRec^.RowsScrolled, WindowHeight ); ***** ^ undeclared identifier ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 1111 ELSIF FrameRec^.VirtualHeight > WindowHeight THEN ***** ^ not supported yet ***** ^ not supported yet 1112 FrameRec^.RowsScrolled := FrameRec^.VirtualHeight - WindowHeight; ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 1113 ELSE 1114 FrameRec^.RowsScrolled := 0; ***** ^ not supported yet ***** ^ not supported yet 1115 END; 1116 ELSIF LastKey = Key.Right THEN ***** ^ not supported yet ***** ^ not supported yet 1117 IF ScrnUtl1.PartOutside( FrameRec, VisibleArea, ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 1118 VWindows.East ) > 0 THEN ***** ^ not supported yet ***** ^ not supported yet 1119 INC( FrameRec^.ColsScrolled ); ***** ^ undeclared identifier ***** ^ not supported yet ***** ^ not supported yet 1120 END; 1121 ELSIF LastKey = Key.Left THEN ***** ^ not supported yet ***** ^ not supported yet 1122 IF ScrnUtl1.PartOutside( FrameRec, VisibleArea, ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 1123 VWindows.West ) > 0 THEN ***** ^ not supported yet ***** ^ not supported yet 1124 DEC( FrameRec^.ColsScrolled ); ***** ^ undeclared identifier ***** ^ not supported yet ***** ^ not supported yet 1125 END; 1126 ELSIF LastKey = Key.Tab THEN ***** ^ not supported yet ***** ^ not supported yet 1127 nOutside := ScrnUtl1.PartOutside( FrameRec, VisibleArea, VWindows.East); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 1128 IF nOutside > 8 THEN 1129 INC( FrameRec^.ColsScrolled, 8 ); ***** ^ undeclared identifier ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 1130 ELSIF nOutside > 0 THEN 1131 INC( FrameRec^.ColsScrolled, nOutside); ***** ^ undeclared identifier ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 1132 END; 1133 ELSIF LastKey = Key.BackTab THEN ***** ^ not supported yet ***** ^ not supported yet 1134 nOutside := ScrnUtl1.PartOutside( FrameRec, VisibleArea,VWindows.West); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 1135 IF nOutside > 8 THEN 1136 DEC( FrameRec^.ColsScrolled, 8 ); ***** ^ undeclared identifier ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 1137 ELSIF nOutside > 0 THEN 1138 DEC( FrameRec^.ColsScrolled, nOutside); ***** ^ undeclared identifier ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 1139 END; 1140 ELSIF LastKey = Key.Return THEN ***** ^ not supported yet ***** ^ not supported yet 1141 M2Strings.Assign( FrameRec^.normlnext, ReturnValue); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 1142 RETURN; 1143 END; 1144 SlideFrame( FrameRec, oldcs, FrameRec^.ColsScrolled, ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 1145 oldrs, FrameRec^.RowsScrolled ); ***** ^ not supported yet ***** ^ not supported yet 1146 END NoFieldsKeyResponse; ***** ^ not supported yet 1147 1148 1149 PROCEDURE RepaintVisibleArea(); 1150 VAR 1151 FirstVisibleRow, FirstVisibleCol, LastVisibleRow, 1152 LastVisibleCol : CARDINAL; 1153 Vis : Rectangles.ARectangle; ***** ^ not supported yet 1154 BEGIN 1155 ScrnUtl1.GetVisibleArea(FrameRec, Vis); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 1156 WITH Vis DO ***** ^ not supported yet 1157 FirstVisibleRow := CARDINAL(row1); ***** ^ undeclared identifier 1158 LastVisibleRow := CARDINAL(row2); ***** ^ undeclared identifier 1159 FirstVisibleCol := CARDINAL(col1); ***** ^ undeclared identifier 1160 LastVisibleCol := CARDINAL(col2); ***** ^ undeclared identifier 1161 (* 11 Oct 88: removed +RowsScrolled from each of 1162 these lines at suggestion of Karta Khalsa and 1163 Ulrik Schmidt. *) 1164 END; ***** ^ not supported yet 1165 FramePainter.RedrawArea( FrameRec, FirstVisibleCol, FirstVisibleRow, ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ undeclared identifier ***** ^ undeclared identifier 1166 LastVisibleCol, LastVisibleRow); ***** ^ undeclared identifier ***** ^ undeclared identifier 1167 END RepaintVisibleArea; ***** ^ not supported yet 1168 1169 BEGIN 1170 (*ControlFrame*) 1171 1172 VWindows.SetCursorHeight( FrameRec^.WindowHandle, 0 ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ undeclared identifier ***** ^ not supported yet ***** ^ not supported yet 1173 M2Strings.Assign(message, LocalMessage); ***** ^ not supported yet ***** ^ not supported yet ***** ^ undeclared identifier ***** ^ undeclared identifier 1174 IF RedrawFirst THEN ***** ^ undeclared identifier 1175 RepaintVisibleArea(); ***** ^ undeclared identifier ***** ^ not supported yet 1176 END; 1177 1178 MaxChoices := ScrnUtl1.FieldGroupTotal( FrameRec ); ***** ^ undeclared identifier ***** ^ not supported yet ***** ^ not supported yet ***** ^ undeclared identifier 1179 (* Number of choices or fields in the frame, counting each 1180 group of choice fields as a single choice. *) 1181 M2Strings.Assign( FrameRec^.normlnext, NextFrame ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ undeclared identifier ***** ^ not supported yet ***** ^ undeclared identifier 1182 MakeLegalKeys( FrameRec, TmpScreenKeys ); ***** ^ not supported yet ***** ^ undeclared identifier ***** ^ undeclared identifier 1183 StrEdit.LowerStr( FrameRec^.action ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ undeclared identifier ***** ^ not supported yet 1184 (* Added 13 Nov 88. We lowercase the action char while 1185 the frame is active and restore it to uppercase when it is 1186 not so that we have a temporary way of determining 1187 whether the frame is active. Don't rely on this. In 1188 a future release we will add a boolean to the DisplayFrame 1189 record and quit using this kludge. *) 1190 IF CAP(FrameRec^.action) = ScrnTypes.DispCode THEN ***** ^ undeclared identifier ***** ^ undeclared identifier ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 1191 (* Do not process user input. Note that we don't call 1192 EraseFrame if the frame is both DisplayOnly and 1193 ClearAfter, since this combination really doesn't make 1194 sense -- latter is probably programmer's mistake. *) 1195 RETURN; 1196 END; 1197 IF FrameRec^.EntryBox[0] # 0C THEN ***** ^ undeclared identifier ***** ^ not supported yet ***** ^ not supported yet 1198 (*Now we change the appearance of the border to let the 1199 user know the frame is active.*) 1200 ScrnUtl1.BoxFrame( FrameRec, TRUE ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ undeclared identifier ***** ^ not supported yet 1201 END; 1202 IF (CAP(FrameRec^.action) = 'W') THEN ***** ^ undeclared identifier ***** ^ undeclared identifier ***** ^ not supported yet 1203 (* wait for any user input, then exit *) 1204 HitAnyKey( NextFrame ); ***** ^ undeclared identifier ***** ^ undeclared identifier 1205 IF FrameRec^.ExitBox[0] # 0C THEN ***** ^ undeclared identifier ***** ^ not supported yet ***** ^ not supported yet 1206 (*Now we change the appearance of the border to let the 1207 user know the frame is no longer active.*) 1208 ScrnUtl1.BoxFrame( FrameRec, FALSE ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ undeclared identifier ***** ^ not supported yet 1209 END; 1210 IF FrameRec^.ClearAfter THEN ***** ^ undeclared identifier ***** ^ not supported yet 1211 FrameManager.EraseFrame( FrameRec ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ undeclared identifier 1212 END; 1213 RETURN; 1214 END; 1215 HiLiteSelChars( FrameRec ); ***** ^ not supported yet ***** ^ undeclared identifier 1216 StrEdit.SetLength( ReturnValue, 0 ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ undeclared identifier ***** ^ not supported yet 1217 ScrnUtl1.GetFrameLinks( FrameRec, FrameAbove, FrameBelow, FrameLeft, ***** ^ not supported yet ***** ^ not supported yet ***** ^ undeclared identifier ***** ^ undeclared identifier ***** ^ undeclared identifier ***** ^ undeclared identifier 1218 FrameRight ); ***** ^ undeclared identifier 1219 FrameRec^.CurrentField := 0; ***** ^ undeclared identifier ***** ^ not supported yet 1220 (*Prevent MovePointerBar from exiting if CurrentField 1221 happens to equal LandingField.*) 1222 IF (LandingField=0) AND (MaxChoices > 0) THEN ***** ^ undeclared identifier ***** ^ undeclared identifier 1223 MovePointerBar( FrameRec, FirstInputField(FrameRec)); ***** ^ not supported yet ***** ^ undeclared identifier ***** ^ not supported yet ***** ^ undeclared identifier 1224 (*highlights first choice*) 1225 END; 1226 1227 REPEAT 1228 IF (LandingField # 0) AND (MaxChoices > 0) THEN ***** ^ undeclared identifier ***** ^ undeclared identifier 1229 (* LandingField is not 0, so highlight the specified 1230 field. We do this at the top of each loop so that 1231 ControlFrame can signal errors from within the loop. *) 1232 MovePointerBar( FrameRec, LandingField ); ***** ^ not supported yet ***** ^ undeclared identifier ***** ^ undeclared identifier 1233 LandingField := 0; ***** ^ undeclared identifier 1234 END; 1235 IF M2Strings.Length( LocalMessage ) > 0 THEN ***** ^ not supported yet ***** ^ not supported yet ***** ^ undeclared identifier 1236 MsgBox2.StrMsgBox( FrameRec, VWindows.SE, LocalMessage ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ undeclared identifier ***** ^ not supported yet ***** ^ not supported yet ***** ^ undeclared identifier 1237 StrEdit.SetLength( LocalMessage, 0 ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ undeclared identifier ***** ^ not supported yet 1238 END; 1239 1240 IF (MaxChoices = 0) OR ***** ^ undeclared identifier 1241 (ScrnUtl1.AllFieldsThisType(FrameRec, ScrnTypes.DispCode)) THEN ***** ^ not supported yet ***** ^ not supported yet ***** ^ undeclared identifier ***** ^ not supported yet ***** ^ not supported yet 1242 LastKey := KbdInput.KeyHit( TmpScreenKeys ); ***** ^ undeclared identifier ***** ^ not supported yet ***** ^ not supported yet ***** ^ undeclared identifier 1243 UserOps.TheKeyHandler( FrameRec, LastKey, ReturnValue ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ undeclared identifier ***** ^ undeclared identifier ***** ^ undeclared identifier 1244 IF PosUtils.Equal( ReturnValue, ScrnTypes.ContinueInput ) THEN ***** ^ not supported yet ***** ^ not supported yet ***** ^ undeclared identifier ***** ^ not supported yet ***** ^ not supported yet 1245 NoFieldsKeyResponse( FrameRec, LastKey, ReturnValue ); ***** ^ undeclared identifier ***** ^ undeclared identifier ***** ^ undeclared identifier ***** ^ undeclared identifier 1246 END; 1247 ELSE 1248 ScrnUtl1.GetFieldRec( FrameRec, FrameRec^.CurrentField, FieldRec ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ undeclared identifier ***** ^ undeclared identifier ***** ^ not supported yet ***** ^ undeclared identifier 1249 SavedFieldNum := FrameRec^.CurrentField; ***** ^ undeclared identifier ***** ^ undeclared identifier ***** ^ not supported yet 1250 CASE FieldRec.typ OF ***** ^ undeclared identifier ***** ^ not supported yet 1251 ScrnTypes.GotoCode, ScrnTypes.GroupMember : ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 1252 LastKey := KbdInput.KeyHit( TmpScreenKeys ); ***** ^ undeclared identifier ***** ^ not supported yet ***** ^ not supported yet ***** ^ undeclared identifier 1253 UserOps.TheKeyHandler( FrameRec, LastKey, ReturnValue ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ undeclared identifier ***** ^ undeclared identifier ***** ^ undeclared identifier 1254 ELSE 1255 AbsFldRow := ScrnUtl1.AbsFieldRow(FrameRec, ***** ^ undeclared identifier ***** ^ not supported yet ***** ^ not supported yet ***** ^ undeclared identifier 1256 FrameRec^.CurrentField); ***** ^ undeclared identifier ***** ^ not supported yet 1257 AbsFldCol := ScrnUtl1.AbsFieldCol(FrameRec, ***** ^ undeclared identifier ***** ^ not supported yet ***** ^ not supported yet ***** ^ undeclared identifier 1258 FrameRec^.CurrentField); ***** ^ undeclared identifier ***** ^ not supported yet 1259 UserOps.TheFieldHandler( FrameRec, ***** ^ not supported yet ***** ^ not supported yet ***** ^ undeclared identifier 1260 AbsFldCol, AbsFldRow, LastKey, ReturnValue ); ***** ^ undeclared identifier ***** ^ undeclared identifier ***** ^ undeclared identifier ***** ^ undeclared identifier 1261 ScrnUtl1.GetFieldRec( FrameRec, FrameRec^.CurrentField, ***** ^ not supported yet ***** ^ not supported yet ***** ^ undeclared identifier ***** ^ undeclared identifier ***** ^ not supported yet 1262 FieldRec ); ***** ^ undeclared identifier 1263 IF FieldRec.ChangeMade THEN ***** ^ undeclared identifier ***** ^ not supported yet 1264 FrameRec^.FrameChanged := TRUE; ***** ^ undeclared identifier ***** ^ not supported yet 1265 END; 1266 END; 1267 IF PosUtils.Equal( 'MovePointerBar', ReturnValue ) THEN ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ undeclared identifier 1268 StrEdit.AssignStr( ScrnTypes.ContinueInput, ReturnValue ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ undeclared identifier 1269 MovePointerBar( FrameRec, FrameRec^.CurrentField ); ***** ^ not supported yet ***** ^ undeclared identifier ***** ^ undeclared identifier ***** ^ not supported yet 1270 ELSE 1271 ScrnUtl1.SetCurrentField( FrameRec, SavedFieldNum ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ undeclared identifier ***** ^ undeclared identifier 1272 IF PosUtils.Equal( ReturnValue, ScrnTypes.ContinueInput ) THEN ***** ^ not supported yet ***** ^ not supported yet ***** ^ undeclared identifier ***** ^ not supported yet ***** ^ not supported yet 1273 (* Now, process defined action keys *) 1274 NormalKeyResponse( FrameRec, FieldRec, LastKey, ReturnValue ); ***** ^ undeclared identifier ***** ^ undeclared identifier ***** ^ undeclared identifier ***** ^ undeclared identifier ***** ^ undeclared identifier 1275 END; 1276 END; 1277 1278 IF (NOT PosUtils.Equal(ReturnValue, ScrnTypes.ContinueInput)) ***** ^ not supported yet ***** ^ not supported yet ***** ^ undeclared identifier ***** ^ not supported yet ***** ^ not supported yet 1279 AND (LastKey # UserOps.BackupKey) ***** ^ undeclared identifier ***** ^ not supported yet ***** ^ not supported yet 1280 AND (LastKey # UserOps.ExitKey) THEN ***** ^ undeclared identifier ***** ^ not supported yet ***** ^ not supported yet 1281 (* Looks like they want to submit the screen. Let's 1282 check to see if all required fields are full *) 1283 IF PosUtils.Equal( ReturnValue, ScrnTypes.SubmitInput ) THEN ***** ^ not supported yet ***** ^ not supported yet ***** ^ undeclared identifier ***** ^ not supported yet ***** ^ not supported yet 1284 ReturnValue := FrameRec^.normlnext; ***** ^ undeclared identifier ***** ^ undeclared identifier ***** ^ not supported yet 1285 END; 1286 IF PosUtils.Equal( ReturnValue, ScrnTypes.CancelInput ) THEN ***** ^ not supported yet ***** ^ not supported yet ***** ^ undeclared identifier ***** ^ not supported yet ***** ^ not supported yet 1287 ReturnValue := FrameRec^.parent; ***** ^ undeclared identifier ***** ^ undeclared identifier ***** ^ not supported yet 1288 ELSIF (NOT RequiredFilled( FrameRec, LandingField )) THEN ***** ^ not supported yet ***** ^ undeclared identifier ***** ^ undeclared identifier 1289 StrEdit.AssignStr( RequiredMessage, LocalMessage ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ undeclared identifier 1290 LastKey := 65535; ***** ^ undeclared identifier 1291 StrEdit.AssignStr( ScrnTypes.ContinueInput, ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet ***** ^ not supported yet 1292 ReturnValue ); ***** ^ undeclared identifier 1293 (*We do this to make sure we go back through the loop.*) 1294 END; 1295 END; 1296 END; 1297 1298 UNTIL (NOT PosUtils.Equal(ReturnValue, ScrnTypes.ContinueInput)); ***** ^ not supported yet ***** ^ not supported yet ***** ^ undeclared identifier ***** ^ not supported yet ***** ^ not supported yet 1299 1300 M2Strings.Assign( ReturnValue, NextFrame ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ undeclared identifier ***** ^ undeclared identifier 1301 (* 1302 IF MaxChoices > 0 THEN 1303 FramePainter.RedrawField( FrameRec, FrameRec^.CurrentField, FALSE ); 1304 END; 1305 Taken care of by RepaintVisibleArea, below. 1306 *) 1307 FrameRec^.action := CAP( FrameRec^.action ); ***** ^ undeclared identifier ***** ^ not supported yet ***** ^ undeclared identifier ***** ^ undeclared identifier ***** ^ not supported yet 1308 IF FrameRec^.ExitBox[0] # 0C THEN ***** ^ undeclared identifier ***** ^ not supported yet ***** ^ not supported yet 1309 (*Now we change the appearance of the border to let the 1310 user know the frame is no longer active.*) 1311 ScrnUtl1.BoxFrame( FrameRec, FALSE ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ undeclared identifier ***** ^ not supported yet 1312 END; 1313 IF FrameRec^.ClearAfter THEN ***** ^ undeclared identifier ***** ^ not supported yet 1314 FrameManager.EraseFrame( FrameRec ); ***** ^ not supported yet ***** ^ not supported yet ***** ^ undeclared identifier 1315 ELSE 1316 RepaintVisibleArea(); ***** ^ undeclared identifier ***** ^ not supported yet 1317 (* Erases pointer bar and selection characters. We do 1318 this mostly to avoid the problem of restoring things 1319 like highlighted selection characters when things 1320 pop up over inactive frames. *) 1321 END; 1322 END ControlFrame; ***** ^ not supported yet 1323 1324 1325 BEGIN 1326 Initialized := FALSE; 1327 Init(); ***** ^ not supported yet ***** ^ not supported yet 1328 END InputManager. ***** ^ not supported yet 1884 errors