home *** CD-ROM | disk | FTP | other *** search
/ The Datafile PD-CD 5 / DATAFILE_PDCD5.iso / education / a / identikey / !IdentiKey / ShellLibRT (.txt) < prev    next >
RISC OS BBC BASIC V Source  |  1995-11-12  |  192KB  |  7,049 lines

  1.  >EvntShell:ShellLibRT 
  2.  Squished by Lofty's !Shrink vsn 3.01 on 12-Nov-95 
  3. "*|Start FNshell_LibraryVersion
  4. shell_LibraryVersion
  5. =2.02*&64
  6.     !*|Stop FNshell_LibraryVersion
  7. %*|Start PROCshell_DefineConstants
  8. shell_DefineConstants
  9. _MSE_SELECTBUT=4
  10. _MSE_MENUBUT=2
  11. _MSE_ADJUSTBUT=1
  12. _EVENT_NULL=0
  13. _EVENT_REDRAWWIN=1
  14. _EVENT_OPENWIN=2
  15. _EVENT_CLOSEWIN=3
  16. _EVENT_PTRLEAVING=4
  17. _EVENT_PTRENTERING=5
  18. _EVNT_MSECLICK=6
  19. _POPUP_TYPE_TEXT=0
  20. _POPUP_TYPE_WIMPCOLOUR=1
  21. _POPUP_TYPE_DATEPICK=2
  22. _POPUP_TYPE_CALCULATOR=3
  23. _POPUP_TYPE_FONTPICK=4
  24. _POPUP_TYPE_LINEFONT=5
  25. _POPUP_TYPE_FONTMENU=6
  26. _POPUP_TYPE_TIMEPICK=7
  27. _POPUP_TYPE_COLOUR24=8
  28. _IBAR_RIGHT%=-1
  29. _IBAR_LEFT%=-2
  30. _BUTTON_TYPE_NEVER=0
  31. _BUTTON_TYPE_CLICK=3
  32. >$*|Stop PROCshell_DefineConstants
  33. B)*|Start FNshell_GetLastSecureFileName
  34. shell_GetLastSecureFileName
  35. g%=_U%!80
  36. I(*|Stop FNshell_GetLastSecureFileName
  37. M *|Start FNshell_GetEventMenu
  38. shell_GetEventMenu(HD%,a%,lA%)
  39. f%,n%,w%,EA%,z%
  40. a%=-1
  41. a%=-2
  42. Q&EA%=
  43. shell_HeapBlockInfo(_U%!&C)-8
  44. n%=_U%!&C
  45. U    O$=""
  46. shell_Tracef0("GetEventMenu:Started..")
  47. shell_Tracef0("GetEventMenu:button is "+
  48. shell_Tracef0("GetEventMenu:window is "+
  49. shell_Tracef0("GetEventMenu:icon   is "+
  50. (n%!f%=a%)
  51. shell_Tracef0("GetEventMenu:window handle matched..")
  52. n%!(f%+4)=lA%
  53. shell_Tracef0("GetEventMenu:icon handle matched..")
  54. z%=n%!(f%+8)
  55. z%=-2
  56. z%=_U%!&FC
  57. shell_Tracef0("GetEventMenu:icon handle NOT matched..")
  58. f%+=48
  59. (f%>=EA%
  60. *|Stop FNshell_GetEventMenu
  61. y$*|Start PROCshell_AttachMenuDBox
  62. shell_AttachMenuDBox(UC%,o$,xA$,BB$)
  63. d%,g%,PB%
  64. shell_WindowLoaded(o$)
  65. shell_MessageOneArg("SHELLMSG03",o$)
  66. shell_HeapBlockFetch(&C)
  67. %d%!0=
  68. shell_HeapBlockFetch(
  69. o$+1)
  70. g%=d%!0:$g%=o$
  71. &d%!4=
  72. shell_HeapBlockFetch(
  73. xA$+1)
  74. g%=d%!4:$g%=xA$
  75. &d%!8=
  76. shell_HeapBlockFetch(
  77. BB$+1)
  78. g%=d%!8:$g%=BB$
  79. &45BCE,UC%,d%
  80. &45BCC,,
  81. #*|Stop PROCshell_AttachMenuDBox
  82. !*|Start FNshell_MessageNoArgs
  83. shell_MessageNoArgs(M$)
  84. shell_MessageLookup(M$,"","")
  85.  *|Stop FNshell_MessageNoArgs
  86. !*|Start FNshell_MessageOneArg
  87. shell_MessageOneArg(M$,x$)
  88. shell_MessageLookup(M$,x$,"")
  89.  *|Stop FNshell_MessageOneArg
  90. "*|Start FNshell_MessageTwoArgs
  91. shell_MessageTwoArgs(M$,x$,UA$)
  92. shell_MessageLookup(M$,x$,UA$)
  93. !*|Stop FNshell_MessageTwoArgs
  94. !*|Start FNshell_MessageLookup
  95. shell_MessageLookup(M$,x$,UA$)
  96. o%,L%,t$,DD%,WC%
  97. M$,8)="SHELLMSG"
  98. DD%=_U%!284:WC%=_U%!280
  99. DD%=_U%!64:WC%=_U%!68
  100. &61502,WC%,M$,DD%,256,x$,UA$
  101. ,,,L%;o%
  102. DD%?L%=&D
  103. t$=$(DD%)
  104.  *|Stop FNshell_MessageLookup
  105. *|Start FNshell_WimpInit
  106. shell_WimpInit(vB%,EA$)
  107. AG%,uA%
  108. !AG%=0
  109. shell_OSCheckVersion(3.1)
  110. vB%=310
  111. &400C0,vB%,&4B534154,EA$,AG%
  112. vB%,uA%
  113. vB%=&C8
  114. &400C0,vB%,&4B534154,EA$
  115. vB%,uA%
  116. _U%!&64
  117. "WimpExt_Initialise",&E,uA%
  118. _U%!&94=uA%
  119. *|Stop FNshell_WimpInit
  120. *|Start FNshell_WimpInit_I
  121. shell_WimpInit_I(vB%,EA$)
  122.  uA%=
  123. shell_WimpInit(vB%,EA$)
  124. &81682,uA%
  125. *|Stop FNshell_WimpInit_I
  126. %*|Start PROCshell_WimpCloseDown_I
  127. shell_WimpCloseDown_I(uA%)
  128. shell_ExReg_FontLib_Loaded
  129. shell_Fonts_LoseFonts
  130. *|ifdef Using_FontMenu
  131. shell_ExReg_FontMenu_Loaded
  132. shell_FontMenu_Deregister
  133. *|endif
  134. _U%!&64
  135. "WimpExt_Initialise",&E,uA%
  136. &600DD,uA%,&4B534154
  137. &A1683,uA%
  138. _U%!&64
  139. "XImpulse_CloseDown",_U%!&94
  140. $*|Stop PROCshell_WimpCloseDown_I
  141. *|Start PROCWimpCloseDown
  142. WimpCloseDown(uA%)
  143. shell_ExReg_FontMenu_Loaded
  144. shell_LoseFonts
  145. *|ifdef Using_FontMenu
  146. shell_ExReg_FontMenu_Loaded
  147. shell_FontMenu_Deregister
  148. *|endif
  149. _U%!&64
  150. "WimpExt_Initialise",&E,uA%
  151. &600DD,uA%,&4B534154
  152. _U%!&64
  153. "XImpulse_CloseDown",_U%!&94
  154. ("Unset "+_shell_AppName$+"$BasicFile")
  155. *|Stop PROCWimpCloseDown
  156. *|Start FNshell_FindFont
  157. shell_FindFont(GB$,XI%)
  158. eA%,hF%
  159. hF%=_U%!&E8
  160. &40081,,GB$,XI%*16,d*16,0,0
  161. hF%?eA%+=1
  162. hF%?eA%>=&FF
  163. shell_OK(
  164. shell_MessageNoArgs("SHELLMSG18"))
  165. *|Stop FNshell_FindFont
  166. *|Start PROCshell_Init
  167. shell_Init
  168. DB%,q%,g%,LA$
  169. D$,G$,WE%
  170. shell_InitModules
  171. shell_DefineConstants
  172. 0!_SHELL_SENDDATALOAD_MY_REF%=0
  173. 1 _SHELL_SENDDATALOAD_FILE$=""
  174. _U%360,_shell_blk%260
  175. 4#_Q%=
  176. shell_HeapBlockFetch(&BB8)
  177. 5!DB%=
  178. shell_HeapBlockFetch(48)
  179. DB%!0=0
  180. DB%!4=0
  181. DB%!8=0
  182. DB%!&C=0
  183. DB%!16=0
  184. DB%!20=0
  185. DB%!24=0
  186. DB%!28=0
  187. DB%!32=0
  188. DB%!36=0
  189. DB%!40=0
  190. DB%!44=0
  191. _U%!0=0
  192. _U%!4=0
  193. _U%!8=0
  194. _U%!&C=DB%
  195. _U%!16=1
  196. _U%!20=0
  197. _U%!44=-1
  198. _U%!48=0
  199. _U%!52=0
  200. _U%!56=0
  201. _U%!60=0
  202. _U%!64=0
  203. _U%!68=0
  204. _U%!72=0
  205. U%_U%!76=
  206. shell_HeapBlockFetch(256)
  207. _U%!80=0
  208. _U%!84=-1
  209. _U%!88=0
  210. _U%!92=0
  211. _U%!96=0
  212. _U%!&64=0
  213. _U%!&6C=-1
  214. _U%!&70=-1
  215. _U%!&74=-1
  216. _U%!&78=-1
  217. _U%!&7C=-1
  218. _U%!&80=0
  219. _U%!&84=0
  220. _U%!&88=-1
  221. _U%!&8C=-1
  222. _U%!&90=-1
  223. _U%!&94=0
  224. _U%!&98=0
  225. _U%!&9C=0
  226. _U%!&B0=0
  227. _U%!&B4=0
  228. _U%!&B8=0
  229. _U%!&BC=0
  230. _U%!&C0=0
  231. _U%!&C4=0
  232. _U%!&C8=0
  233. _U%!&CC=0
  234. _U%!&D0=-1
  235. _U%!&D4=-1
  236. _U%!&D8=0
  237. _U%!&DC=0
  238. _U%!&E0=0
  239. _U%!&E4=0
  240. &_U%!&E8=
  241. shell_HeapBlockFetch(256)
  242. &_U%!&EC=
  243. shell_HeapBlockFetch(256)
  244. _U%!&F0=-1
  245. _U%!&F4=0
  246. _U%!&FC=0
  247. _U%!256=0
  248. _U%!260=1
  249. _U%!264=0
  250. _U%!268=0
  251. _U%!272=0
  252. _U%!276=0
  253. _U%!280=0
  254. _U%!284=0
  255. _U%!304=0
  256. _U%!308=0
  257. _U%!316=0
  258. _U%!324=0
  259. _U%!336=0
  260. _U%!340=0
  261. _U%!344=0
  262. shell_MemFill(_U%!&E8,256,0)
  263. shell_MemFill(_U%!&EC,256,0)
  264. shell_OSVarGetVal("Obey$Dir",1)
  265. shell_Leaf(D$),2)
  266. *_U%!&BC=
  267. shell_HeapBlockFetch((
  268. D$)+1)
  269. *_U%!&C4=
  270. shell_HeapBlockFetch((
  271. G$)+1)
  272. g%=_U%!&BC:$g%=D$
  273. g%=_U%!&C4:$g%=G$
  274. shell_OSModuleCheckVersion("WimpExtension",1.98)
  275. _U%!&64=_U%!&64
  276. RO3_Present
  277. _U%!&64=_U%!&64
  278. 1<<&A
  279. shell_InteractiveHelpOn
  280. WE%=&64
  281. shell_PollSetInterval(WE%)
  282. shell_PollSetPrevInterval(WE%)
  283. _POLL_EARLIEST_TIME%
  284. _POLL_EARLIEST_TIME%+=WE%
  285. *|Stop PROCshell_Init
  286. !*|Start PROCshell_InitModules
  287. shell_InitModules
  288. _shell_Bumpers_Init
  289. _shell_CaretMove_Init
  290. _shell_DataLoad_Init
  291. _shell_DataSave_Init
  292. _shell_Debug_Init
  293. _shell_Errors_Init
  294. _shell_Evnts_Init
  295. _shell_ExReg_Init
  296. _shell_Files_Init
  297. _shell_Iconbar_Init
  298. _shell_Icons_Init
  299. _shell_IntHelp_Init
  300. _shell_Memory_Init
  301. _shell_Menus_Init
  302. _shell_MenuList_Init
  303. _shell_Messages_Init
  304. _shell_OS_Init
  305. _shell_Pointer_Init
  306. _shell_Poll_Init
  307. _shell_PopUps_Init
  308. _shell_ProgEvnts_Init
  309. _shell_Sliders_Init
  310. _shell_Strings_Init
  311. _shell_StaticList_Init
  312. _shell_WindowList_Init
  313. _shell_Windows_Init
  314.  *|Stop PROCshell_InitModules
  315. "*|Start FNshell_GetCmdLineArgs
  316. shell_GetCmdLineArgs
  317. _U%!324<>0
  318. LA$=$(_U%!324)
  319. shell_Tracef0("GetCmdLineArgs:cmdline was "+LA$)
  320. !*|Stop FNshell_GetCmdLineArgs
  321. *|Start FNshell_GetAppDir
  322. shell_GetAppDir
  323. g%=_U%!&BC
  324. *|Stop FNshell_GetAppDir
  325. !*|Start FNshell_GetAppDataDir
  326. shell_GetAppDataDir
  327. g%=_U%!&C0
  328.  *|Stop FNshell_GetAppDataDir
  329. *|Start FNshell_GetAppName
  330. shell_GetAppName
  331. g%=_U%!&C4
  332. *|Stop FNshell_GetAppName
  333. #*|Start PROCshell_ResourcesInit
  334. shell_ResourcesInit
  335. SA$,g%,G$,D$,KE%
  336. IC%,ND%
  337. shell_GetAppName
  338. shell_GetAppDir
  339. shell_OSVarExists(G$+"Res$Path")
  340. _U%!&64=_U%!&64
  341. shell_OSVarExists(G$+"Data$Dir")
  342. +SA$=
  343. shell_OSVarGetVal(G$+"Data$Dir",1)
  344. +_U%!&C0=
  345. shell_HeapBlockFetch((
  346. SA$)+1)
  347. g%=_U%!&C0:$g%=SA$
  348. *_U%!&C0=
  349. shell_HeapBlockFetch((
  350. D$)+1)
  351. g%=_U%!&C0:$g%=D$
  352. _U%!&64
  353. *|define Using_ResFind
  354. shell_FileExists(G$+"Res:Messages")
  355. shell_MessagesInit(G$+"Res:Messages",_U%!68,_U%!64)
  356. shell_FileExists(G$+"Res:ShellMsgs")
  357. shell_MessagesInit(G$+"Res:ShellMsgs",_U%!280,_U%!284)
  358. shell_MessagesInit("EvntShellRes:ShellMsgs",_U%!280,_U%!284)
  359. &20035,-1,4
  360. ,,ND%
  361. &20035,-1,5
  362. ,,IC%
  363. IC%=1
  364. shell_FileExists(G$+"Res:Sprites22")
  365. *4_U%!16=
  366. shell_SpriteAreaLoad(G$+"Res:Sprites22")
  367. shell_FileExists(G$+"Res:Sprites")
  368. .2_U%!16=
  369. shell_SpriteAreaLoad(G$+"Res:Sprites")
  370. _U%!16=1
  371. shell_3DEnabled
  372. shell_FileExists(G$+"Res:Templates3")
  373. shell_TemplatesInit(G$+"Res:Templates3",j%)
  374. shell_FileExists(G$+"Res:Templates")
  375. shell_TemplatesInit(G$+"Res:Templates",j%)
  376. shell_FileExists(D$+".Messages")
  377. shell_MessagesInit(D$+".Messages",_U%!68,_U%!64)
  378. shell_FileExists(D$+".ShellMsgs")
  379. shell_MessagesInit(D$+".ShellMsgs",_U%!280,_U%!284)
  380. shell_MessagesInit("EvntShellRes:ShellMsgs",_U%!280,_U%!284)
  381. &20035,-1,4
  382. ,,ND%
  383. &20035,-1,5
  384. ,,IC%
  385. IC%=1
  386. shell_FileExists(D$+".Sprites22")
  387. L1_U%!16=
  388. shell_SpriteAreaLoad(D$+".Sprites22")
  389. shell_FileExists(D$+".Sprites")
  390. O/_U%!16=
  391. shell_SpriteAreaLoad(D$+".Sprites")
  392. _U%!16=1
  393. shell_3DEnabled
  394. shell_FileExists(D$+".Templates3")
  395. shell_TemplatesInit(D$+".Templates3",j%)
  396. shell_FileExists(D$+".Templates")
  397. shell_TemplatesInit(D$+".Templates",j%)
  398. &45BC0
  399. shell_HeapBlockReturn(_Q%)
  400. b#_Q%=
  401. shell_HeapBlockFetch(&400)
  402. shell_FileExists(D$+".EvntData")
  403. shell_EvntLoad_AllEvnts(D$+".EvntData")
  404. l"*|Stop PROCshell_ResourcesInit
  405. n"*|Start FNshell_SpriteAreaLoad
  406. shell_SpriteAreaLoad(K$)
  407. lB%,S%,T%
  408. (K$):T%=
  409. #S%+16:
  410. r!lB%=
  411. shell_HeapBlockFetch(T%)
  412. !lB%=T%:lB%!4=0
  413. lB%!8=16:lB%!&C=16
  414. 46,521,lB%
  415. 46,522,lB%,K$
  416. *|ifdef TraceInit
  417. shell_Tracef0("SpriteLoad:Sprite file loaded at &"+
  418. ~lB%)
  419. *|endif
  420. |!*|Stop FNshell_SpriteAreaLoad
  421. ~#*|Start FNshell_UserSpritesBase
  422. shell_UserSpritesBase
  423. =_U%!16
  424. "*|Stop FNshell_UserSpritesBase
  425.  *|Start FNshell_SpriteGetPtr
  426. shell_SpriteGetPtr(AD%,d$)
  427. OE%,f%
  428. !OE%=
  429. shell_HeapBlockFetch(21)
  430. $OE%=d$
  431. 46,280,AD%,OE%
  432. shell_HeapBlockReturn(OE%)
  433. *|Stop FNshell_SpriteGetPtr
  434. !*|Start FNshell_MessageExpand
  435. shell_MessageExpand(n$)
  436. P$,t$,IB%
  437.     P$=""
  438. n$,"\")>0
  439. n$,"\")
  440. n$,IB%-1)
  441. n$,IB%+1,1)
  442. n$,IB%+2)
  443. "A":P$+="Click ADJUST to"
  444. "a":P$+="ADJUST"
  445. "D":P$+="Drag with SELECT to"
  446. "d":P$+="Drag with ADJUST to"
  447. "G":P$+="This option is greyed out because"
  448. "R":P$+="Move the pointer right"
  449. "S":P$+="Click SELECT to"
  450. "s":P$+="SELECT"
  451. "T":P$+="This is the"
  452. "W":P$+="This window is"
  453. "w":P$+="window"
  454. P$+="\"+t$
  455. =P$+n$
  456.  *|Stop FNshell_MessageExpand
  457. !*|Start FNshell_MessageWindow
  458. shell_MessageWindow(J$,lI%,SB$,JA$)
  459. xF%,oC%
  460. "oC%=
  461. shell_HeapBlockFetch(260)
  462. !oC%=0:$(oC%+4)=J$+
  463. JA$=""
  464. JA$="Message from "+SB$
  465. &400DF,oC%,19,JA$
  466. &400DF,oC%,17,JA$
  467. shell_HeapBlockReturn(oC%)
  468.  *|Stop FNshell_MessageWindow
  469. !*|Start FNshell_CreateWindow2
  470. shell_CreateWindow2(O,o%,TJ%,yI%,YJ%,GB%,jF%,dB%,bB%,ZF%)
  471. shell_HeapBlockFetch(&BB8)
  472. 0Q%!0=jF%:Q%!4=dB%:Q%!8=bB%:Q%!&C=ZF%:Q%!16=0
  473. %Q%!20=0:Q%!24=-1:Q%!28=o%:Q%?32=7
  474. Q%?33=2:Q%?34=TJ%:Q%?35=yI%
  475. Q%?36=3:Q%?37=1
  476. %Q%?38=2:Q%?39=0:Q%!40=0:Q%!44=GB%
  477. +Q%!48=YJ%:Q%!52=0:Q%!56=317:Q%!60=&3000
  478. .Q%!68=1:Q%!72=O:Q%!76=-1:Q%!80=
  479. $O:Q%!84=0
  480. &400C1,,Q%
  481. shell_HeapBlockReturn(Q%)
  482.  *|Stop FNshell_CreateWindow2
  483. !*|Start FNshell_ClaimKeypress
  484. shell_ClaimKeypress
  485. _U%!20<>0
  486. &400D4,,-1
  487. shell_DeleteWindow(_U%!20)
  488. _U%!20=0
  489.  *|Stop FNshell_ClaimKeypress
  490. *|Start FNoktodeletew
  491. oktodeletew(m%)
  492. *|Stop FNoktodeletew
  493. *|Start FNoktoclosew
  494. oktoclosew(m%)
  495. *|Stop FNoktoclosew
  496. *|Start PROCcliprect
  497. cliprect(A,
  498. XA%,aA%
  499. lwaorigin(A,XA%,aA%):qA%=A!24-XA%:yA%=A!28-aA%:SJ%=A!32-XA%
  500. LJ%=A!36-aA%
  501. *|Stop PROCcliprect
  502. #&*|Start PROCshell_DoBackgroundTask
  503. shell_DoBackgroundTask
  504. '%*|Stop PROCshell_DoBackgroundTask
  505. +(*|Start PROCshell_HandleAttachedMenu
  506. shell_HandleAttachedMenu(_Q%,a%,r%)
  507. r%<>-1
  508. a%>-1
  509. 3'z%=
  510. shell_GetEventMenu(_Q%!8,a%,r%)
  511. z%<>0
  512. shell_HandleMenuOpen(_Q%,z%,a%,r%,
  513. :'*|Stop PROCshell_HandleAttachedMenu
  514. *|Start PROCshell_Action
  515. shell_Action(vI%)
  516. O$,z%,s$,gB$,SH%,RB%,cB%,iF%
  517. a%,r%,j%,_temp28%,_temp32%,_temp24%,_temp%,TI%
  518. tJ%,c%,qG%
  519. _EVENT_NULL
  520. (qG%-_POLL_EARLIEST_TIME%)>0
  521. F)_POLL_EARLIEST_TIME%+=_POLL_INTERVAL%
  522. shell_ExReg_OLELib_Loaded
  523. shell_DoOLEHandling
  524. shell_DoBackgroundTask
  525. shell_SliderDragInProgress
  526. shell_Slider
  527. shell_EvntHandle_IconWatch
  528. _EVENT_REDRAWWIN
  529. shell_RedrawWindow(_Q%!0)
  530. _EVENT_OPENWIN
  531. shell_OpenWindow(_Q%!0,
  532. _EVENT_CLOSEWIN
  533. shell_CloseWindow(_Q%!0)
  534. _EVENT_PTRLEAVING
  535. shell_EvntHandle_PointerLeavingWindow(!_Q%)
  536. _EVENT_PTRENTERING
  537. shell_EvntHandle_PointerEnteringWindow(!_Q%)
  538. _EVNT_MSECLICK
  539. RB%=_Q%!0
  540. cB%=_Q%!4
  541. _U%!272=_Q%!0:_U%!276=_Q%!4
  542. e"_EVNTS_LAST_MOUSEBUTTON%=_Q%!8
  543. f%_EVNTS_LAST_WINDOWCLICKED%=_Q%!&C
  544. g#_EVNTS_LAST_ICONCLICKED%=_Q%!16
  545. shell_Tracef0("Action:Mouse_Click event detected")
  546. shell_Tracef0("Action:Window Handle was &"+
  547. ~_Q%!&C+" Icon Handle was "+
  548. _Q%!16)
  549. _Q%!8
  550. shell_EvntHandle_ClickSelect(
  551. Evnts_GetLastWindowClicked,
  552. Evnts_GetLastIconClicked)
  553. shell_EvntHandle_ClickMenu(
  554. Evnts_GetLastWindowClicked,
  555. Evnts_GetLastIconClicked)
  556. shell_EvntHandle_ClickAdjust(
  557. Evnts_GetLastWindowClicked,
  558. Evnts_GetLastIconClicked)
  559. _U%!&80=0
  560. shell_SliderDragInProgress=
  561. shell_EvntHandle_UserDragEnd
  562. shell_EvntHandle_DataSaveEndDrag
  563. shell_SliderDragEnd
  564. shell_Tracef0("Action:keypress is="+
  565. _Q%!24)
  566. _Q%!24
  567. &D,394,398,399,410,430,431
  568. 6iF%=
  569. shell_WritableIconHandler(_Q%!0,_Q%!4,_Q%!24)
  570. $iF%=
  571. shell_HotKeyProcess(_Q%!24)
  572. shell_Tracef0("Action:Keypress not claimed, passing it on")
  573. &400DC,_Q%!24
  574. shell_Tracef0("Action:Keypress claimed by this application")
  575. shell_EvntHandle_MenuSelect(_Q%)
  576. 17,18:
  577. shell_Receive(_Q%)
  578. shell_UserMessageAcknowledge(_Q%)
  579. *|Stop PROCshell_Action
  580. $*|Start PROCshell_HandleMenuOpen
  581. shell_HandleMenuOpen(_Q%,z%,a%,r%,QJ%)
  582. LA%,v%
  583. shell_OpenMenu(_Q%!0,_Q%!4,z%)
  584. !LA%=
  585. shell_HeapBlockFetch(50)
  586. shell_HeapBlockFetch(36)
  587. LA%!0=a%:LA%!4=r%
  588. &400CE,,LA%
  589. v%!0=a%
  590. &400CB,,v%
  591. shell_OpenMenu(v%!4+LA%!16+64,_Q%!4,z%)
  592. v%!4+LA%!16+64,_Q%!4
  593. shell_HeapBlockReturn(LA%)
  594. shell_HeapBlockReturn(v%)
  595. #*|Stop PROCshell_HandleMenuOpen
  596. (*|Start PROCshell_ActionAdjustButton
  597. shell_ActionAdjustButton
  598. o%,O$,j%,KD%,i%
  599. [KD%=
  600. shell_HeapBlockFetch(&C+(
  601. shell_WindowCountIcons(
  602. Evnts_GetLastWindowClicked)*32))
  603. *|ifdef TraceInit
  604. shell_Tracef0("Action:Mouse Button was ADJUST")
  605. *|endif
  606. Evnts_GetLastWindowClicked>0
  607. &400D6,
  608. Evnts_GetLastWindowClicked,KD%,&F000,&B000
  609. KD%!i%<>-1
  610. KD%!i%=
  611. Evnts_GetLastIconClicked
  612. shell_IconSet(
  613. Evnts_GetLastWindowClicked,
  614. Evnts_GetLastIconClicked,1)
  615.     i%+=4
  616. Evnts_GetLastIconClicked=0
  617. shell_HandleAttachedDataSave(_Q%,
  618. Evnts_GetLastWindowClicked,
  619. Evnts_GetLastIconClicked)
  620. shell_EvntHandle_ClickAdjust(
  621. Evnts_GetLastWindowClicked,
  622. Evnts_GetLastIconClicked)
  623. shell_HeapBlockReturn(KD%)
  624. '*|Stop PROCshell_ActionAdjustButton
  625. *|Start FNshiftmenuclick
  626. shiftmenuclick(a%,r%)
  627. *|Stop FNshiftmenuclick
  628. "*|Start PROCshell_RedrawWindow
  629. shell_RedrawWindow(m%)
  630. ZE%,O$,XA%,aA%,d%
  631. shell_HeapBlockFetch(&64)
  632. shell_FatalError
  633. d%!0=m%
  634. &400C8,,d%
  635. XA%=d%!4-d%!20
  636. aA%=d%!16-d%!24
  637. &81681,,d%
  638. shell_EvntHandle_Redraw(m%,d%,XA%,aA%)
  639. &400CA,,d%
  640. shell_HeapBlockReturn(d%)
  641. !*|Stop PROCshell_RedrawWindow
  642. *|Start PROCshell_Receive
  643. shell_Receive(_Q%)
  644. g%,j%,_G%
  645. _Q%!16
  646. _MESSAGE_QUIT
  647. shell_Exit
  648. _MESSAGE_DATASAVE
  649. shell_DataSave(_Q%)
  650. _MESSAGE_DATASAVEACK
  651. shell_DataSaveAck(_Q%)
  652. _MESSAGE_DATALOAD
  653. shell_EvntHandle_DataLoad(_Q%,
  654. _MESSAGE_DATALOADACK
  655. shell_DataLoadAck(_Q%)
  656. shell_EvntHandle_DataLoad(_Q%,
  657. _MESSAGE_RAMFETCH
  658. shell_RAMFetch(_Q%)
  659. _MESSAGE_RAMTRANSMIT
  660. shell_RAMTransmit(_Q%)
  661. _MESSAGE_PREQUIT
  662. shell_ProgEvnts_PreQuit(_Q%)
  663. _MESSAGE_PALETTECHANGE
  664. shell_ProgEvnts_PaletteChanged
  665. _MESSAGE_SAVEDESKTOP
  666. shell_ProgEvnts_SaveDesktop(_Q%!20)
  667. _MESSAGE_SHUTDOWN
  668. shell_ProgEvnts_Shutdown
  669. _MESSAGE_HELP
  670. shell_InteractiveHelp(_Q%)
  671. _MESSAGE_MENUWARNING
  672. shell_MenuWarning(_Q%)
  673. _MESSAGE_MODECHANGE
  674. shell_ProgEvnts_ModeChanged
  675. _MESSAGE_COLOURPICKERCOLOURCHOICE
  676. _G%=(_Q%!24
  677. shell_ColourPickerSelection(_Q%!28,_G%)
  678. _MESSAGE_DESKFONT_CHANGED
  679. shell_ProgEvnts_DeskFontChanged(_Q%!20)
  680. shell_ExReg_Fonts_Loaded
  681. shell_Fonts_DeskTopFont_Selected(_Q%!20)
  682. _MESSAGE_TASKINIT
  683. shell_ProgEvnts_TaskInitialise(_Q%!4,
  684. shell_GetString(_Q%+28))
  685. _U%!&D0=-1
  686. shell_GetString(_Q%+28)="StrongHelp"
  687. _U%!&D0=_Q%!4
  688. shell_StrongHlpMsg("Help_Install -DieWithTask "+
  689. shell_GetAppDir+"."+
  690. shell_GetAppName)
  691. g%=_U%!&D8
  692. $g%<>""
  693. shell_HelpWord($g%)
  694. shell_HeapBlockReturn(_U%!&D8)
  695. _U%!&D8=0
  696. _MESSAGE_TASKCLOSEDOWN
  697. shell_ProgEvnts_TaskCloseDown(_Q%!4)
  698. _Q%!4=_U%!&D0
  699. _U%!&D0=-1
  700. _MESSAGE_TASKNAMEIS
  701. shell_Tracef0("Receive:TaskNameIs message received")
  702. shell_GetString(_Q%+28)="StrongHelp"
  703. _U%!&D0=_Q%!20
  704. shell_ScanForHelp
  705. &80140
  706. shell_HandlePrintFile(_Q%)
  707. &80143
  708. shell_HandlePrintError(_Q%)
  709. &80145
  710. shell_HandlePrintTypeOdd(_Q%)
  711. &80147
  712. shell_HandleSetPrinter(_Q%)
  713. shell_HandleUnknownMessage2(_Q%)
  714. *|Stop PROCshell_Receive
  715. +*|Start PROCshell_HandleUnknownMessage2
  716. shell_HandleUnknownMessage2(_Q%)
  717. _Q%!16
  718. &43B00
  719. S$=$(_Q%+20)
  720. S$,30)="EvntShellLib:ShellDBug started"
  721. _U%!&64
  722. _U%!&64=(_U%!&64
  723. 1<<4)
  724. shell_BroadcastMessage(&43B00,"ShellDBug:Init Debug messages from "+
  725. shell_GetAppName)
  726. S$,25)="EvntShellLib:TraceInitAck"
  727. _U%!&64=(_U%!&64
  728. 1<<4)
  729. S$,20)="EvntShellLib:TraceOn"
  730. shell_TraceOn
  731. S$,21)="EvntShellLib:TraceOff"
  732. shell_TraceOff
  733. S$,28)="EvntShellLib:ListClickSelect"
  734. shell_ListClickSelect
  735. S$,26)="EvntShellLib:ListClickMenu"
  736. shell_ListClickMenu
  737. S$,28)="EvntShellLib:ListClickAdjust"
  738. shell_ListClickAdjust
  739. S$,25)="EvntShellLib:ListHelpTags"
  740. shell_ListHelpTags
  741. S$,24)="EvntShellLib:ListBumpers"
  742. shell_ListBumpers
  743. S$,26)="EvntShellLib:ListPointerIn"
  744. shell_ListPointerIn
  745. S$,27)="EvntShellLib:ListPointerOut"
  746. shell_ListPointerOut
  747. S$,25)="EvntShellLib:ListDataLoad"
  748. shell_ListDataLoad
  749. S$,25)="EvntShellLib:ListDataSave"
  750. shell_ListDataSave
  751. shell_HandleUnknownMessage(_Q%)
  752. **|Stop PROCshell_HandleUnknownMessage2
  753. **|Start PROCshell_HandleUnknownMessage
  754. shell_HandleUnknownMessage(_Q%)
  755. )*|Stop PROCshell_HandleUnknownMessage
  756. *|Start PROCshell_RAMFetch
  757. shell_RAMFetch(_Q%)
  758. wJ%,WF%,fF%
  759.     fF%=
  760. _U%!&90>&8000
  761. *|ifdef TraceInit
  762. shell_Tracef0("RAMFetch:RAMFetch called..")
  763. *|endif
  764. _Q%!&C=_Q%!8
  765. _Q%!16=7
  766. WF%=_U%!&88
  767. _U%!&8C=&FF9
  768. _U%!&90+=4
  769. (WF%-_U%!&80)<_Q%!24
  770. _Q%!24=WF%-_U%!&80
  771.     fF%=
  772. *|ifdef TraceInit
  773. shell_Tracef0("RAMFetch:Sending block")
  774. *|endif
  775. &400F1,_U%!&94,_U%!&90+_U%!&80,_Q%!4,_Q%!20,_Q%!24
  776. &400E7,17,_Q%,_Q%!4
  777. _U%!&78=_Q%!8
  778. _U%!&80+=_Q%!24
  779. _U%!&80=0
  780. *|Stop PROCshell_RAMFetch
  781. !*|Start PROCshell_RAMTransmit
  782. shell_RAMTransmit(_Q%)
  783. c%,d%,yA$,g%
  784. _Q%!&C=_U%!&70
  785. _U%!&80+=_Q%!24
  786. _Q%!24<_U%!&84
  787. *|ifdef TraceInit
  788. shell_Tracef0("RAMTransmit:Last block received")
  789. *|endif
  790. shell_GetEventListOffset(
  791. Evnts_GetLastWindowClicked,
  792. Evnts_GetLastIconClicked,_U%+96,16,
  793. d%=_U%!96+c%
  794. *|ifdef TraceInit
  795. shell_Tracef0("RAMTransmit:_U%!28="+
  796. _U%!28)
  797. shell_Tracef0("RAMTransmit:_U%!32="+
  798. _U%!32)
  799. shell_Tracef0("RAMTransmit:offset%="+
  800. *|endif
  801. g%=_U%!&9C
  802. shell_GetString(g%+44)
  803. shell_UserFNLoadFile(g%!40,_U%!&98,d%!8,yA$,_U%!&84,d%)
  804. *|ifdef TraceInit
  805. shell_Tracef0("RAMTransmit:Block received")
  806. *|endif
  807. _U%!&80>_U%!&84
  808. *|ifdef TraceInit
  809. shell_Tracef0("RAMTransmit:Increasing buffer size..")
  810. *|endif
  811. ;_U%!&98=
  812. shell_HeapBlockExtend(_U%!&98,_U%!&80,_U%!&84)
  813. _Q%!&C=_Q%!8
  814. _Q%!16=6
  815. _Q%!20=_U%!&98+_U%!&80
  816. _Q%!24=_U%!&84
  817. &400E7,18,_Q%,_Q%!4
  818. _U%!&70=_Q%!8
  819. shell_HeapBlockReturn(_U%!&98)
  820. _U%!&98=0
  821. shell_OK(
  822. shell_MessageNoArgs("SHELLMSG15"))
  823. 0 *|Stop PROCshell_RAMTransmit
  824. *|Start FNshell_LoadFile
  825. shell_LoadFile(hJ%)
  826. HA$,CC%,QE%,VB%
  827. 4 HA$=
  828. shell_GetString(_Q%+44)
  829. shell_FileLength(HA$)
  830. CC%<0
  831. shell_OK(
  832. shell_MessageNoArgs("SHELLMSG16"))
  833. 7"VB%=
  834. shell_HeapBlockFetch(CC%)
  835. &20008,16,HA$,VB%,0
  836. shell_VFlag(QE%)
  837. shell_HeapBlockReturn(VB%)
  838. *|ifdef TraceInit
  839. shell_Tracef0("LoadFile:File "+HA$+" loaded ok at &"+
  840. ~VB%)
  841. *|endif
  842. *|Stop FNshell_LoadFile
  843. *|Start FNshell_VFlag
  844. shell_VFlag(QE%)
  845. =((QE%
  846. 1)=1)
  847. *|Stop FNshell_VFlag
  848. *|Start PROCshell_Exit
  849. shell_Exit
  850. WC%=_U%!68
  851. &61504,WC%
  852. &2001E,7,,WC%
  853. *|ifdef TraceInit
  854. shell_Tracef0("Exit:Application closing down")
  855. *|endif
  856. shell_TraceExit
  857. &606C2
  858. &600D0,,-1
  859. shell_WimpCloseDown_I(_U%!&94)
  860. *|Stop PROCshell_Exit
  861. *|Start PROCshell_DataSave
  862. shell_DataSave(_Q%)
  863. g%,c%,d%,q%
  864. *|ifdef TraceInit
  865. shell_Tracef0("DataSave:DataSave message received")
  866. *|endif
  867. _Q%!4<>_U%!&94
  868. w;c%=
  869. shell_GetEventListOffset(_Q%!20,_Q%!24,_U%+96,16,
  870. c%>-1
  871. d%=_U%!96+c%
  872. shell_CheckType(_Q%!40,d%!8,
  873. *|ifdef TraceInit
  874. shell_Tracef0("DataSave:Filetype recognized (&"+
  875. ~_Q%!40+")")
  876. *|endif
  877. shell_TopBitLoadInProgress
  878. *|ifdef TraceInit
  879. shell_Tracef0("DataSave:'no load' flag set")
  880. shell_Tracef0("DataSave:Sending Message_DataSaveAck")
  881. *|endif
  882. _Q%!0=256
  883. #_Q%!&C=_Q%!8:_Q%!36=-1:_Q%!16=2
  884. .$(_Q%+44)=
  885. shell_GetAppDir+".ScrapFile"+
  886. &400E7,18,_Q%,_Q%!4
  887. shell_HeapBlockReturn(_U%!&9C)
  888. ,_U%!&9C=
  889. shell_HeapBlockFetch((_Q%!0)+8)
  890. g%=_U%!&9C
  891. _Q%!0
  892. g%!q%=_Q%!q%
  893. %_EVNTS_LAST_WINDOWCLICKED%=_Q%!20
  894. #_EVNTS_LAST_ICONCLICKED%=_Q%!24
  895. _U%!&80=0
  896. _U%!&84=_Q%!36
  897. )_U%!&98=
  898. shell_HeapBlockFetch(_Q%!36)
  899. _Q%!0=28
  900. _Q%!&C=_Q%!8
  901. _Q%!16=6
  902. _Q%!20=_U%!&98+_U%!&80
  903. _Q%!24=_U%!&84
  904. &400E7,18,_Q%,_Q%!4
  905. _U%!&70=_Q%!8
  906. *|ifdef TraceInit
  907. shell_Tracef0("DataSave:Sending Message_RAMFetch")
  908. *|endif
  909. *|ifdef TraceInit
  910. shell_Tracef0("DataSave:Filetype NOT recognized")
  911. *|endif
  912. *|Stop PROCshell_DataSave
  913. (*|Start FNshell_TopBitLoadInProgress
  914. shell_TopBitLoadInProgress
  915. _U%!&64
  916. (*|Stop  FNshell_TopBitLoadInProgress
  917. "*|Start PROCshell_SendDataSave
  918. d%,MA%,TC%,c%,CC%,j%
  919. !TC%=
  920. shell_HeapBlockFetch(30)
  921. &400CF,,TC%
  922. shell_GetEventListOffset(a%,r%,_U%+72,24,
  923. c%=-1
  924. c%=-2
  925. shell_MessageWindow(
  926. shell_MessageNoArgs("SHELLMSG13"),0,"",
  927. shell_MessageNoArgs("warning"))
  928. d%=(_U%!72)+c%
  929. d%!8>&8000
  930. $CC%=
  931. shell_HeapBlockInfo(d%!8)-4
  932. CC%=d%!8
  933. MA%=_U%!76
  934. MA%!0=256
  935. MA%!&C=0
  936. MA%!16=1
  937. MA%!20=TC%!&C
  938. MA%!24=TC%!16
  939. MA%!28=TC%!0
  940. MA%!32=TC%!4
  941. MA%!36=CC%
  942. MA%!40=d%!&C
  943. 7$(MA%+44)=
  944. shell_Leaf(
  945. shell_IconGetData(a%,d%!16))
  946. &400E7,18,MA%,MA%!20,MA%!24
  947. _U%!&78=_Q%!8
  948. _U%!&88=CC%
  949. _U%!&8C=d%!&C
  950. _U%!&90=d%!8
  951. _U%!&9C=d%!4
  952. _U%!&C8=MA%!20
  953. _U%!&CC=MA%!24
  954. shell_HeapBlockReturn(TC%)
  955. !*|Stop PROCshell_SendDataSave
  956. 4'*|Start PROCshell_DataSaveCheckName
  957. shell_DataSaveCheckName(a%,r%)
  958. c%,d%,EA%
  959. d%=_U%!72:c%=0
  960. d%<>0
  961. ="EA%=
  962. shell_HeapBlockInfo(d%)-8
  963. !(d%+c%)=a%
  964. C$d$=
  965. shell_IconGetData(!d%,d%!16)
  966. d$,".")=0
  967. shell_OK(
  968. shell_MessageNoArgs("SHELLMSG01"))
  969. c%=EA%
  970. c%+=24
  971. c%>=EA%
  972. L&*|Stop PROCshell_DataSaveCheckName
  973. N!*|Start PROCshell_DataLoadAck
  974. shell_DataLoadAck(_Q%)
  975. *|ifdef TraceInit
  976. shell_Tracef0("DataLoadAck:DataLoadAck message received (file received ok)")
  977. *|endif
  978. U *|Stop PROCshell_DataLoadAck
  979. W,*|Start PROCshell_UserMessageAcknowledge
  980. shell_UserMessageAcknowledge(_Q%)
  981. _Q%!16
  982. shell_AckDataLoad(_Q%)
  983. shell_AckRAMFetch(_Q%)
  984. _Q%!8=_SHELL_SENDDATALOAD_MY_REF%
  985. RO3_Present
  986. ("Filer_Run "+_SHELL_SENDDATALOAD_FILE$)
  987. ("Run "+_SHELL_SENDDATALOAD_FILE$)
  988. h+*|Stop PROCshell_UserMessageAcknowledge
  989. l!*|Start PROCshell_AckRAMFetch
  990. shell_AckRAMFetch(_Q%)
  991. eG%,g%
  992. g%=_U%!&9C
  993. *|ifdef TraceInit
  994. shell_Tracef0("AckRAMFetch:AckRAMFetch called....")
  995. *|endif
  996. _Q%!&C<>_U%!&70
  997. _U%!&80=0
  998. *|ifdef TraceInit
  999. shell_Tracef0("AckRAMFetch:Receiver does not support RAM transfer")
  1000. *|endif
  1001. &20023,"Wimp$Scrap",,-1,0,3
  1002. ,,eG%
  1003. eG%<>0
  1004. } $(g%+44)="<Wimp$Scrap>"+
  1005. ~+g%!0=(49+
  1006. shell_GetString(g%+44)))
  1007. g%!&C=g%!8
  1008. g%!16=2
  1009. g%!36=-1
  1010. &400E7,18,g%,g%!4
  1011. _U%!&6C=g%!8
  1012. shell_OK(
  1013. shell_MessageNoArgs("SHELLMSG14"))
  1014. *|ifdef TraceInit
  1015. shell_Tracef0("AckRAMFetch:RAM transfer started, but not enough data sent. Sender died?")
  1016. *|endif
  1017. shell_HeapBlockReturn(_U%!&98)
  1018. _U%!&98=0
  1019. shell_OK("SHELLMSG06")
  1020.  *|Stop PROCshell_AckRAMFetch
  1021. '*|Start PROCshell_FindMenuWarnEvent
  1022. shell_FindMenuWarnEvent(PA%,
  1023. t%,hA%,g%,c%,w%,EA%,nA%,i%
  1024.     cC%=0
  1025. %hA%=_U%!&DC:c%=0:w%=
  1026. :L$="":cC%=0
  1027. shell_HeapBlockExists(hA%)
  1028.     i%+=4
  1029. hA%!i%=-1
  1030. EA%=i%:i%=0
  1031. *|ifdef PROCshell_TraceInit
  1032. shell_Tracef0("FindMenuWarnEvent:list_size%="+
  1033. *|endif
  1034. g%=!(hA%+c%+0)
  1035. g%<>-1
  1036. g%=PA%
  1037. nA%=hA%!(c%+4):L$=$nA%
  1038. cC%=hA%!(c%+8)
  1039. nA%=hA%!(c%+&C):T$=$nA%
  1040. *|ifdef PROCshell_TraceInit
  1041. shell_Tracef0("FindMenuWarnEvent:submenu found")
  1042. *|endif
  1043. c%+=16
  1044. c%=EA%
  1045. c%>=EA%
  1046. L$="":T$=""
  1047. *|ifdef PROCshell_TraceInit
  1048. cC%=0
  1049. shell_Tracef0("FindMenuWarnEvent:warn fn not found..")
  1050. *|endif
  1051. &*|Stop PROCshell_FindMenuWarnEvent
  1052. '*|Start PROCshell_EventListMenuWarn
  1053. shell_EventListMenuWarn(UC%,OI%,L$,T$)
  1054. g%,nA%,i%,hA%
  1055. _U%!&DC=0
  1056. %_U%!&DC=
  1057. shell_HeapBlockFetch(32)
  1058. g%=_U%!&DC
  1059. g%!0=UC%
  1060. %g%!4=
  1061. shell_HeapBlockFetch(
  1062. L$+1)
  1063. $(g%!4)=L$
  1064. g%!8=OI%
  1065. &g%!&C=
  1066. shell_HeapBlockFetch(
  1067. T$+1)
  1068. $(g%!&C)=T$
  1069. 'g%!16=-1:g%!20=-1:g%!24=-1:g%!28=-1
  1070. *hA%=
  1071. shell_HeapBlockExtend(_U%!&DC,32)
  1072. _U%!&DC=hA%:i%=0
  1073. i%+=16
  1074. hA%!i%=-1
  1075. g%=_U%!&DC
  1076. g%!i%=UC%
  1077. *g%!(i%+4)=
  1078. shell_HeapBlockFetch(
  1079. L$+1)
  1080. nA%=g%!(i%+4):$(nA%)=L$
  1081. g%!(i%+8)=OI%
  1082. +g%!(i%+&C)=
  1083. shell_HeapBlockFetch(
  1084. T$+1)
  1085. nA%=g%!(i%+&C):$(nA%)=T$
  1086. -g%!(i%+16)=-1:g%!(i%+20)=-1:g%!(i%+24)=-1
  1087. g%!(i%+28)=-1
  1088. &*|Stop PROCshell_EventListMenuWarn
  1089. *|Start PROCack
  1090. *|Stop PROCack
  1091. *|Start PROClwaorigin
  1092. lwaorigin(A,
  1093. SA%=A!0-A!16:TA%=A!&C-A!20
  1094. *|Stop PROClwaorigin
  1095. '*|Start FNshell_WritableIconHandler
  1096. shell_WritableIconHandler(a%,r%,fA%)
  1097. MB%,rB%,uB%,i%
  1098. FE%,fE%,IB%,RB%,cB%,DK%,AA%
  1099. #AA%=
  1100. shell_HeapBlockFetch(&400)
  1101. &400D3,,AA%
  1102. !AA%=-1
  1103. shell_HeapBlockReturn(AA%)
  1104. &400D6,a%,AA%,&40E000,&E000
  1105. rB%=!AA%:i%=0
  1106. AA%!i%=r%
  1107. FE%=AA%!(i%-4)
  1108. fE%=AA%!(i%+4)
  1109.     i%+=4
  1110. AA%!i%=-1
  1111. uB%=AA%!(i%-4)
  1112. shell_FakeMouseClick(a%,0,4)
  1113. 398,394
  1114. r%=uB%
  1115. &400D2,a%,rB%,-1,-1,-1,
  1116. shell_IconGetData(a%,rB%))
  1117. shell_IconEnsureVisible(a%,rB%)
  1118. &400D2,a%,fE%,-1,-1,-1,
  1119. shell_IconGetData(a%,fE%))
  1120. shell_IconEnsureVisible(a%,fE%)
  1121. 399,410
  1122. r%=rB%
  1123. &400D2,a%,uB%,-1,-1,-1,
  1124. shell_IconGetData(a%,uB%))
  1125. shell_IconEnsureVisible(a%,uB%)
  1126. &400D2,a%,FE%,-1,-1,-1,
  1127. shell_IconGetData(a%,FE%))
  1128. shell_IconEnsureVisible(a%,FE%)
  1129. &400D2,a%,rB%,-1,-1,-1,
  1130. shell_IconGetData(a%,rB%))
  1131. shell_IconEnsureVisible(a%,rB%)
  1132. &400D2,a%,uB%,-1,-1,-1,
  1133. shell_IconGetData(a%,uB%))
  1134. shell_IconEnsureVisible(a%,uB%)
  1135. shell_HeapBlockReturn(AA%)
  1136. 0&*|Stop FNshell_WritableIconHandler
  1137. 2$*|Start PROCshell_FakeMouseClick
  1138. shell_FakeMouseClick(a%,r%,HD%)
  1139. 6,&F,1
  1140. 5!_Q%!8=HD%:_Q%!&C=a%:_Q%!16=r%
  1141. shell_Action(6)
  1142. 9#*|Stop PROCshell_FakeMouseClick
  1143. *|Start PROCshell_GetMinXY
  1144. shell_GetMinXY(o%,J$,p$)
  1145. XA%,aA%,qA%,yA%,RB%,cB%
  1146. TB%=0:GB%=0
  1147. J$<>""
  1148. &40084,o%>>24
  1149. ,,aA%,,yA%
  1150. &40097,,
  1151. (o%>>24)+J$
  1152. ,XA%,,qA%
  1153. &40088,,XA%
  1154. &40088,,qA%
  1155. TB%=qA%-XA%:GB%=yA%-aA%
  1156. TB%=6*jJ%+16*
  1157. J$:GB%=32
  1158. 4GB%+=2*rJ%
  1159. p$<>""
  1160. &2002E,296,
  1161. shell_UserSpritesBase,p$
  1162. ,,,RB%,cB%,,aH%;P%
  1163. &20035,aH%,4
  1164. ,,_I%:RB%=RB%<<_I%
  1165. &20035,aH%,5
  1166. ,,NJ%:cB%=cB%<<NJ%
  1167. &800RB%=RB%/2:cB%=cB%/2
  1168. 539)=19RB%=TB%+RB%
  1169. RB%>TB%TB%=RB%
  1170. cB%>GB%GB%=cB%
  1171. *|Stop PROCshell_GetMinXY
  1172. ]"*|Start PROCshell_IconGetState
  1173. shell_IconGetState(dC%,LC%)
  1174. !_Q%=dC%
  1175. _Q%!4=LC%
  1176. &400CE,,_Q%
  1177. d!*|Stop PROCshell_IconGetState
  1178. *|Start PROCprint_text
  1179. print_text(K,J,J$)
  1180. in(K,J-32,K+16*
  1181. (J$),J)
  1182. *|Stop PROCprint_text
  1183. *|Start FNin
  1184. in(A%,B%,C%,D%)
  1185. *|Stop FNin
  1186. *|Start PROCnewvals
  1187. newvals
  1188. X=_Q%!28:b=_Q%!32
  1189. Q=_Q%!36:a=_Q%!40
  1190. T=_Q%!4:V=_Q%!8
  1191. W=_Q%!&C:S=_Q%!16
  1192. M=_Q%!20:N=_Q%!24
  1193. c=W-T:R=S-V:e=M
  1194. f=M+c:g=N:h=N-R
  1195. *|Stop PROCnewvals
  1196. max(iA%,dB%)
  1197. iA%<dB%
  1198. *|Start FNshell_Leaf
  1199. shell_Leaf(I$)
  1200. I$,".")
  1201. I$,".")+1)
  1202. *|Stop FNshell_Leaf
  1203. *|Start FNshell_Branch
  1204. shell_Branch(bA$)
  1205. NA%,QA$,g%
  1206. bA$,".")=0
  1207. QA$=""
  1208. NA%=g%+1
  1209. bA$,".",NA%)
  1210. bA$,NA%-2)
  1211. *|Stop FNshell_Branch
  1212. *|Start FNgname
  1213. gname(G)
  1214. eA$=""
  1215. ?G<>0
  1216. ?G<>&D
  1217. eA$=eA$+
  1218. ?G:G+=1
  1219. *|Stop FNgname
  1220. **|Start PROCshell_ScreenToWindowCoords
  1221. shell_ScreenToWindowCoords(bH%,
  1222. VF%,XH%,mJ%,IH%,pG%,SC%
  1223. DSC%=
  1224. shell_HeapBlockFetch(&64+(
  1225. shell_WindowCountIcons(bH%)*32))
  1226. VF%=SC%
  1227. !VF%=bH%
  1228. &400CC,,VF%
  1229. XH%=SC%!4
  1230. VJ%=SC%!16
  1231. IH%=SC%!20
  1232. pG%=SC%!24
  1233. X%=X%+(IH%-XH%)
  1234. Y%=Y%+(pG%-VJ%)
  1235. shell_HeapBlockReturn(SC%)
  1236. )*|Stop PROCshell_ScreenToWindowCoords
  1237. #*|Start FNshell_WimpSlotReadEnd
  1238. shell_WimpSlotReadEnd
  1239. &400EC,-1,-1
  1240. "*|Stop FNshell_WimpSlotReadEnd
  1241. '*|Start FNshell_WimpSlotClaimMemory
  1242. shell_WimpSlotClaimMemory(yC%,NB%)
  1243. &400EC,yC%+NB%,-1
  1244. JG%<yC%+NB%
  1245. &*|Stop FNshell_WimpSlotClaimMemory
  1246. +*|Start PROCshell_WimpSlotReleaseMemory
  1247. shell_WimpSlotReleaseMemory
  1248. &400EC,yC%,-1
  1249. **|Stop PROCshell_WimpSlotReleaseMemory
  1250.  *|Start PROCshell_MouseLimit
  1251. shell_MouseLimit(A,QA%)
  1252. A!0=QA%:
  1253. &400CB,,A
  1254. mouse_rectangle(A!4,A!8,A!&C-A!4,A!16-A!8)
  1255. *|Stop PROCshell_MouseLimit
  1256. %*|Start FNshell_NameOfFirstSprite
  1257. shell_NameOfFirstSprite(FB$)
  1258. X%,N%,hA$
  1259. (FB$)
  1260. #X%=4
  1261. #X%*256
  1262. #X%*65536
  1263. #X%*&1000000
  1264. #X%=N%
  1265. hA$=""
  1266. hA$+=
  1267. $*|Stop FNshell_NameOfFirstSprite
  1268. $*|Start PROCInitialiseSpriteArea
  1269. InitialiseSpriteArea(S%,fI%)
  1270. !S%=fI%
  1271. S%!8=16
  1272. 46,9+256,S%
  1273. #*|Stop PROCInitialiseSpriteArea
  1274.  *|Start PROCshell_ListEvents
  1275. shell_ListEvents(a%,lA%)
  1276. z%,s$
  1277. a%=-1
  1278. a%=-2
  1279. shell_Tracef0("MenuSelection="+
  1280. shell_GetEventHandler(a%,lA%,0))
  1281. shell_Tracef0("MenuMaker    ="+
  1282. shell_GetEventHandler(a%,lA%,1))
  1283. shell_Tracef0("ClickSelect  ="+
  1284. shell_GetEventHandler(a%,lA%,2))
  1285. shell_Tracef0("ClickAdjust  ="+
  1286. shell_GetEventHandler(a%,lA%,3))
  1287. shell_Tracef0("Redraw       ="+
  1288. shell_GetEventHandler(a%,lA%,4))
  1289. shell_Tracef0("Keypress     ="+
  1290. shell_GetEventHandler(a%,lA%,5))
  1291. shell_Tracef0("Drag         ="+
  1292. shell_GetEventHandler(a%,lA%,6))
  1293. shell_Tracef0("Menu Warning ="+
  1294. shell_GetEventHandler(a%,lA%,7))
  1295. shell_Tracef0("HelpTag      ="+
  1296. shell_GetEventHandler(a%,lA%,8))
  1297. shell_GetEventMenu(2,a%,lA%)
  1298. s$="None"
  1299. shell_Tracef0("Menu handle =&"+s$)
  1300. *|Stop PROCshell_ListEvents
  1301. "*|Start PROCshell_AttachHotKey
  1302. shell_AttachHotKey(qA$,fC%,hC%,FD%,o$,a%,e$,f$)
  1303. hA%,c%,g%,nA%,fA%,aF%
  1304.     aF%=
  1305. _U%!60=0
  1306. $_U%!60=
  1307. shell_HeapBlockFetch(24)
  1308. c%=0:_U%!&B4=1
  1309. c%=_U%!&B4*24
  1310. ,_U%!60=
  1311. shell_HeapBlockExtend(_U%!60,24)
  1312. _U%!&B4=(_U%!&B4)+1
  1313. hA%=_U%!60
  1314. "F1":fA%=385
  1315. "F2":fA%=386
  1316. "F3":fA%=387
  1317. "F4":fA%=388
  1318. "F5":fA%=389
  1319. "F6":fA%=390
  1320. "F7":fA%=391
  1321. "F8":fA%=392
  1322. "F9":fA%=393
  1323. "F10":fA%=458
  1324. "F11":fA%=459
  1325. fA%=(
  1326. qA$)-64:aF%=
  1327. fA%+=16
  1328. fA%+=32
  1329. g%=hA%+c%
  1330. g%!0=fA%
  1331. g%?4=fC%
  1332. g%?5=hC%
  1333. g%?6=FD%
  1334. 5%g%!8=
  1335. shell_HeapBlockFetch(
  1336. o$+1)
  1337. nA%=g%!8:$nA%=o$
  1338. shell_IsWindowStatic(a%)=
  1339. shell_MessageNoArgs("SHELLMSG09")
  1340. g%!&C=a%
  1341. <&g%!16=
  1342. shell_HeapBlockFetch(
  1343. e$+1)
  1344. nA%=g%!16:$nA%=e$
  1345. >&g%!20=
  1346. shell_HeapBlockFetch(
  1347. f$+1)
  1348. nA%=g%!20:$nA%=f$
  1349. B!*|Stop PROCshell_AttachHotKey
  1350. D!*|Start FNshell_HotKeyProcess
  1351. shell_HotKeyProcess(fA%)
  1352. hA%,EA%,w%,f%,y%,BA$,e$,f$
  1353. hC%,fC%,FD%,BB%,CB%,yD%,qJ%,c%
  1354. t%,_%
  1355. hA%=_U%!60
  1356. EA%=_U%!&B4*24
  1357. :f%=0
  1358. hA%!f%=fA%
  1359. f%+=24
  1360. f%>=EA%
  1361. g%=hA%+f%
  1362. BA$=$(g%!8)
  1363. *|ifdef TraceInit
  1364. shell_Tracef0("HotKeyProcess:Template name is '"+BA$+"'")
  1365. *|endif
  1366. (BA$<>""
  1367. g%!&C=0)
  1368. shell_CreateWindow(BA$,y%)
  1369. *|ifdef TraceInit
  1370. shell_Tracef0("HotKeyProcess:Creating new dynamic window (handle is &"+
  1371. ~y%+")")
  1372. *|endif
  1373. ` _%=
  1374. shell_HeapBlockFetch(36)
  1375. _%!0=y%
  1376. &400CB,,_%
  1377. BB%=(_%!4-_%!&C)/2
  1378. CB%=(_%!16-_%!8)/2
  1379. shell_HeapBlockReturn(_%)
  1380. e$=$(g%!16)
  1381. e$<>""
  1382. shell_Tracef0("HotKeyProcess:Calling Pre-Open FN '"+e$+"'")
  1383. g%!&C>0
  1384. k j%=
  1385. ("FN"+e$+"("+
  1386. g%!&C+")")
  1387. ("FN"+e$+"("+
  1388. y%+")")
  1389. shell_Tracef0("HotKeyProcess:No Pre-Open FN registered")
  1390. shell_IsWindowStatic(g%!&C)
  1391. shell_OpenWindowStatic(g%!&C)
  1392. g%!&C>0
  1393. shell_MessageNoArgs("SHELLMSG09")
  1394. shell_OpenWindowDynamic2(y%,BB%,CB%)
  1395. f$=$(g%!20)
  1396. f$<>""
  1397. *|ifdef TraceInit
  1398. shell_Tracef0("HotKeyProcess:Calling Post-Open FN '"+f$+"'")
  1399. *|endif
  1400. g%!&C>0
  1401. ("FN"+f$+"("+
  1402. g%!&C+")")
  1403. ("FN"+f$+"("+
  1404. y%+")")
  1405. *|ifdef TraceInit
  1406. shell_Tracef0("HotKeyProcess:No Post-Open FN registered")
  1407. *|endif
  1408. BA$="":e$="":f$="":t%=
  1409.  *|Stop FNshell_HotKeyProcess
  1410. +*|Start PROCshell_WindowCentreOnPointer
  1411. shell_WindowCentreOnPointer(y%)
  1412. v%,ED%,BB%,CB%
  1413. !ED%=
  1414. shell_HeapBlockFetch(20)
  1415. &400CF,,ED%
  1416. shell_HeapBlockFetch(36)
  1417. _%!0=y%
  1418. &400CB,,_%
  1419. BB%=(_%!4-_%!&C)/2
  1420. CB%=(_%!16-_%!8)/2
  1421. shell_WindowMoveTo(y%,ED%!0+BB%,ED%!4-CB%)
  1422. shell_HeapBlockReturn(_%)
  1423. shell_HeapBlockReturn(ED%)
  1424. **|Stop PROCshell_WindowCentreOnPointer
  1425. **|Start PROCshell_WindowCentreOnScreen
  1426. shell_WindowCentreOnScreen(y%)
  1427. v%,UE%,VE%,HB%,oA%,ND%,IC%
  1428. &20035,-1,4
  1429. ,,ND%
  1430. &20035,-1,5
  1431. ,,IC%
  1432. &20035,-1,&B
  1433. ,,UE%
  1434. &20035,-1,&C
  1435. ,,VE%
  1436. UE%=UE%<<ND%
  1437. VE%=VE%<<IC%
  1438. shell_HeapBlockFetch(36)
  1439. _%!0=y%
  1440. &400CB,,_%
  1441. HB%=(_%!&C-_%!4)
  1442. oA%=(_%!16-_%!8)
  1443. shell_WindowMoveTo(y%,(UE%/2)-(HB%/2),(VE%-oA%)/2)
  1444. shell_HeapBlockReturn(_%)
  1445. )*|Stop PROCshell_WindowCentreOnScreen
  1446. -*|Start PROCshell_OpenWindowStaticNewView
  1447. shell_OpenWindowStaticNewView(a%)
  1448. shell_OpenWindow(a%,
  1449. ,*|Stop PROCshell_OpenWindowStaticNewView
  1450. &*|Start PROCshell_OpenWindowStatic
  1451. shell_OpenWindowStatic(m%)
  1452. shell_IsWindowStatic(m%)=
  1453. shell_OpenWindow(m%,0,-1)
  1454. %*|Stop PROCshell_OpenWindowStatic
  1455. $*|Start PROCshell_InitHelpSystem
  1456. shell_InitHelpSystem(I$,uI%)
  1457. OA$,NA%,j$,qE%,sB%
  1458. 9_U%!&D4=0:
  1459. _U%!&D8<>0
  1460. shell_HeapBlockReturn(_U%!&D8)
  1461. _U%!&D8=0
  1462. shell_ScanForHelp
  1463. OA$=" -DieWithTask"
  1464. OA$=""
  1465. _U%!&64
  1466.     I$=""
  1467. shell_OSVarGetVal(
  1468. shell_GetAppName+"Res$Path",-1)
  1469. j$,",")
  1470. NA%>0
  1471. shell_FileExists(
  1472. j$,NA%-1)+
  1473. shell_GetAppName)
  1474. j$,NA%-1)+
  1475. shell_GetAppName
  1476. shell_StrongHlpChkFiles(I$)
  1477. j$,NA%+1)
  1478. shell_FileExists(j$+
  1479. shell_GetAppName)
  1480. I$=j$+
  1481. shell_GetAppName
  1482. shell_StrongHlpChkFiles(I$)
  1483.     sB%=
  1484. shell_OK(
  1485. shell_MessageOneArg("SHELLMSG26",
  1486. shell_GetAppName))
  1487. I$<>""
  1488. shell_FileExists(I$)
  1489. shell_StrongHlpChkFiles(I$)
  1490. shell_MessageOneArg("SHELLMSG33",I$)
  1491. sB%=0
  1492. shell_StrongHlpMsg("Help_Install "+I$+OA$)
  1493. _U%!&64=_U%!&64
  1494. #*|Stop PROCshell_InitHelpSystem
  1495. *|Start PROCshell_HelpWord
  1496. shell_HelpWord(MA$)
  1497. FK%,g%
  1498. _U%!&D0=-1
  1499. shell_OSVarExists("StrongHelp$Dir")
  1500. &600DE,"<StrongHelp$Dir>"
  1501. _U%!&D8<>0
  1502. shell_HeapBlockReturn(_U%!&D8)
  1503. )_U%!&D8=
  1504. shell_HeapBlockFetch(
  1505. MA$+1)
  1506. g%=_U%!&D8
  1507. $g%=MA$
  1508. shell_OK(
  1509. shell_MessageNoArgs("SHELLMSG11"))
  1510. shell_StrongHlpMsg("Help_Word "+MA$)
  1511. *|Stop PROCshell_HelpWord
  1512. "*|Start PROCshell_StrongHlpMsg
  1513. shell_StrongHlpMsg(FA$)
  1514. shell_BroadcastMessage(&43B00,FA$)
  1515. !*|Stop PROCshell_StrongHlpMsg
  1516. !*|Start PROCshell_ScanForHelp
  1517. shell_ScanForHelp
  1518. iB%,XE%
  1519. "iB%=
  1520. shell_HeapBlockFetch(256)
  1521. iB%!&C=0
  1522. &400E7,19,iB%,-2,_U%!&D4
  1523. ,,XE%
  1524. _U%!&D4=_U%!&D4+1
  1525. XE%<>-1
  1526. (_U%!&D4)>64
  1527. XE%<>-1
  1528. iB%!0=24
  1529. iB%!&C=0
  1530. iB%!16=&400C6
  1531. iB%!20=XE%
  1532. &400E7,17,iB%,0
  1533. shell_HeapBlockReturn(iB%)
  1534.     9 *|Stop PROCshell_ScanForHelp
  1535. *|Start PROCshell_MemFill
  1536. shell_MemFill(jD%,yH%,ID%)
  1537. I%,cE%,vE%
  1538. cE%=yH%
  1539. vE%=yH%
  1540. cE%>0
  1541. (cE%*4)
  1542. jD%!(I%-1)=ID%
  1543. vE%>0
  1544. jD%=jD%+(cE%*4)
  1545. vE%-1
  1546. jD%?I%=ID%
  1547. *|Stop PROCshell_MemFill
  1548.     `&*|Start PROCshell_MenuUpdateHandle
  1549. shell_MenuUpdateHandle(rG%,DI%)
  1550. EA%,f%,n%,z%
  1551.     c&EA%=
  1552. shell_HeapBlockInfo(_U%!&C)-8
  1553. n%=_U%!&C
  1554. z%=n%!(f%+8)
  1555. z%=rG%
  1556. n%!(f%+8)=DI%
  1557. f%+=48
  1558. (f%>=EA%)
  1559. shell_MenuLastHandle=rG%
  1560. _m_Menu_HandleLastOpened%=DI%
  1561.     n%*|Stop PROCshell_MenuUpdateHandle
  1562.     r"*|Start FNshell_CheckSelection
  1563. shell_CheckSelection(aI%)
  1564. g%,i%
  1565. g%=_U%!256
  1566. shell_MenuLastHandle=_U%!&FC
  1567. aI%!i%<>g%!i%
  1568.     z    i%+=4
  1569. g%!i%=-1
  1570.     ~!*|Stop FNshell_CheckSelection
  1571. &*|Start FNshell_MenuGetItemAddress
  1572. shell_MenuGetItemAddress(z%,mG%)
  1573. i%,GC%
  1574. &45BC7,z%
  1575. GC%=z%+28+((mG%!i%)*24)
  1576. z%=GC%!4
  1577.     i%+=4
  1578. mG%!i%=-1
  1579. %*|Stop FNshell_MenuGetItemAddress
  1580. $*|Start FNshell_GetLastMouseXPos
  1581. shell_GetLastMouseXPos
  1582. Evnts_GetLastMouseXPos
  1583. #*|Stop FNshell_GetLastMouseXPos
  1584. $*|Start FNshell_GetLastMouseYPos
  1585. shell_GetLastMouseYPos
  1586. Evnts_GetLastMouseYPos
  1587. #*|Stop FNshell_GetLastMouseYPos
  1588. (*|Start PROCshell_UpdateWindowHandle
  1589. shell_UpdateWindowHandle(jA%,ZA%)
  1590. *|ifdef TraceInit
  1591. shell_Tracef0("UpdateWindowHandle:Updating stored window handles")
  1592. shell_Tracef0("UpdateWindowHandle:old handle=&"+
  1593. ~jA%)
  1594. shell_Tracef0("UpdateWindowHandle:new handle=&"+
  1595. ~ZA%)
  1596. *|endif
  1597. ZA%<>jA%
  1598. Evnts_GetLastWindowClicked=jA%
  1599. _EVNTS_LAST_WINDOWCLICKED%=ZA%
  1600. !_Q%=jA%
  1601. !_Q%=ZA%
  1602. shell_FixEventBlock(jA%,ZA%,_U%!&C,48)
  1603. shell_FixEventBlock(jA%,ZA%,_U%!96,16)
  1604. shell_FixEventBlock(jA%,ZA%,_U%!72,24)
  1605. shell_FixEventBlock(jA%,ZA%,_U%!92,24)
  1606. shell_UpdateStaticWindowHandle(jA%,ZA%)
  1607. shell_UpdateWindowHandleList(jA%,ZA%)
  1608. '*|Stop PROCshell_UpdateWindowHandle
  1609. #*|Start PROCshell_FixEventBlock
  1610. shell_FixEventBlock(jA%,ZA%,n%,c%)
  1611. f%,EA%
  1612. shell_HeapBlockExists(n%)
  1613. "EA%=
  1614. shell_HeapBlockInfo(n%)-8
  1615. (n%!f%=jA%)
  1616. n%!f%=ZA%
  1617. f%+=c%
  1618. (f%>=EA%)
  1619. "*|Stop PROCshell_FixEventBlock
  1620. $*|Start PROCshell_FixEventBlock2
  1621. shell_FixEventBlock2(jA%,ZA%,n%,c%)
  1622. f%,EA%
  1623. shell_HeapBlockExists(n%)
  1624. EA%=!n%
  1625. (n%!f%=jA%)
  1626. n%!f%=ZA%
  1627. f%+=c%
  1628. (f%>=EA%)
  1629. #*|Stop PROCshell_FixEventBlock2
  1630. "*|Start PROCshell_MessagesInit
  1631. shell_MessagesInit(K$,
  1632. NB%,o%
  1633. 3,"Cannot open message file '"+K$+"'"
  1634. &41500,,K$
  1635. o%,,NB%
  1636. bG%=0
  1637. shell_HeapBlockFetch(NB%)
  1638. 30,6,,,17+
  1639. ,,CE%
  1640. $(CE%+16)=K$
  1641. &41501,CE%,CE%+16
  1642. *|ifdef TraceInit
  1643. shell_Tracef0("MessagesInit:Message resource file '"+K$+"' loaded")
  1644. *|endif
  1645. !*|Stop PROCshell_MessagesInit
  1646. '*|Start FNshell_WindowSetSpriteArea
  1647. shell_WindowSetSpriteArea(y%,tE%)
  1648. d%,ZA%,uE%,CF%
  1649. shell_HeapBlockFetch(&64+(
  1650. shell_WindowCountIcons(y%)*32))
  1651. !d%=y%
  1652. &400CC,,d%
  1653. d%!68=tE%
  1654. shell_IconSetSpriteArea(d%!60,d%+76,tE%)
  1655. (d%!88)>0
  1656. uE%=0
  1657. (d%!88)-1
  1658. CF%=d%+92+uE%*32
  1659. shell_IconSetSpriteArea(CF%!16,CF%+20,tE%)
  1660. &400C3,,d%
  1661. &400C1,,d%+4
  1662. ZA%<>y%
  1663. shell_UpdateWindowHandle(y%,ZA%)
  1664. y%=ZA%
  1665. shell_HeapBlockReturn(d%)
  1666. &*|Stop FNshell_WindowSetSpriteArea
  1667. (*|Start FNshell_StrongHlpIsAvailable
  1668. shell_StrongHlpIsAvailable
  1669. bB%,UA%
  1670.     bB%=
  1671. _U%!&64
  1672.     ,bB%=
  1673. shell_OSVarExists("StrongHelp$Dir")
  1674. '*|Stop FNshell_StrongHlpIsAvailable
  1675. &*|Start PROCshell_AttachOpenWindow
  1676. shell_AttachOpenWindow(a%,O$)
  1677. d%,g%,c%
  1678. *|ifdef TraceInit
  1679. shell_Tracef0("AttachOpenWindow:Attaching OpenWindow Handler")
  1680. *|endif
  1681. shell_MessageOneArg("SHELLMSG27","AttachOpenWindow")
  1682. shell_GetEventListOffset(a%,-1,_U%+304,&C,
  1683. d%=_U%!304+c%
  1684. d%!0=a%:d%!4=-1
  1685. 'd%!8=
  1686. shell_HeapBlockFetch(
  1687. (O$)+1)
  1688. g%=d%!8:$g%=O$
  1689. %*|Stop PROCshell_AttachOpenWindow
  1690. !.*|Start PROCshell_AttachCloseWindowHandler
  1691. shell_AttachCloseWindowHandler(a%,O$)
  1692. d%,g%,c%
  1693. *|ifdef TraceInit
  1694. shell_Tracef0("AttachCloseWindowHandler:Attaching CloseWindow Handler")
  1695. *|endif
  1696. shell_MessageOneArg("SHELLMSG27","AttachCloseWindow")
  1697. (4c%=
  1698. shell_GetEventListOffset(a%,-1,_U%+308,&C,
  1699. d%=_U%!308+c%
  1700. d%!0=a%:d%!4=-1
  1701. +'d%!8=
  1702. shell_HeapBlockFetch(
  1703. (O$)+1)
  1704. g%=d%!8:$g%=O$
  1705. /-*|Stop PROCshell_AttachCloseWindowHandler
  1706. 1"*|Start PROCshell_SpriteRename
  1707. shell_SpriteRename(AD%,VB$,NB$)
  1708. 46,512+26,AD%,
  1709. shell_SpriteGetPtr(AD%,VB$),NB$
  1710. 6!*|Stop PROCshell_SpriteRename
  1711. 8$*|Start PROCshell_SpriteAreaSave
  1712. shell_SpriteAreaSave(AD%,K$)
  1713. 46,512+&C,AD%,K$
  1714. =#*|Stop PROCshell_SpriteAreaSave
  1715. ? *|Start PROCshell_EnsurePoll
  1716. shell_EnsurePoll
  1717. C DA%=
  1718. shell_Poll_I(0,_U%!&94)
  1719. shell_Action(DA%)
  1720. DA%=0
  1721. *|Stop PROCshell_EnsurePoll
  1722. J"*|Start FNshell_WimpGetVersion
  1723. shell_WimpGetVersion
  1724. =_U%!316
  1725. M!*|Stop FNshell_WimpGetVersion
  1726. S)*|Start PROCshell_MessageSendDataLoad
  1727. shell_MessageSendDataLoad(pA%,d$)
  1728. V"EB%=
  1729. shell_HeapBlockFetch(256)
  1730. EB%!0=256
  1731. EB%!4=0
  1732. EB%!&C=0
  1733. EB%!16=5
  1734. EB%!20=0
  1735. EB%!28=0
  1736. EB%!32=0
  1737. EB%!36=0
  1738. EB%!40=pA%
  1739. $(EB%+44)=d$+
  1740. &400E7,18,EB%,0
  1741. d%_SHELL_SENDDATALOAD_MY_REF%=EB%!8
  1742. e _SHELL_SENDDATALOAD_FILE$=d$
  1743. shell_HeapBlockReturn(EB%)
  1744. i(*|Stop PROCshell_MessageSendDataLoad
  1745. m *|Start FNshell_BinarySearch
  1746. shell_BinarySearch(_search_term$,IB$,m$,FH%,bE%)
  1747. _pos%,HC%,_wp$,mE%,gJ%,BG%,RD%,PH%,w%,BF%
  1748. bE%+=1
  1749. s    BF%=
  1750. HC%=bE%
  1751. v    mE%=0
  1752. _pos%=HC%
  1753. RD%=FH%-1
  1754. RD%<0
  1755. {    RD%=0
  1756. BG%=bE%
  1757. shell_Tracef0("BinarySearch:_search_term$ = "+_search_term$)
  1758. shell_Tracef0("BinarySearch:hi% = "+
  1759. shell_Tracef0("BinarySearch:lo% = "+
  1760. shell_Tracef0("BinarySearch:m%  = "+
  1761.  _wp$=
  1762. ("FN"+IB$+"( _pos% )")
  1763. shell_Tracef0("BinarySearch:_pos% = "+
  1764. _pos%)
  1765. shell_Tracef0("BinarySearch:_wp$  = "+_wp$)
  1766. yF%=_pos%
  1767. _search_term$=_wp$
  1768. shell_Tracef0("BinarySearch:_search_term$ = _wp$, item found..")
  1769. shell_Tracef0("BinarySearch:_search_term$ <> _wp$")
  1770. shell_Tracef0("BinarySearch:_search_term$ = "+_search_term$)
  1771. shell_Tracef0("BinarySearch:_wp$  = "+_wp$)
  1772. shell_Tracef0("BinarySearch:"+"FN"+m$+"( _search_term$,_wp$ )")
  1773. ("FN"+m$+"( _search_term$,_wp$ )")=
  1774. shell_Tracef0("BinarySearch:searching lower half..")
  1775. BG%=_pos%
  1776. HC%=_pos%-RD%
  1777. _pos%=HC%
  1778. 2+mE%
  1779. shell_Tracef0("BinarySearch:searching upper half..")
  1780. RD%=_pos%
  1781. mE%=_pos%
  1782. HC%=BG%-_pos%
  1783. _pos%=HC%
  1784. 2+mE%
  1785. PH%=yF%
  1786. PH%=yF%
  1787. *|Stop FNshell_BinarySearch
  1788. #*|Start FNshell_IconLastClicked
  1789. shell_IconLastClicked
  1790. Evnts_GetLastIconClicked
  1791. "*|Stop FNshell_IconLastClicked
  1792. *|Start PROCshell_QuickSort
  1793. shell_QuickSort(m$,CA$,_asc%,_start%,_end%)
  1794. _lo%,_h%,_F%,_temp%,j%
  1795. !_lo%=_start%:_hi%=_end%:_F%=
  1796.  _temp%=_lo%-1+
  1797. (_hi%+1-_lo%)
  1798. ("FN"+CA$+"(_lo%,_temp%)")
  1799. _asc%=0
  1800. ("FN"+m$+"(_lo%,_hi%)")
  1801. ("FN"+CA$+"(_lo%,_hi%)")
  1802. ("FN"+m$+"(_hi%,_lo%)")
  1803. ("FN"+CA$+"(_hi%,_lo%)")
  1804. _hi%=_hi%-1
  1805. _lo%=_lo%+1
  1806. _lo%=_hi%
  1807. _start%<_lo%-1
  1808. shell_QuickSort(m$,CA$,_asc%,_start%,_lo%-1)
  1809. _hi%+1<_end%
  1810. shell_QuickSort(m$,CA$,_asc%,_hi%+1,_end%)
  1811. *|Stop PROCshell_QuickSort
  1812. *|Start FN_shell_MS_swap
  1813. _shell_MS_swap(iE%,jE%)
  1814. y$,w$,sG%,cG%
  1815. shell_MenuGetItemText(_shell_MS_handle%,iE%)
  1816. shell_MenuGetItemText(_shell_MS_handle%,jE%)
  1817. 7sG%=
  1818. shell_MenuGetItemHandle(_shell_MS_handle%,iE%)
  1819. 7cG%=
  1820. shell_MenuGetItemHandle(_shell_MS_handle%,jE%)
  1821. shell_MenuPutData(sG%,w$)
  1822. shell_MenuPutData(cG%,y$)
  1823. *|Stop FN_shell_MS_swap
  1824. *|Start FN_shell_MS_comp
  1825. _shell_MS_comp(iE%,jE%)
  1826. y$,w$
  1827. shell_MenuGetItemText(_shell_MS_handle%,iE%)
  1828. shell_MenuGetItemText(_shell_MS_handle%,jE%)
  1829. *|Stop FN_shell_MS_comp
  1830. -*|Start PROCshell_WindowSetTitleRightJust
  1831. shell_WindowSetTitleRightJust(
  1832. v%,kA%,m%,tB%
  1833. shell_WindowIsOpen(a%)
  1834. shell_HeapBlockFetch(&64+(
  1835. shell_WindowCountIcons(a%)*32))
  1836. !v%=a%
  1837. &400CC,,v%
  1838. kA%=v%!60
  1839. (1<<3))
  1840. *|ifdef TraceInit
  1841. shell_Tracef0("WindowSetTitleRightJust:title flags = &"+
  1842. ~kA%)
  1843. shell_Tracef0("WindowSetTitleRightJust:Horizontally centred bit set..")
  1844. shell_Tracef0("WindowSetTitleRightJust:Unsetting horizontally centred bit..")
  1845. *|endif
  1846. kA%=kA%
  1847. (1<<3)
  1848. *|ifdef TraceInit
  1849. shell_Tracef0("WindowSetTitleRightJust:title flags = &"+
  1850. ~kA%)
  1851. *|endif
  1852. *|ifdef TraceInit
  1853. shell_Tracef0("WindowSetTitleRightJust:Horizontally centred bit NOT set..")
  1854. *|endif
  1855. *|ifdef TraceInit
  1856. shell_Tracef0("WindowSetTitleRightJust:Setting right justified bit..")
  1857. *|endif
  1858. kA%=kA%
  1859. (1<<9)
  1860. v%!60=kA%
  1861. &400C3,,v%
  1862. &400C1,,v%+4
  1863. a%<>m%
  1864. *|ifdef TraceInit
  1865. shell_Tracef0("WindowSetTitleRightJust:Updating window handle...")
  1866. *|endif
  1867. shell_UpdateWindowHandle(a%,m%)
  1868.     a%=m%
  1869. shell_OpenWindow(m%,0,0)
  1870. shell_HeapBlockReturn(v%)
  1871. ,*|Stop PROCshell_WindowSetTitleRightJust
  1872. .*|Start PROCshell_WindowSetTitleCentreJust
  1873. shell_WindowSetTitleCentreJust(
  1874. v%,kA%,m%,tB%
  1875. shell_WindowIsOpen(a%)
  1876. shell_HeapBlockFetch(&64+(
  1877. shell_WindowCountIcons(a%)*32))
  1878. !v%=a%
  1879. &400CC,,v%
  1880. kA%=v%!60
  1881. shell_Tracef0("WindowSetTitleCentreJust:title flags = &"+
  1882. ~kA%)
  1883. shell_Tracef0("WindowSetTitleCentreJust:t_flags% AND (1 << 3) = "+
  1884. ~(kA%
  1885. (1<<3)))
  1886. (1<<3))=0
  1887. *|ifdef TraceInit
  1888. shell_Tracef0("WindowSetTitleCentreJust:Horizontally centred bit not set..")
  1889. shell_Tracef0("WindowSetTitleCentreJust:Setting horizontally centred bit..")
  1890. *|endif
  1891. kA%=kA%
  1892. (1<<3)
  1893. *|ifdef TraceInit
  1894. shell_Tracef0("WindowSetTitleCentreJust:title flags = &"+
  1895. ~kA%)
  1896. *|endif
  1897. v%!60=kA%
  1898. &400C3,,v%
  1899. &400C1,,v%+4
  1900. a%<>m%
  1901. *|ifdef TraceInit
  1902. shell_Tracef0("WindowSetTitleCentreJust:Updating window handle...")
  1903. *|endif
  1904. shell_UpdateWindowHandle(a%,m%)
  1905. +    a%=m%
  1906. shell_OpenWindow(m%,0,0)
  1907. shell_HeapBlockReturn(v%)
  1908. 3-*|Stop PROCshell_WindowSetTitleCentreJust
  1909. 7&*|Start FNshell_GetLastMouseButton
  1910. shell_GetLastMouseButton
  1911. Evnts_GetLastMouseButton
  1912. ;%*|Stop FNshell_GetLastMouseButton
  1913. =(*|Start FNshell_GetLastWindowClicked
  1914. shell_GetLastWindowClicked
  1915. Evnts_GetLastWindowClicked
  1916. A'*|Stop FNshell_GetLastWindowClicked
  1917. C&*|Start FNshell_GetLastIconClicked
  1918. shell_GetLastIconClicked
  1919. Evnts_GetLastIconClicked
  1920. G%*|Stop FNshell_GetLastIconClicked
  1921. K%*|Start FNshell_StrongHlpChkFiles
  1922. shell_StrongHlpChkFiles(I$)
  1923. shell_FileExists(I$+".HelpData")
  1924. sB%=-1
  1925. shell_MessageOneArg("SHELLMSG32","HelpData")
  1926. shell_FileExists(I$+".Index")
  1927. sB%=-1
  1928. shell_MessageOneArg("SHELLMSG32","Index")
  1929. Z$*|Stop FNshell_StrongHlpChkFiles
  1930. ^&*|Start PROCshell_TemplateFileInfo
  1931. shell_TemplateFileInfo(K$,
  1932. RO3_Present
  1933. shell_TemplateFileInfo3(K$,FB%,FA%,t%)
  1934. shell_TemplateFileInfo2(K$,FB%,FA%,t%)
  1935. q%*|Stop PROCshell_TemplateFileInfo
  1936. s'*|Start PROCshell_TemplateFileInfo2
  1937. shell_TemplateFileInfo2(K$,
  1938. NA%,JC%,jB%
  1939. UA%,X%,kB%,UJ%
  1940. i%,EE%,bF%,MB%,bD%,o%
  1941. x NA%=0:FA%=0:JC%=0:jB%=0:t%=0
  1942. shell_FileExists(K$)
  1943. t%=-1
  1944. shell_FileType(K$)<>&FEC
  1945. t%=-2
  1946. }!UA%=
  1947. shell_HeapBlockFetch(&D)
  1948. #X%=16
  1949. &C,4,X%,UA%,4
  1950. OB%=!UA%
  1951. OB%>0
  1952. FA%+=1
  1953.     pF%=0
  1954. &C,4,X%,UA%,4
  1955. kB%=!UA%
  1956. &C,4,X%,UA%,4
  1957. UJ%=!UA%
  1958. &C,4,X%,UA%,&C
  1959. #X%=OB%+56
  1960. &C,4,X%,UA%,4
  1961. o%=!UA%
  1962. #X%=OB%+72
  1963. &C,4,X%,UA%,&C
  1964. ,pF%+=
  1965. shell_IconIndirSize(OB%,o%,UA%,X%)
  1966. #X%=OB%+84
  1967. &C,4,X%,UA%,4
  1968. MB%=!UA%
  1969. MB%>0
  1970. bD%=0
  1971. MB%-1
  1972. #X%=OB%+88+(bD%*32)+16
  1973. &C,4,X%,UA%,4
  1974. o%=!UA%
  1975. #X%=OB%+88+(bD%*32)+20
  1976. &C,4,X%,UA%,&C
  1977. ,pF%+=
  1978. shell_IconIndirSize(OB%,o%,UA%,X%)
  1979. #X%=bF%
  1980. JC%+=pF%
  1981. kB%>jB%
  1982. jB%=kB%
  1983. OB%=0
  1984. shell_HeapBlockReturn(UA%)
  1985. FB%=jB%+JC%
  1986. &*|Stop PROCshell_TemplateFileInfo2
  1987. '*|Start PROCshell_TemplateFileInfo3
  1988. shell_TemplateFileInfo3(K$,
  1989. NA%,JC%,jB%,OB%
  1990. i%,EE%,bF%,MB%,bD%,o%
  1991. NA%=0:FA%=0:JC%=0:jB%=0
  1992. !UA%=
  1993. shell_HeapBlockFetch(&D)
  1994. &400D9,,K$
  1995. $UA%="*"
  1996. &400DB,,-1,,,,UA%,NA%
  1997. ,FB%,qI%,,,,NA%
  1998. NA%<>0
  1999. FB%>jB%
  2000. jB%=FB%
  2001. JC%+=qI%
  2002. FA%+=1
  2003. NA%=0
  2004. &400DA
  2005. FB%=jB%+JC%
  2006. shell_HeapBlockReturn(UA%)
  2007. &*|Stop PROCshell_TemplateFileInfo3
  2008. *|Start FNRO3_Present
  2009. RO3_Present
  2010. d%,KC%,Q$
  2011. shell_HeapBlockFetch(256)
  2012. ("Set RO3$Check Y")
  2013. ("RMEnsure UtilityModule 3.00 Set RO3$Check N")
  2014. 35,"RO3$Check",d%,256,0,0
  2015. ,,KC%
  2016. d%?KC%=&D
  2017. ("Unset RO3$Check")
  2018. Q$=$d%
  2019. shell_HeapBlockReturn(d%)
  2020. Q$="N"
  2021. *|Stop FNRO3_Present
  2022. *|Start FN_shell_icondrag
  2023. _shell_icondrag(a%,r%)
  2024. shell_IconDragBox(a%,r%)
  2025. *|Stop FN_shell_icondrag
  2026. **|Start PROCshell_MessageSendPrintSave
  2027. shell_MessageSendPrintSave(MG%,nG%)
  2028. nG%>1
  2029. _U%!336=nG%-1
  2030. _U%!336=0
  2031. shell_DoSendPrintSave(MG%)
  2032. )*|Stop PROCshell_MessageSendPrintSave
  2033. %*|Start PROCshell_DoSendPrintSave
  2034. shell_DoSendPrintSave(MG%)
  2035. "MA%=
  2036. shell_HeapBlockFetch(256)
  2037. MA%!0=256
  2038. MA%!&C=0
  2039. MA%!16=&80142
  2040. MA%!20=0
  2041. MA%!24=0
  2042. MA%!28=0
  2043. MA%!32=0
  2044. MA%!36=256
  2045. MA%!40=MG%
  2046. $(MA%+44)="PrintOut"+
  2047. *|ifdef TraceInit
  2048. shell_Tracef0("MessageSendPrintSave:Sending PrintSave message..")
  2049. *|endif
  2050. &400E7,18,MA%,MA%!20,MA%!24
  2051. shell_HeapBlockReturn(MA%)
  2052. $*|Stop PROCshell_DoSendPrintSave
  2053.     %*|Start PROCshell_HandlePrintFile
  2054. shell_HandlePrintFile(_Q%)
  2055. *|ifdef TraceInit
  2056. shell_Tracef0("HandlePrintFile:Message_PrintFile received")
  2057. *|endif
  2058. $*|Stop PROCshell_HandlePrintFile
  2059. &*|Start PROCshell_HandlePrintError
  2060. shell_HandlePrintError(_Q%)
  2061. *|ifdef TraceInit
  2062. shell_Tracef0("HandlePrintError:Message_PrintError received")
  2063. *|endif
  2064. %*|Stop PROCshell_HandlePrintError
  2065. (*|Start PROCshell_HandlePrintTypeOdd
  2066. shell_HandlePrintTypeOdd(_Q%)
  2067. *|ifdef TraceInit
  2068. shell_Tracef0("HandlePrintTypeOdd:Message_PrintTypeOdd received")
  2069. *|endif
  2070. "'*|Stop PROCshell_HandlePrintTypeOdd
  2071. $&*|Start PROCshell_HandleSetPrinter
  2072. shell_HandleSetPrinter(_Q%)
  2073. *|ifdef TraceInit
  2074. shell_Tracef0("HandleSetPrinter:Message_SetPrinter received")
  2075. *|endif
  2076. +%*|Stop PROCshell_HandleSetPrinter
  2077. *|Start FNshell_3DEnabled
  2078. shell_3DEnabled
  2079. OH%,_3d%
  2080. _U%!&64
  2081. (1<<&A)
  2082. 6,&A1,&8C
  2083. ,,OH%
  2084. _3d%=
  2085. _3d%=
  2086. _3d%=
  2087. <    =_3d%
  2088. *|Stop FNshell_3DEnabled
  2089. B,*|Start PROCshell_HandleAttachedDataSave
  2090. shell_HandleAttachedDataSave(_Q%,a%,r%)
  2091. YF%,d%,BH%,_name$,g%,j%
  2092. shell_DataSaveCheckName(a%,r%)
  2093. I4YF%=
  2094. shell_GetEventListOffset(a%,-1,_U%+72,24,
  2095. YF%>=0
  2096. d%=_U%!72+YF%
  2097. BH%=d%!16
  2098. M%_name$=
  2099. shell_IconGetData(a%,BH%)
  2100. g%=d%!20
  2101. $g%<>""
  2102. ("FN"+$g%+"(_name$)")
  2103. S+*|Stop PROCshell_HandleAttachedDataSave
  2104. *|Start FNshell_InstallLib
  2105. shell_InstallLib(X$)
  2106. 1,"Unable to install "+X$
  2107. X$,&A)
  2108. X$,".")
  2109. X$,".")+1)
  2110. "FN_shell_"+X$+"_Init not found":
  2111. ("FN_shell_"+X$+"_Init")
  2112. *|Stop FNshell_InstallLib
  2113. !*|Start FN_shell_Iconbar_Init
  2114. _shell_Iconbar_Init
  2115.  *|Stop FN_shell_Iconbar_Init
  2116. *|Start FNshell_Iconbar
  2117. shell_Iconbar(NA%,mA$,J$,HB%,z%,fC%,hC%,FD%)
  2118. m%,GA%,eF%,sE%
  2119. !GA%=
  2120. shell_HeapBlockFetch(36)
  2121. eF%20
  2122. sE%20
  2123. !GA%=NA%
  2124. GA%!4=0
  2125. GA%!&C=96
  2126. J$<>""
  2127. GA%!8=-16
  2128. GA%!16=92
  2129. GA%!32=
  2130. GA%!8=0
  2131. GA%!16=70
  2132. GA%!32=&C
  2133. GA%!20=&1700310B
  2134. GA%!24=eF%
  2135. GA%!28=sE%
  2136. $eF%=J$
  2137. $sE%=mA$
  2138. &400C2,,GA%
  2139. shell_AttachMenu(-2,m%,z%,fC%,hC%,FD%)
  2140. shell_HeapBlockReturn(GA%)
  2141. shell_IconNewSprite(NA%,m%,mA$)
  2142. *|Stop FNshell_Iconbar
  2143. $*|Start PROCshell_IconbarSetText
  2144. shell_IconbarSetText(e%,h%,ZB$)
  2145. shell_HeapBlockFetch(40)
  2146. !l%=e%
  2147. l%!4=h%
  2148. &400CE,,l%
  2149. $(l%!28)=ZB$
  2150. shell_IconRedraw(e%,h%)
  2151. shell_HeapBlockReturn(l%)
  2152. #*|Stop PROCshell_IconbarSetText
  2153. *|Start FN_shell_Files_Init
  2154. _shell_Files_Init
  2155. *|Stop FN_shell_Files_Init
  2156. *|Start FNshell_FileLength
  2157. shell_FileLength(g$)
  2158. pA%,zD%,_D%,UB%,gC%,C$
  2159. 8,5,g$
  2160. pA%,,zD%,_D%,UB%,gC%
  2161. *|Stop FNshell_FileLength
  2162. *|Start FNshell_FileType
  2163. shell_FileType(g$)
  2164. 8,5,g$
  2165. ,,pA%
  2166. pA%=(pA%
  2167. &FFF00)>>>8
  2168. *|Stop FNshell_FileType
  2169. *|Start FNshell_FileExists
  2170. shell_FileExists(g$)
  2171. pA%,E
  2172. 8,E,g$
  2173. pA%=0
  2174. *|Stop FNshell_FileExists
  2175. *|Start FNshell_CatInfoRead
  2176. shell_CatInfoRead(g$)
  2177. pA%,zD%,_D%,UB%,gC%,C$
  2178. 8,5,g$
  2179. pA%,,zD%,_D%,UB%,gC%
  2180. pA%=0
  2181. ="Not Found"
  2182. gC%=51
  2183. C$+="WR "
  2184. gC%=&BB
  2185. C$+="LWR"
  2186. gC%=&88
  2187. C$+="DL "
  2188. 0C$+=" "+
  2189. shell_StringPadLeading(
  2190. ~zD%,"0",8)
  2191. 0C$+=" "+
  2192. shell_StringPadLeading(
  2193. ~_D%,"0",8)
  2194. 0C$+=" "+
  2195. shell_StringPadLeading(
  2196. ~UB%,"0",8)
  2197. *|Stop FNshell_CatInfoRead
  2198. $*|Start FNshell_FileGetDateStamp
  2199. shell_FileGetDateStamp(g$)
  2200. pA%,VG%,E
  2201. 8,E,g$
  2202. pA%,,,VG%
  2203. pA%=0
  2204. #*|Stop FNshell_FileGetDateStamp
  2205. *|Start FN_shell_Evnts_Init
  2206. _shell_Evnts_Init
  2207. _EVNTS_HEADER_SIZE%=8
  2208. GE%=-1
  2209. _EVNTS_PANE_BLK%&BB8
  2210. _EVNTS_CLICKSELECT_ANCHOR%4
  2211. _EVNTS_CLICKADJUST_ANCHOR%4
  2212. _EVNTS_CLICKMENU_ANCHOR%4
  2213. _EVNTS_HELPTAG_ANCHOR%4
  2214. _EVNTS_POPUPS_ANCHOR%4
  2215. _EVNTS_PANES_ANCHOR%4
  2216. _EVNTS_SLIDERS_ANCHOR%4
  2217. _EVNTS_POINTERIN_ANCHOR%4
  2218. _EVNTS_POINTEROUT_ANCHOR%4
  2219. _EVNTS_DATASAVE_ANCHOR%4
  2220. _EVNTS_REDRAW_ANCHOR%4
  2221. _EVNTS_DRAG_ANCHOR%4
  2222. _EVNTS_BUMP_ANCHOR%4
  2223. _EVNTS_WINDOWOPEN_ANCHOR%4
  2224. _EVNTS_WINDOWCLOSE_ANCHOR%4
  2225. _EVNTS_ICONWATCH_ANCHOR%4
  2226. _EVNTS_MENUHELPTAG_ANCHOR%4
  2227. !!_EVNTS_CLICKSELECT_ANCHOR%=0
  2228. !!_EVNTS_CLICKADJUST_ANCHOR%=0
  2229. !_EVNTS_CLICKMENU_ANCHOR%=0
  2230. !_EVNTS_HELPTAG_ANCHOR%=0
  2231. !_EVNTS_POPUPS_ANCHOR%=0
  2232. !_EVNTS_SLIDERS_ANCHOR%=0
  2233. !_EVNTS_PANES_ANCHOR%=0
  2234. !_EVNTS_POINTERIN_ANCHOR%=0
  2235.  !_EVNTS_POINTEROUT_ANCHOR%=0
  2236. !_EVNTS_DATASAVE_ANCHOR%=0
  2237. !_EVNTS_REDRAW_ANCHOR%=0
  2238. !_EVNTS_DRAG_ANCHOR%=0
  2239. !_EVNTS_BUMP_ANCHOR%=0
  2240.  !_EVNTS_WINDOWOPEN_ANCHOR%=0
  2241. !!_EVNTS_WINDOWCLOSE_ANCHOR%=0
  2242. !_EVNTS_ICONWATCH_ANCHOR%=0
  2243. !!_EVNTS_MENUHELPTAG_ANCHOR%=0
  2244. _EVNTS_CLICKSELECT_DATA%4
  2245. _EVNTS_CLICKADJUST_DATA%4
  2246. _EVNTS_CLICKMENU_DATA%4
  2247. _EVNTS_HELPTAG_DATA%4
  2248. _EVNTS_POPUPS_DATA%4
  2249. _EVNTS_PANES_DATA%4
  2250. _EVNTS_SLIDERS_DATA%4
  2251. _EVNTS_POINTERIN_DATA%4
  2252. _EVNTS_POINTEROUT_DATA%4
  2253. _EVNTS_DATASAVE_DATA%4
  2254. _EVNTS_REDRAW_DATA%4
  2255. _EVNTS_DRAG_DATA%4
  2256. _EVNTS_BUMP_DATA%4
  2257. _EVNTS_WINDOWOPEN_DATA%4
  2258. _EVNTS_WINDOWCLOSE_DATA%4
  2259. _EVNTS_ICONWATCH_DATA%4
  2260. _EVNTS_MENUHELPTAG_DATA%4
  2261. !_EVNTS_CLICKSELECT_DATA%=0
  2262. !_EVNTS_CLICKADJUST_DATA%=0
  2263. !_EVNTS_CLICKMENU_DATA%=0
  2264. !_EVNTS_HELPTAG_DATA%=0
  2265. !_EVNTS_POPUPS_DATA%=0
  2266. !_EVNTS_PANES_DATA%=0
  2267. !_EVNTS_POINTERIN_DATA%=0
  2268. !_EVNTS_POINTEROUT_DATA%=0
  2269. !_EVNTS_DATASAVE_DATA%=0
  2270. !_EVNTS_REDRAW_DATA%=0
  2271. !_EVNTS_DRAG_DATA%=0
  2272. !_EVNTS_BUMP_DATA%=0
  2273. !_EVNTS_WINDOWOPEN_DATA%=0
  2274. !_EVNTS_WINDOWCLOSE_DATA%=0
  2275. !_EVNTS_SLIDERS_DATA%=0
  2276. !_EVNTS_ICONWATCH_DATA%=0
  2277. !_EVNTS_MENUHELPTAG_DATA%=0
  2278. #_EVNTS_CLICKSELECT_REC_SIZE%=20
  2279. #_EVNTS_CLICKADJUST_REC_SIZE%=20
  2280. !_EVNTS_CLICKMENU_REC_SIZE%=24
  2281. _EVNTS_HELPTAG_REC_SIZE%=20
  2282. _EVNTS_POPUPS_REC_SIZE%=36
  2283. _EVNTS_PANES_REC_SIZE%=32
  2284. !_EVNTS_POINTERIN_REC_SIZE%=20
  2285. "_EVNTS_POINTEROUT_REC_SIZE%=20
  2286.  _EVNTS_DATASAVE_REC_SIZE%=20
  2287. _EVNTS_REDRAW_REC_SIZE%=20
  2288. _EVNTS_DRAG_REC_SIZE%=20
  2289. _EVNTS_BUMP_REC_SIZE%=44
  2290. _EVNTS_SLIDERS_REC_SIZE%=40
  2291. "_EVNTS_WINDOWOPEN_REC_SIZE%=20
  2292. #_EVNTS_WINDOWCLOSE_REC_SIZE%=20
  2293. !_EVNTS_ICONWATCH_REC_SIZE%=24
  2294. #_EVNTS_MENUHELPTAG_REC_SIZE%=20
  2295. $_EVNTS_CLICKSELECT_DATAOFFSET%=0
  2296. $_EVNTS_CLICKADJUST_DATAOFFSET%=0
  2297. "_EVNTS_CLICKMENU_DATAOFFSET%=0
  2298.  _EVNTS_HELPTAG_DATAOFFSET%=0
  2299. _EVNTS_POPUPS_DATAOFFSET%=0
  2300. _EVNTS_PANES_DATAOFFSET%=0
  2301. "_EVNTS_POINTERIN_DATAOFFSET%=0
  2302. #_EVNTS_POINTEROUT_DATAOFFSET%=0
  2303. !_EVNTS_DATASAVE_DATAOFFSET%=0
  2304. _EVNTS_REDRAW_DATAOFFSET%=0
  2305. _EVNTS_DRAG_DATAOFFSET%=0
  2306. _EVNTS_BUMP_DATAOFFSET%=0
  2307.  _EVNTS_SLIDERS_DATAOFFSET%=0
  2308. #_EVNTS_WINDOWOPEN_DATAOFFSET%=0
  2309. $_EVNTS_WINDOWCLOSE_DATAOFFSET%=0
  2310. "_EVNTS_ICONWATCH_DATAOFFSET%=0
  2311. $_EVNTS_MENUHELPTAG_DATAOFFSET%=0
  2312. _EVNTS_LAST_MOUSEBUTTON%=0
  2313. _EVNTS_LAST_MOUSEXPOS%=0
  2314. _EVNTS_LAST_MOUSEYPOS%=0
  2315. _EVNTS_LAST_ICONCLICKED%=-1
  2316. !_EVNTS_LAST_WINDOWCLICKED%=-1
  2317.  _EVNTS_LAST_MENUMAKER_FN$=""
  2318. _m_evnts_DestTaskHandle%=-1
  2319. !_m_evnts_DestWindowHandle%=-1
  2320. _m_evnts_DestIconHandle%=-1
  2321. _m_evnts_MouseXCoord%=-1
  2322. _m_evnts_MouseYCoord%=-1
  2323. $_m_evnts_DragIconStartWindow%=-1
  2324. "_m_evnts_DragIconStartIcon%=-1
  2325. $_m_evnts_DragIconWritableDrag%=
  2326. *|Stop FN_shell_Evnts_Init
  2327. %*|Start FNEvnts_GetEvntListOffset
  2328. Evnts_GetEvntListOffset(A$,h%,k%,BA%,KI%)
  2329. EA%,f%,w%,c%,MC%,mB%
  2330. A$="IconBar"
  2331.     h%=-1
  2332. A$="iconbar"
  2333. (!k%=0
  2334. A$=""
  2335. (!k%=0)
  2336. $6!k%=
  2337. shell_HeapBlockFetch(BA%+_EVNTS_HEADER_SIZE%)
  2338. MC%=!k%
  2339. MC%!0=BA%
  2340. MC%!4=1
  2341. (!$(MC%+_EVNTS_HEADER_SIZE%)=""
  2342. q%=&C
  2343. (BA%-4)
  2344. +#MC%!(q%+_EVNTS_HEADER_SIZE%)=-1
  2345. GE%=_EVNTS_HEADER_SIZE%
  2346. =_EVNTS_HEADER_SIZE%
  2347. MC%=!k%
  2348. EA%=!MC%
  2349. f%=_EVNTS_HEADER_SIZE%
  2350. 8    c%=-1
  2351. sJ%=-1
  2352. mB%=!k%
  2353. ($(mB%+f%)=A$)
  2354. mB%!(f%+&C)=h%
  2355. B    c%=f%
  2356. f%+=BA%
  2357. f%+=BA%
  2358. ((f%>=(EA%+_EVNTS_HEADER_SIZE%))
  2359. (c%=-1
  2360. c%=EA%+_EVNTS_HEADER_SIZE%
  2361. O'!k%=
  2362. shell_HeapBlockExtend(!k%,BA%)
  2363. GD%=!k%
  2364. GD%!0+=BA%
  2365. GD%!4+=1
  2366. GD%+=c%
  2367. $(GD%)=""
  2368. q%=&C
  2369. (BA%-4)
  2370. GD%!q%=-1
  2371. GE%=c%
  2372. g$*|Stop FNEvnts_GetEvntListOffset
  2373. k *|Start PROCEvnts_UpdateData
  2374. Evnts_UpdateData(p%,wB%,
  2375. RA%,F$)
  2376. !p%=-1
  2377. !p%=RA%
  2378. t-!wB%=
  2379. shell_HeapBlockExtend(!wB%,
  2380. (F$)+1)
  2381. $(!wB%+RA%)=F$
  2382. RA%+=
  2383. (F$)+1
  2384. r$=$(!wB%+!p%)
  2385. r$<>F$
  2386. (F$)<=
  2387. $(!wB%+!p%)=F$
  2388. -!wB%=
  2389. shell_HeapBlockExtend(!wB%,
  2390. (F$)+1)
  2391. $(!wB%+RA%)=F$
  2392. !p%=RA%
  2393. RA%+=
  2394. (F$)+1
  2395. *|Stop PROCEvnts_UpdateData
  2396. %*|Start PROCEvnts_DebugListHeader
  2397. Evnts_DebugListHeader(dB$,fB$)
  2398. $*|Stop PROCEvnts_DebugListHeader
  2399. '*|Start PROCshell_AttachClickSelect
  2400. shell_AttachClickSelect(e%,h%,B$)
  2401. c%,b%,p%,A$
  2402. shell_GetWindowIdentifier(e%)
  2403. A$="iconbar"
  2404.     h%=-1
  2405. Evnts_GetEvntListOffset(A$,h%,_EVNTS_CLICKSELECT_ANCHOR%,_EVNTS_CLICKSELECT_REC_SIZE%,
  2406. "b%=!_EVNTS_CLICKSELECT_ANCHOR%
  2407. b%+=c%
  2408. $b%=A$
  2409. b%!&C=h%
  2410. !_EVNTS_CLICKSELECT_DATA%=0
  2411. <!_EVNTS_CLICKSELECT_DATA%=
  2412. shell_HeapBlockFetch(
  2413. (B$)+1)
  2414. p%=b%+16
  2415. Evnts_UpdateData(p%,_EVNTS_CLICKSELECT_DATA%,_EVNTS_CLICKSELECT_DATAOFFSET%,B$)
  2416. shell_IconSetButtonType(e%,h%,_BUTTON_TYPE_CLICK)
  2417. &*|Stop PROCshell_AttachClickSelect
  2418. ,*|Start PROCshell_EvntHandle_ClickSelect
  2419. shell_EvntHandle_ClickSelect(_window_handle%,_icon_handle%)
  2420. A$,c%,B$,k%,x%,t%,k$
  2421. shell_GetWindowIdentifier(_window_handle%)
  2422. A$="iconbar"
  2423. _icon_handle%=-1
  2424. Evnts_GetEvntListOffset(A$,_icon_handle%,_EVNTS_CLICKSELECT_ANCHOR%,_EVNTS_CLICKSELECT_REC_SIZE%,
  2425. Evnts_GetEvntListOffset(A$,-1,_EVNTS_CLICKSELECT_ANCHOR%,_EVNTS_CLICKSELECT_REC_SIZE%,
  2426. c%>=0
  2427. %k%=!_EVNTS_CLICKSELECT_ANCHOR%+c%
  2428. JA%=k%!16
  2429.  x%=!_EVNTS_CLICKSELECT_DATA%
  2430. B$=$(x%+JA%)
  2431. ("FN"+B$+"( _window_handle%, _icon_handle% )")
  2432. _icon_handle%=0
  2433. _window_handle%=_U%!20
  2434. shell_CloseWindow(_window_handle%)
  2435. _window_handle%>0
  2436. A$<>""
  2437. shell_IconIsDraggable(
  2438. Evnts_GetLastWindowClicked,
  2439. Evnts_GetLastIconClicked)
  2440. k$="Icon is draggable"
  2441. shell_EvntHandle_UserDragStartDrag(
  2442. Evnts_GetLastWindowClicked,
  2443. Evnts_GetLastIconClicked)
  2444. shell_EvntHandle_DataSaveStartDrag(
  2445. Evnts_GetLastWindowClicked,
  2446. Evnts_GetLastIconClicked)
  2447. shell_HandleSlider(
  2448. Evnts_GetLastWindowClicked,
  2449. Evnts_GetLastIconClicked)
  2450. k$="Icon is not draggable"
  2451. shell_EvntHandle_PopupMenu(_window_handle%,_icon_handle%)
  2452. shell_EvntHandle_Bumpers(_window_handle%,_icon_handle%)
  2453. +*|Stop PROCshell_EvntHandle_ClickSelect
  2454. %*|Start PROCshell_ListClickSelect
  2455. shell_ListClickSelect
  2456. EA%,n%,BA%,f%,OA%,mB%
  2457. h%,B$,IA%,q%
  2458. "n%=!_EVNTS_CLICKSELECT_ANCHOR%
  2459. $BA%=_EVNTS_CLICKSELECT_REC_SIZE%
  2460. OA%=n%!4
  2461. Evnts_DebugListHeader ("ClickSelect","Window         Icon   FN")
  2462. f%=_EVNTS_HEADER_SIZE%
  2463. A$=$(n%+f%)
  2464. h%=n%!(f%+&C)
  2465.     !IA%=!_EVNTS_CLICKSELECT_DATA%
  2466. IA%>0
  2467. B$=$(IA%+n%!(f%+16))
  2468. $f%+=_EVNTS_CLICKSELECT_REC_SIZE%
  2469. $*|Stop PROCshell_ListClickSelect
  2470.  '*|Start PROCshell_AttachClickAdjust
  2471. shell_AttachClickAdjust(e%,h%,B$)
  2472. c%,b%,A$
  2473. $%A$=
  2474. shell_GetWindowIdentifier(e%)
  2475. A$="iconbar"
  2476. '    h%=-1
  2477. *`c%=
  2478. Evnts_GetEvntListOffset(A$,h%,_EVNTS_CLICKADJUST_ANCHOR%,_EVNTS_CLICKADJUST_REC_SIZE%,
  2479. +"b%=!_EVNTS_CLICKADJUST_ANCHOR%
  2480. b%+=c%
  2481. $b%=A$
  2482. b%!&C=h%
  2483. !_EVNTS_CLICKADJUST_DATA%=0
  2484. 2<!_EVNTS_CLICKADJUST_DATA%=
  2485. shell_HeapBlockFetch(
  2486. (B$)+1)
  2487. p%=b%+16
  2488. Evnts_UpdateData(p%,_EVNTS_CLICKADJUST_DATA%,_EVNTS_CLICKADJUST_DATAOFFSET%,B$)
  2489. shell_IconSetButtonType(e%,h%,_BUTTON_TYPE_CLICK)
  2490. <&*|Stop PROCshell_AttachClickAdjust
  2491. @,*|Start PROCshell_EvntHandle_ClickAdjust
  2492. shell_EvntHandle_ClickAdjust(_window_handle%,_icon_handle%)
  2493. A$,c%,B$,k%,x%
  2494. C2A$=
  2495. shell_GetWindowIdentifier(_window_handle%)
  2496. A$="iconbar"
  2497. _icon_handle%=-1
  2498. Ikc%=
  2499. Evnts_GetEvntListOffset(A$,_icon_handle%,_EVNTS_CLICKADJUST_ANCHOR%,_EVNTS_CLICKADJUST_REC_SIZE%,
  2500. Evnts_GetEvntListOffset(A$,-1,_EVNTS_CLICKADJUST_ANCHOR%,_EVNTS_CLICKADJUST_REC_SIZE%,
  2501. c%>=0
  2502. M%k%=!_EVNTS_CLICKADJUST_ANCHOR%+c%
  2503. JA%=k%!16
  2504. O x%=!_EVNTS_CLICKADJUST_DATA%
  2505. B$=$(x%+JA%)
  2506. Q3j%=
  2507. ("FN"+B$+"(_window_handle%,_icon_handle%)")
  2508. _window_handle%>0
  2509. shell_EvntHandle_Bumpers(_window_handle%,_icon_handle%)
  2510. Z+*|Stop PROCshell_EvntHandle_ClickAdjust
  2511. ^%*|Start PROCshell_ListClickAdjust
  2512. shell_ListClickAdjust
  2513. EA%,n%,BA%,f%,OA%,mB%
  2514. h%,B$,IA%,q%
  2515. b"n%=!_EVNTS_CLICKADJUST_ANCHOR%
  2516. c$BA%=_EVNTS_CLICKADJUST_REC_SIZE%
  2517. OA%=n%!4
  2518. Evnts_DebugListHeader ("ClickAdjust","Window         Icon   FN")
  2519. f%=_EVNTS_HEADER_SIZE%
  2520. A$=$(n%+f%)
  2521. h%=n%!(f%+&C)
  2522. m!IA%=!_EVNTS_CLICKADJUST_DATA%
  2523. IA%>0
  2524. B$=$(IA%+n%!(f%+16))
  2525. r$f%+=_EVNTS_CLICKADJUST_REC_SIZE%
  2526. x$*|Stop PROCshell_ListClickAdjust
  2527.  *|Start PROCshell_AttachMenu
  2528. shell_AttachMenu(e%,h%,s%,fC%,hC%,FD%)
  2529. c%,b%,A$
  2530. shell_IsWindowStatic(e%)=
  2531. shell_OK(
  2532. shell_MessageNoArgs("SHELLMSG30"))
  2533. shell_GetWindowIdentifier(e%)
  2534. )wA$=
  2535. shell_MenuList_GetIdentifier(s%)
  2536. A$="iconbar"
  2537.     h%=-1
  2538. h%>=0
  2539. shell_IconSetButtonType(e%,h%,3)
  2540. shell_EvntAdd_PopUpMenu(A$,h%,-1,s%,"","",_POPUP_TYPE_TEXT)
  2541. Evnts_GetEvntListOffset(A$,h%,_EVNTS_CLICKMENU_ANCHOR%,_EVNTS_CLICKMENU_REC_SIZE%,
  2542.  b%=!_EVNTS_CLICKMENU_ANCHOR%
  2543. b%+=c%
  2544. $b%=A$
  2545. b%!&C=h%
  2546. b%!20=-1
  2547. !_EVNTS_CLICKMENU_DATA%=0
  2548. 4!_EVNTS_CLICKMENU_DATA%=
  2549. shell_HeapBlockFetch(1)
  2550. p%=b%+16
  2551. Evnts_UpdateData(p%,_EVNTS_CLICKMENU_DATA%,_EVNTS_CLICKMENU_DATAOFFSET%,wA$)
  2552. p%=b%+20
  2553. Evnts_UpdateData(p%,_EVNTS_CLICKMENU_DATA%,_EVNTS_CLICKMENU_DATAOFFSET%,"")
  2554. *|Stop PROCshell_AttachMenu
  2555. %*|Start PROCshell_AttachPopupMenu
  2556. shell_AttachPopupMenu(a%,NC%,iC%,z%,Y$,V$)
  2557. NC%>=0
  2558. shell_IconSetButtonType(a%,NC%,3)
  2559. shell_EvntAdd_PopUpMenu(
  2560. shell_GetWindowIdentifier(a%),NC%,iC%,z%,Y$,V$,_POPUP_TYPE_TEXT)
  2561. $*|Stop PROCshell_AttachPopupMenu
  2562. +*|Start PROCshell_AttachColourPopupMenu
  2563. shell_AttachColourPopupMenu(a%,NC%,iC%,z%,Y$,V$)
  2564. NC%>=0
  2565. shell_IconSetButtonType(a%,NC%,3)
  2566. shell_EvntAdd_PopUpMenu(
  2567. shell_GetWindowIdentifier(a%),NC%,iC%,z%,Y$,V$,_POPUP_TYPE_WIMPCOLOUR)
  2568. **|Stop PROCshell_AttachColourPopupMenu
  2569. **|Start PROCshell_EvntHandle_ClickMenu
  2570. shell_EvntHandle_ClickMenu(_window_handle%,_icon_handle%)
  2571. A$,c%,k%,hH%,a$,zF%,j%
  2572. shell_GetWindowIdentifier(_window_handle%)
  2573. A$="iconbar"
  2574. _icon_handle%=-1
  2575. Evnts_GetEvntListOffset(A$,_icon_handle%,_EVNTS_CLICKMENU_ANCHOR%,_EVNTS_CLICKMENU_REC_SIZE%,
  2576. Evnts_GetEvntListOffset(A$,-1,_EVNTS_CLICKMENU_ANCHOR%,_EVNTS_CLICKMENU_REC_SIZE%,
  2577. c%>=0
  2578. #k%=!_EVNTS_CLICKMENU_ANCHOR%+c%
  2579. kH%=k%!16
  2580. hH%=k%!20
  2581. zF%=!_EVNTS_CLICKMENU_DATA%
  2582. shell_MenuList_GetSysHandle($(zF%+kH%))
  2583. a$=$(zF%+hH%)
  2584.  _EVNTS_LAST_MENUMAKER_FN$=a$
  2585. a$<>""
  2586. ("FN"+a$+"( "+
  2587. _window_handle%+", "+
  2588. _icon_handle%+" )")
  2589. shell_OpenMenu(_Q%!0,_Q%!4,s%)
  2590. _window_handle%>0
  2591. shell_EvntHandle_PopupMenu(_window_handle%,_icon_handle%)
  2592. )*|Stop PROCshell_EvntHandle_ClickMenu
  2593. #*|Start PROCshell_ListClickMenu
  2594. shell_ListClickMenu
  2595. EA%,n%,BA%,f%,OA%,mB%,s%
  2596. h%,q%,a$
  2597.  n%=!_EVNTS_CLICKMENU_ANCHOR%
  2598. "BA%=_EVNTS_CLICKMENU_REC_SIZE%
  2599. OA%=n%!4
  2600. Evnts_DebugListHeader ("ClickMenu  ","Window         Icon   Menu handle  Maker FN")
  2601. f%=_EVNTS_HEADER_SIZE%
  2602. A$=$(n%+f%)
  2603. h%=n%!(f%+&C)
  2604. s%=n%!(f%+16)
  2605. IA%=!_EVNTS_CLICKMENU_DATA%
  2606. IA%>0
  2607. a$=$(IA%+n%!(f%+20))
  2608. a$="None"
  2609. "f%+=_EVNTS_CLICKMENU_REC_SIZE%
  2610. "*|Stop PROCshell_ListClickMenu
  2611.  %*|Start PROCshell_AttachMenuMaker
  2612. shell_AttachMenuMaker(e%,h%,s%,a$)
  2613. c%,b%,A$,p%
  2614. shell_AttachMenu(e%,h%,s%,0,0,0)
  2615. '%A$=
  2616. shell_GetWindowIdentifier(e%)
  2617. A$="iconbar"
  2618. )    h%=-1
  2619. -\c%=
  2620. Evnts_GetEvntListOffset(A$,h%,_EVNTS_CLICKMENU_ANCHOR%,_EVNTS_CLICKMENU_REC_SIZE%,
  2621. c%=-1
  2622. 99,"MenuMaker offset not found.."
  2623. 1 b%=!_EVNTS_CLICKMENU_ANCHOR%
  2624. b%+=c%
  2625. !_EVNTS_CLICKMENU_DATA%=0
  2626. 5:!_EVNTS_CLICKMENU_DATA%=
  2627. shell_HeapBlockFetch(
  2628. (a$)+1)
  2629. p%=b%+20
  2630. Evnts_UpdateData(p%,_EVNTS_CLICKMENU_DATA%,_EVNTS_CLICKMENU_DATAOFFSET%,a$)
  2631. =$*|Stop PROCshell_AttachMenuMaker
  2632. I#*|Start PROCshell_AttachHelpTag
  2633. shell_AttachHelpTag(e%,h%,W$)
  2634. c%,b%,A$
  2635. M%A$=
  2636. shell_GetWindowIdentifier(e%)
  2637. A$="iconbar"
  2638. P    h%=-1
  2639. SXc%=
  2640. Evnts_GetEvntListOffset(A$,h%,_EVNTS_HELPTAG_ANCHOR%,_EVNTS_HELPTAG_REC_SIZE%,
  2641. b%=!_EVNTS_HELPTAG_ANCHOR%
  2642. b%+=c%
  2643. $b%=A$
  2644. b%!&C=h%
  2645. !_EVNTS_HELPTAG_DATA%=0
  2646. Z8!_EVNTS_HELPTAG_DATA%=
  2647. shell_HeapBlockFetch(
  2648. (W$)+1)
  2649. p%=b%+16
  2650. Evnts_UpdateData(p%,_EVNTS_HELPTAG_DATA%,_EVNTS_HELPTAG_DATAOFFSET%,W$)
  2651. b"*|Stop PROCshell_AttachHelpTag
  2652. f)*|Start PROCshell_EvntHandle_HelpTags
  2653. shell_EvntHandle_HelpTags(_window_handle%,_icon_handle%,
  2654. A$,c%,k%,jC%,kC%,oE%
  2655. o%,PG%,f%,XJ%,b%
  2656. k2A$=
  2657. shell_GetWindowIdentifier(_window_handle%)
  2658. A$="iconbar"
  2659. _icon_handle%=-1
  2660. qcc%=
  2661. Evnts_GetEvntListOffset(A$,_icon_handle%,_EVNTS_HELPTAG_ANCHOR%,_EVNTS_HELPTAG_REC_SIZE%,
  2662. c%>=0
  2663. t)W$=
  2664. shell_EvntHandle_AttachedHelp(c%)
  2665. y!oE%=
  2666. shell_HeapBlockFetch(96)
  2667. &600F4,1,oE%,_window_handle%,_icon_handle%
  2668. o%<>1
  2669. _window_handle%<>
  2670. shell_GetDynamicWindowHandle
  2671. shell_WindowHandleKnown(_window_handle%)
  2672. shell_EvntHandle_MenuHelp(oE%)
  2673. shell_HeapBlockReturn(oE%)
  2674. (*|Stop PROCshell_EvntHandle_HelpTags
  2675. "*|Start PROCshell_ListHelpTags
  2676. shell_ListHelpTags
  2677. EA%,n%,BA%,f%,OA%,mB%,B$
  2678. h%,IA%,q%
  2679. n%=!_EVNTS_HELPTAG_ANCHOR%
  2680.  BA%=_EVNTS_HELPTAG_REC_SIZE%
  2681. OA%=n%!4
  2682. Evnts_DebugListHeader ("HelpTag ","Window         Icon   Help tag")
  2683. f%=_EVNTS_HEADER_SIZE%
  2684. A$=$(n%+f%)
  2685. h%=n%!(f%+&C)
  2686. IA%=!_EVNTS_HELPTAG_DATA%
  2687. IA%>0
  2688. B$=$(IA%+n%!(f%+16))
  2689.  f%+=_EVNTS_HELPTAG_REC_SIZE%
  2690. !*|Stop PROCshell_ListHelpTags
  2691. '*|Start PROCshell_AttachMenuHelpTag
  2692. shell_AttachMenuHelpTag(wA$,MI%,M$)
  2693. c%,b%,p%
  2694. Evnts_GetEvntListOffset("menu",MI%,_EVNTS_MENUHELPTAG_ANCHOR%,_EVNTS_MENUHELPTAG_REC_SIZE%,
  2695. "b%=!_EVNTS_MENUHELPTAG_ANCHOR%
  2696. b%+=c%
  2697. $b%="menu"
  2698. b%!&C=MI%
  2699. !_EVNTS_MENUHELPTAG_DATA%=0
  2700. <!_EVNTS_MENUHELPTAG_DATA%=
  2701. shell_HeapBlockFetch(
  2702. (M$)+1)
  2703. p%=b%+16
  2704. Evnts_UpdateData(p%,_EVNTS_MENUHELPTAG_DATA%,_EVNTS_MENUHELPTAG_DATAOFFSET%,M$)
  2705. &*|Stop PROCshell_AttachMenuHelpTag
  2706.  *|Start PROCshell_AttachPane
  2707. shell_AttachPane(e%,
  2708. xD%,o%,BB%,CB%)
  2709. c%,b%,zA%,A$,b$,lC%
  2710. shell_GetWindowIdentifier(e%)
  2711. shell_GetWindowIdentifier(xD%)
  2712.     zA%=0
  2713. "lC%=
  2714. shell_WindowGetFlags(xD%)
  2715. 1<<5)=0
  2716. shell_WindowToggleFlags(xD%,1<<5)
  2717. 1<<1)
  2718. shell_WindowToggleFlags(xD%,1<<1)
  2719. Evnts_GetEvntListOffset(A$,zA%,_EVNTS_PANES_ANCHOR%,_EVNTS_PANES_REC_SIZE%,
  2720. zA%+=1
  2721. Evnts_GetEvntListOffset(A$,zA%,_EVNTS_PANES_ANCHOR%,_EVNTS_PANES_REC_SIZE%,
  2722. b%=!_EVNTS_PANES_ANCHOR%
  2723. b%+=c%
  2724. $b%=A$
  2725. b%!&C=zA%
  2726. b%!20=o%
  2727. b%!24=BB%
  2728. b%!28=CB%
  2729. !_EVNTS_PANES_DATA%=0
  2730. 6!_EVNTS_PANES_DATA%=
  2731. shell_HeapBlockFetch(
  2732. (b$)+1)
  2733. p%=b%+16
  2734. Evnts_UpdateData(p%,_EVNTS_PANES_DATA%,_EVNTS_PANES_DATAOFFSET%,b$)
  2735. *|Stop PROCshell_AttachPane
  2736. *|Start PROCshell_ListPanes
  2737. shell_ListPanes
  2738. EA%,n%,BA%,f%,OA%,b$
  2739. IA%,q%,cB$,JB$
  2740. n%=!_EVNTS_PANES_ANCHOR%
  2741. BA%=_EVNTS_PANES_REC_SIZE%
  2742. OA%=n%!4
  2743. Evnts_DebugListHeader ("Pane ","Window         Pane name   X Pos   Y Pos")
  2744. f%=_EVNTS_HEADER_SIZE%
  2745. A$=$(n%+f%)
  2746. IA%=!_EVNTS_PANES_DATA%
  2747. IA%>0
  2748. b$=$(IA%+n%!(f%+16))
  2749. 5cB$=
  2750. shell_StringPadTrailing(
  2751. (n%!(f%+24))," ",8)
  2752. 5JB$=
  2753. shell_StringPadTrailing(
  2754. (n%!(f%+28))," ",6)
  2755. f%+=_EVNTS_PANES_REC_SIZE%
  2756. *|Stop PROCshell_ListPanes
  2757. /(*|Start PROCshell_EvntAdd_WindowOpen
  2758. shell_EvntAdd_WindowOpen(A$,B$)
  2759. c%,b%
  2760. 25c%=
  2761. Evnts_GetEvntListOffset(A$,-1,"WINDOWOPEN",
  2762. 3!b%=!_EVNTS_WINDOWOPEN_ANCHOR%
  2763. b%+=c%
  2764. $b%=A$
  2765. b%!&C=-1
  2766. !_EVNTS_WINDOWOPEN_DATA%=0
  2767. 9;!_EVNTS_WINDOWOPEN_DATA%=
  2768. shell_HeapBlockFetch(
  2769. (B$)+1)
  2770. p%=b%+16
  2771. Evnts_UpdateData(p%,_EVNTS_WINDOWOPEN_DATA%,_EVNTS_WINDOWOPEN_DATAOFFSET%,B$)
  2772. A'*|Stop PROCshell_EvntAdd_WindowOpen
  2773. E *|Start PROCshell_OpenWindow
  2774. shell_OpenWindow(_window_handle%,cF%,JD%)
  2775. c%,UH%,QB%,oA%,HB%
  2776. mC%,zG%,TH%
  2777. A$,k%,JA%,x%
  2778. B$,j%,zA%,rE%,lC%,nC%
  2779. LD%,HA%,MD%
  2780. M2A$=
  2781. shell_GetWindowIdentifier(_window_handle%)
  2782. QB%=_Q%!28
  2783. P^c%=
  2784. Evnts_GetEvntListOffset(A$,-1,_EVNTS_WINDOWOPEN_ANCHOR%,_EVNTS_WINDOWOPEN_REC_SIZE%,
  2785. c%>=0
  2786. S$k%=!_EVNTS_WINDOWOPEN_ANCHOR%+c%
  2787. JA%=k%!16
  2788. x%=!_EVNTS_WINDOWOPEN_DATA%
  2789. B$=$(x%+JA%)
  2790. ("FN"+B$+"("+A$+")")
  2791. Z    mC%=
  2792. [,_WINDOWS_GETSTATE_BLK%!0=_window_handle%
  2793. &400CB,,_WINDOWS_GETSTATE_BLK%
  2794. (_WINDOWS_GETSTATE_BLK%!32
  2795. &80000)=&80000
  2796. &400CF,,_WINDOWS_GETPINFO_BLK%
  2797. _Q%!0=_window_handle%
  2798. &400CB,,_Q%
  2799. &400C5,,_Q%
  2800. h    rE%=
  2801. iUc%=
  2802. Evnts_GetEvntListOffset(A$,zA%,_EVNTS_PANES_ANCHOR%,_EVNTS_PANES_REC_SIZE%,
  2803. c%>=0
  2804. _Q%!0=_window_handle%
  2805. JD%>0
  2806. QB%=JD%
  2807. QB%=-1
  2808. QB%=_Q%!28
  2809. &400C5,,_Q%
  2810. &400CB,,_Q%
  2811. &400C6,,_Q%
  2812. |    zA%=0
  2813. Evnts_GetEvntListOffset(A$,zA%,_EVNTS_PANES_ANCHOR%,_EVNTS_PANES_REC_SIZE%,
  2814. c%=GE%
  2815. k%=!_EVNTS_PANES_ANCHOR%+c%
  2816. wD%=k%!16
  2817. x%=!_EVNTS_PANES_DATA%
  2818. b$=$(x%+wD%)
  2819. lC%=k%!20
  2820. nC%=k%!24
  2821. LD%=k%!28
  2822. &HA%=
  2823. shell_GetWindowHandleList(b$)
  2824. MD%=!HA%
  2825. _EVNTS_PANE_BLK%!0=MD%
  2826. UH%=0
  2827. UH%=_EVNTS_PANE_BLK%!0
  2828. zG%=_EVNTS_PANE_BLK%!0
  2829. &400CB,,_EVNTS_PANE_BLK%
  2830. _WINDOWS_GETPINFO_BLK%!16=-9
  2831. _WINDOWS_GETPINFO_BLK%!16>-5
  2832. .oA%=_EVNTS_PANE_BLK%!16-_EVNTS_PANE_BLK%!8
  2833. .HB%=_EVNTS_PANE_BLK%!&C-_EVNTS_PANE_BLK%!4
  2834.  _EVNTS_PANE_BLK%!4=_Q%!4+nC%
  2835. ._EVNTS_PANE_BLK%!&C=_EVNTS_PANE_BLK%!4+HB%
  2836. "_EVNTS_PANE_BLK%!16=_Q%!16+LD%
  2837. ._EVNTS_PANE_BLK%!8=_EVNTS_PANE_BLK%!16-oA%
  2838. .oA%=_EVNTS_PANE_BLK%!16-_EVNTS_PANE_BLK%!8
  2839. HB%=_Q%!&C-_Q%!4
  2840.  _EVNTS_PANE_BLK%!4=_Q%!4+nC%
  2841. _EVNTS_PANE_BLK%!&C=_Q%!&C
  2842. "_EVNTS_PANE_BLK%!16=_Q%!16+LD%
  2843. ._EVNTS_PANE_BLK%!8=_EVNTS_PANE_BLK%!16-oA%
  2844. oA%=_Q%!16-_Q%!8
  2845. .HB%=_EVNTS_PANE_BLK%!&C-_EVNTS_PANE_BLK%!4
  2846.  _EVNTS_PANE_BLK%!4=_Q%!4+nC%
  2847. ._EVNTS_PANE_BLK%!&C=_EVNTS_PANE_BLK%!4+HB%
  2848. _EVNTS_PANE_BLK%!16=_Q%!16
  2849.  _EVNTS_PANE_BLK%!8=_Q%!8+LD%
  2850. .oA%=_EVNTS_PANE_BLK%!16-_EVNTS_PANE_BLK%!8
  2851. HB%=_Q%!&C-_Q%!4
  2852.  _EVNTS_PANE_BLK%!4=_Q%!4+nC%
  2853. _EVNTS_PANE_BLK%!&C=_Q%!&C
  2854. %_EVNTS_PANE_BLK%!16=_Q%!8+oA%+LD%
  2855. ._EVNTS_PANE_BLK%!8=_EVNTS_PANE_BLK%!16+oA%
  2856. oA%=_Q%!16-_Q%!8
  2857. .HB%=_EVNTS_PANE_BLK%!&C-_EVNTS_PANE_BLK%!4
  2858. %_EVNTS_PANE_BLK%!4=_Q%!&C-HB%+nC%
  2859. ._EVNTS_PANE_BLK%!&C=_EVNTS_PANE_BLK%!4+HB%
  2860. _EVNTS_PANE_BLK%!16=_Q%!16
  2861. _EVNTS_PANE_BLK%!8=_Q%!8
  2862. zA%=0
  2863. _EVNTS_PANE_BLK%!28=QB%
  2864. _EVNTS_PANE_BLK%!28=TH%
  2865. &400C5,,_EVNTS_PANE_BLK%
  2866. TH%=_EVNTS_PANE_BLK%!0
  2867. zA%+=1
  2868. _Q%!28=zG%
  2869. &400C5,,_Q%
  2870. _Q%!0=_window_handle%
  2871. &400CB,,_Q%
  2872. QB%=-2
  2873. _Q%!28=-2
  2874. JD%=-1
  2875. _Q%!28=-1
  2876. &400C5,,_Q%
  2877. *|Stop PROCshell_OpenWindow
  2878. )*|Start PROCshell_EvntAdd_WindowClose
  2879. shell_EvntAdd_WindowClose(A$,B$)
  2880. c%,b%
  2881. Evnts_GetEvntListOffset(A$,-1,_EVNTS_WINDOWCLOSE_ANCHOR%,_EVNTS_WINDOWCLOSE_REC_SIZE%,
  2882. "b%=!_EVNTS_WINDOWCLOSE_ANCHOR%
  2883. b%+=c%
  2884. $b%=A$
  2885. b%!&C=-1
  2886. !_EVNTS_WINDOWCLOSE_DATA%=0
  2887. <!_EVNTS_WINDOWCLOSE_DATA%=
  2888. shell_HeapBlockFetch(
  2889. (B$)+1)
  2890. p%=b%+16
  2891. Evnts_UpdateData(p%,_EVNTS_WINDOWCLOSE_DATA%,_EVNTS_WINDOWCLOSE_DATAOFFSET%,B$)
  2892. (*|Stop PROCshell_EvntAdd_WindowClose
  2893. ,*|Start PROCshell_EvntHandle_WindowClose
  2894. shell_EvntHandle_WindowOpen(_window_handle%)
  2895. c%,j%,k%,JA%,x%
  2896. Evnts_GetEvntListOffset(A$,-1,"WINDOWCLOSE",
  2897. c%>=0
  2898. %k%=!_EVNTS_WINDOWCLOSE_ANCHOR%+c%
  2899. JA%=k%!16
  2900.  x%=!_EVNTS_WINDOWCLOSE_DATA%
  2901. B$=$(x%+JA%)
  2902. ("FN"+B$+"(_window_handle%)")
  2903.     +*|Stop PROCshell_EvntHandle_WindowClose
  2904. $ *|Start PROCshell_AttachDrag
  2905. shell_AttachDrag(e%,h%,B$)
  2906. c%,b%,p%,A$
  2907. (%A$=
  2908. shell_GetWindowIdentifier(e%)
  2909. )/c%=
  2910. Evnts_GetEvntListOffset(A$,h%,"DRAG",
  2911. b%=!_EVNTS_DRAG_ANCHOR%
  2912. b%+=c%
  2913. $b%=A$
  2914. b%!&C=h%
  2915. !_EVNTS_DRAG_DATA%=0
  2916. 05!_EVNTS_DRAG_DATA%=
  2917. shell_HeapBlockFetch(
  2918. (B$)+1)
  2919. p%=b%+16
  2920. Evnts_UpdateData(p%,_EVNTS_DRAG_DATA%,_EVNTS_DRAG_DATAOFFSET%,B$)
  2921. *|Stop PROCshell_AttachDrag
  2922. C&*|Start PROCshell_AttachUserRedraw
  2923. shell_AttachUserRedraw(
  2924. e%,B$)
  2925. c%,b%,p%,d%,eA%
  2926. G d%=
  2927. shell_HeapBlockFetch(36)
  2928. !d%=e%
  2929. &400CB,,d%
  2930. eA%=d%!32
  2931. shell_HeapBlockReturn(d%)
  2932. shell_Tracef0("AttachUserRedraw:flag% = &"+
  2933. ~eA%)
  2934. 1<<4)
  2935. shell_Tracef0("AttachUserRedraw:auto redraw set!!")
  2936. shell_WindowToggleFlags(e%,1<<4)
  2937. R%A$=
  2938. shell_GetWindowIdentifier(e%)
  2939. shell_Tracef0("AttachUserRedraw:window name is : "+A$)
  2940. TVc%=
  2941. Evnts_GetEvntListOffset(A$,-1,_EVNTS_REDRAW_ANCHOR%,_EVNTS_REDRAW_REC_SIZE%,
  2942. b%=!_EVNTS_REDRAW_ANCHOR%
  2943. b%+=c%
  2944. $b%=A$
  2945. b%!&C=-1
  2946. !_EVNTS_REDRAW_DATA%=0
  2947. [7!_EVNTS_REDRAW_DATA%=
  2948. shell_HeapBlockFetch(
  2949. (B$)+1)
  2950. p%=b%+16
  2951. Evnts_UpdateData(p%,_EVNTS_REDRAW_DATA%,_EVNTS_REDRAW_DATAOFFSET%,B$)
  2952. c%*|Stop PROCshell_AttachUserRedraw
  2953. g'*|Start PROCshell_EvntHandle_Redraw
  2954. shell_EvntHandle_Redraw(_window_handle%,d%,XA%,aA%)
  2955. A$,c%,B$,k%,x%,j%
  2956. j2A$=
  2957. shell_GetWindowIdentifier(_window_handle%)
  2958. kVc%=
  2959. Evnts_GetEvntListOffset(A$,-1,_EVNTS_REDRAW_ANCHOR%,_EVNTS_REDRAW_REC_SIZE%,
  2960. c%>=0
  2961. n k%=!_EVNTS_REDRAW_ANCHOR%+c%
  2962. JA%=k%!16
  2963. x%=!_EVNTS_REDRAW_DATA%
  2964. B$=$(x%+JA%)
  2965. B$<>""
  2966. u/j%=
  2967. ("FN"+B$+"("+
  2968. d%+","+
  2969. XA%+","+
  2970. aA%+")")
  2971. {&*|Stop PROCshell_EvntHandle_Redraw
  2972.  *|Start PROCshell_ListRedraw
  2973. shell_ListRedraw
  2974. EA%,n%,BA%,f%,OA%,B$,A$
  2975. IA%,q%
  2976. n%=!_EVNTS_REDRAW_ANCHOR%
  2977. BA%=_EVNTS_REDRAW_REC_SIZE%
  2978. OA%=n%!4
  2979. Evnts_DebugListHeader ("Redraw ","Window       User FN")
  2980. f%=_EVNTS_HEADER_SIZE%
  2981. A$=$(n%+f%)
  2982. IA%=!_EVNTS_REDRAW_DATA%
  2983. IA%>0
  2984. B$=$(IA%+n%!(f%+16))
  2985. f%+=_EVNTS_REDRAW_REC_SIZE%
  2986. *|Stop PROCshell_ListRedraw
  2987. %*|Start PROCshell_AttachIconWatch
  2988. shell_AttachIconWatch(e%,h%,B$)
  2989. c%,b%,p%,A$,c$
  2990. shell_GetWindowIdentifier(e%)
  2991. Evnts_GetEvntListOffset(A$,h%,_EVNTS_ICONWATCH_ANCHOR%,_EVNTS_ICONWATCH_REC_SIZE%,
  2992.  b%=!_EVNTS_ICONWATCH_ANCHOR%
  2993. b%+=c%
  2994. $b%=A$
  2995. b%!&C=h%
  2996. !_EVNTS_ICONWATCH_DATA%=0
  2997. :!_EVNTS_ICONWATCH_DATA%=
  2998. shell_HeapBlockFetch(
  2999. (B$)+1)
  3000. p%=b%+16
  3001. Evnts_UpdateData(p%,_EVNTS_ICONWATCH_DATA%,_EVNTS_ICONWATCH_DATAOFFSET%,B$)
  3002. shell_IconGetData(e%,h%)
  3003. p%=b%+20
  3004. Evnts_UpdateData(p%,_EVNTS_ICONWATCH_DATA%,_EVNTS_ICONWATCH_DATAOFFSET%,c$)
  3005. $*|Stop PROCshell_AttachIconWatch
  3006. **|Start PROCshell_EvntHandle_IconWatch
  3007. shell_EvntHandle_IconWatch
  3008. k%,BA%,VA%,f%,q%,h%,A$,lG%
  3009. HA%,e%,c$,AB$,B$,JA%
  3010. x%,p%
  3011.  k%=!_EVNTS_ICONWATCH_ANCHOR%
  3012. "BA%=_EVNTS_ICONWATCH_REC_SIZE%
  3013. VA%=k%!4
  3014. f%=_EVNTS_HEADER_SIZE%
  3015. A$=$(k%+f%)
  3016. h%=k%!(f%+&C)
  3017. JA%=k%!(f%+16)
  3018. x%=!_EVNTS_ICONWATCH_DATA%
  3019. B$=$(x%+JA%)
  3020. lG%=!(k%+f%+20)
  3021. p%=k%+f%+20
  3022. AB$=$(x%+lG%)
  3023. &HA%=
  3024. shell_GetWindowHandleList(A$)
  3025. e%=!HA%
  3026. shell_WindowIsOpen(e%)=
  3027. shell_IconGetData(e%,h%)
  3028. c$=""
  3029. c$="0"
  3030. B$<>""
  3031. c$<>AB$
  3032. ("FN"+B$+"( "+
  3033. (34)+c$+
  3034. (34)+" )")
  3035. Evnts_UpdateData(p%,_EVNTS_ICONWATCH_DATA%,_EVNTS_ICONWATCH_DATAOFFSET%,c$)
  3036. "f%+=_EVNTS_ICONWATCH_REC_SIZE%
  3037. )*|Stop PROCshell_EvntHandle_IconWatch
  3038. #*|Start PROCshell_ListIconWatch
  3039. shell_ListIconWatch
  3040. EA%,n%,BA%,f%,OA%,B$,A$
  3041. IA%,q%
  3042.  n%=!_EVNTS_ICONWATCH_ANCHOR%
  3043. "BA%=_EVNTS_ICONWATCH_REC_SIZE%
  3044. OA%=n%!4
  3045. Evnts_DebugListHeader ("IconWatch ","Window       User FN")
  3046. f%=_EVNTS_HEADER_SIZE%
  3047. A$=$(n%+f%)
  3048. IA%=!_EVNTS_ICONWATCH_DATA%
  3049. IA%>0
  3050. B$=$(IA%+n%!(f%+16))
  3051. "f%+=_EVNTS_ICONWATCH_REC_SIZE%
  3052. "*|Stop PROCshell_ListIconWatch
  3053. $*|Start PROCshell_AttachUserDrag
  3054. shell_AttachUserDrag(e%,h%,B$)
  3055. c%,b%,p%,A$,c$
  3056. shell_GetWindowIdentifier(e%)
  3057. Evnts_GetEvntListOffset(A$,h%,_EVNTS_DRAG_ANCHOR%,_EVNTS_DRAG_REC_SIZE%,
  3058. b%=!_EVNTS_DRAG_ANCHOR%
  3059. b%+=c%
  3060. $b%=A$
  3061. b%!&C=h%
  3062. !_EVNTS_DRAG_DATA%=0
  3063. #5!_EVNTS_DRAG_DATA%=
  3064. shell_HeapBlockFetch(
  3065. (B$)+1)
  3066. p%=b%+16
  3067. Evnts_UpdateData(p%,_EVNTS_DRAG_DATA%,_EVNTS_DRAG_DATAOFFSET%,B$)
  3068. +#*|Stop PROCshell_AttachUserDrag
  3069. /2*|Start PROCshell_EvntHandle_UserDragStartDrag
  3070. shell_EvntHandle_UserDragStartDrag(e%,h%)
  3071. JA%,x%,A$,c%
  3072. 4%A$=
  3073. shell_GetWindowIdentifier(e%)
  3074. 5Rc%=
  3075. Evnts_GetEvntListOffset(A$,h%,_EVNTS_DRAG_ANCHOR%,_EVNTS_DRAG_REC_SIZE%,
  3076. c%>=0
  3077. shell_IconDragBox2(e%,h%)
  3078. ;$_m_evnts_DragIconStartWindow%=e%
  3079. <"_m_evnts_DragIconStartIcon%=h%
  3080. shell_IconIsWritable(e%,h%)
  3081. shell_IconDragBox2(e%,h%)
  3082. D$_m_evnts_DragIconStartWindow%=e%
  3083. E"_m_evnts_DragIconStartIcon%=h%
  3084. F$_m_evnts_DragIconWritableDrag%=
  3085. L1*|Stop PROCshell_EvntHandle_UserDragStartDrag
  3086. P,*|Start PROCshell_EvntHandle_UserDragEnd
  3087. shell_EvntHandle_UserDragEnd
  3088. bA%,A$,c%,k%,JA%,x%
  3089. j%,B$,NA$,oA$
  3090. V@A$=
  3091. shell_GetWindowIdentifier(_m_evnts_DragIconStartWindow%)
  3092. Wkc%=
  3093. Evnts_GetEvntListOffset(A$,_m_evnts_DragIconStartIcon%,_EVNTS_DRAG_ANCHOR%,_EVNTS_DRAG_REC_SIZE%,
  3094. [!bA%=
  3095. shell_HeapBlockFetch(30)
  3096. &400CF,,bA%
  3097. _m_evnts_MouseXCoord%=bA%!0
  3098. _m_evnts_MouseYCoord%=bA%!4
  3099. _%_m_evnts_DestWindowHandle%=bA%!&C
  3100. `#_m_evnts_DestIconHandle%=bA%!16
  3101. shell_HeapBlockReturn(bA%)
  3102. c%>=0
  3103. k%=!_EVNTS_DRAG_ANCHOR%+c%
  3104. JA%=k%!16
  3105. x%=!_EVNTS_DRAG_DATA%
  3106. B$=$(x%+JA%)
  3107. ("FN"+B$+"("+
  3108. _m_evnts_DestTaskHandle%+","+
  3109. _m_evnts_DestWindowHandle%+","+
  3110. _m_evnts_DestIconHandle%+","+
  3111. _m_evnts_MouseXCoord%+","+
  3112. _m_evnts_MouseYCoord%+")")
  3113. _m_evnts_DragIconWritableDrag%=
  3114. k$_m_evnts_DragIconWritableDrag%=
  3115. shell_IconIsWritable(_m_evnts_DestWindowHandle%,_m_evnts_DestIconHandle%)
  3116. shell_WindowHandleKnown(_m_evnts_DestWindowHandle%)
  3117. mUNA$=
  3118. shell_IconGetData(_m_evnts_DragIconStartWindow%,_m_evnts_DragIconStartIcon%)
  3119. nOoA$=
  3120. shell_IconGetData(_m_evnts_DestWindowHandle%,_m_evnts_DestIconHandle%)
  3121. shell_IconPutData(_m_evnts_DestWindowHandle%,_m_evnts_DestIconHandle%,NA$,
  3122. shell_IconPutData(_m_evnts_DestWindowHandle%,_m_evnts_DestIconHandle%,oA$+NA$,
  3123. z+*|Stop PROCshell_EvntHandle_UserDragEnd
  3124. '*|Start PROCshell_EvntAdd_PopUpMenu
  3125. shell_EvntAdd_PopUpMenu(A$,xB%,WA%,s%,R$,V$,yD%)
  3126. c%,b%
  3127. Evnts_GetEvntListOffset(A$,xB%,_EVNTS_POPUPS_ANCHOR%,_EVNTS_POPUPS_REC_SIZE%,
  3128. b%=!_EVNTS_POPUPS_ANCHOR%
  3129. b%+=c%
  3130. $b%=A$
  3131. b%!&C=xB%
  3132. b%!20=WA%
  3133. b%!24=yD%
  3134. b%!28=s%
  3135. R$<>""
  3136. !_EVNTS_POPUPS_DATA%=0
  3137. 7!_EVNTS_POPUPS_DATA%=
  3138. shell_HeapBlockFetch(
  3139. (R$)+1)
  3140. p%=b%+16
  3141. Evnts_UpdateData(p%,_EVNTS_POPUPS_DATA%,_EVNTS_POPUPS_DATAOFFSET%,R$)
  3142. b%!16=-1
  3143. V$<>""
  3144. !_EVNTS_POPUPS_DATA%=0
  3145. 7!_EVNTS_POPUPS_DATA%=
  3146. shell_HeapBlockFetch(
  3147. (V$)+1)
  3148. p%=b%+32
  3149. Evnts_UpdateData(p%,_EVNTS_POPUPS_DATA%,_EVNTS_POPUPS_DATAOFFSET%,V$)
  3150. b%!32=-1
  3151. &*|Stop PROCshell_EvntAdd_PopUpMenu
  3152. **|Start PROCshell_EvntHandle_PopupMenu
  3153. shell_EvntHandle_PopupMenu(_window_handle%,_icon_handle%)
  3154. A$,c%,x%,RA%,k%,OC%,s%
  3155. EK%,R$,V$,j%
  3156. shell_GetWindowIdentifier(_window_handle%)
  3157. Evnts_GetEvntListOffset(A$,_icon_handle%,_EVNTS_POPUPS_ANCHOR%,_EVNTS_POPUPS_REC_SIZE%,
  3158. c%>=0
  3159.  k%=!_EVNTS_POPUPS_ANCHOR%+c%
  3160. RA%=k%!16
  3161. x%=!_EVNTS_POPUPS_DATA%
  3162. xB%=k%!&C
  3163. WA%=k%!20
  3164. OC%=k%!24
  3165. s%=k%!28
  3166. RA%>=0
  3167. R$=$(x%+RA%)
  3168. RA%=k%!32
  3169. RA%>=0
  3170. V$=$(x%+RA%)
  3171. s%=_POPUP_TYPE_FONTMENU
  3172. ("FN"+V$+"("+
  3173. shell_FontMenu_GetHandle)+")")
  3174. ("FN"+V$+"("+
  3175. (s%)+")")
  3176. _POPUP_TYPE_TEXT
  3177. shell_HandleMenuOpen(_Q%,s%,_window_handle%,_icon_handle%,
  3178. _POPUP_TYPE_WIMPCOLOUR
  3179. shell_HandleMenuOpen(_Q%,s%,_window_handle%,_icon_handle%,
  3180. _POPUP_TYPE_COLOUR24
  3181. shell_ColourPickerOpen(_window_handle%,WA%,xB%,R$,V$)
  3182. _POPUP_TYPE_FONTMENU
  3183. shell_FontMenu_ShowMenu(_Q%,s%,_window_handle%,_icon_handle%,
  3184. _POPUP_TYPE_FONTPICK
  3185. shell_FontPickerOpen(_window_handle%,WA%,xB%,R$,V$)
  3186. _POPUP_TYPE_DATEPICK
  3187. shell_DatePickerOpen(_window_handle%,WA%,xB%,R$)
  3188. 99,"Unknown popup type detected!"
  3189. )*|Stop PROCshell_EvntHandle_PopupMenu
  3190. 3*|Start PROCshell_EvntHandle_PopupMenuSelection
  3191. shell_EvntHandle_PopupMenuSelection(e%,h%,nB%)
  3192. _item_text$,A$,c%,k%,RA%,x%
  3193. xB%,WA%,OC%,s%,t%,Y$
  3194. shell_GetWindowIdentifier(e%)
  3195. Evnts_GetEvntListOffset(A$,h%,_EVNTS_POPUPS_ANCHOR%,_EVNTS_POPUPS_REC_SIZE%,
  3196. c%>=0
  3197.  k%=!_EVNTS_POPUPS_ANCHOR%+c%
  3198. RA%=k%!16
  3199. x%=!_EVNTS_POPUPS_DATA%
  3200. xB%=k%!&C
  3201. WA%=k%!20
  3202. OC%=k%!24
  3203. s%=k%!28
  3204. OC%=_POPUP_TYPE_FONTMENU
  3205. _item_text$=""
  3206. /_item_text$=
  3207. shell_MenuGetItemText(s%,!nB%)
  3208. RA%<>-1
  3209. Y$=$(x%+RA%)
  3210. ("FN"+Y$+"("+
  3211. e%+","+
  3212. WA%+",_item_text$)")
  3213. t%<>0
  3214. RA%=-1
  3215. WA%>=0
  3216. _POPUP_TYPE_TEXT
  3217. shell_IconPutData(e%,WA%,_item_text$,
  3218. _POPUP_TYPE_WIMPCOLOUR
  3219. shell_IconSetBGColour(e%,WA%,nB%)
  3220. 99,"Unknown Popup type in EvntHandle_PopupMenuSelection (type was "+
  3221. OC%+")"
  3222. B2*|Stop PROCshell_EvntHandle_PopupMenuSelection
  3223. F *|Start PROCshell_ListPopUps
  3224. shell_ListPopUps
  3225. EA%,n%,BA%,f%,OA%,mB%
  3226. h%,B$,IA%,q%
  3227. n%=!_EVNTS_POPUPS_ANCHOR%
  3228. BA%=_EVNTS_POPUPS_REC_SIZE%
  3229. OA%=n%!4
  3230. Evnts_DebugListHeader ("PopUps","Window         Icon   FN")
  3231. f%=_EVNTS_HEADER_SIZE%
  3232. A$=$(n%+f%)
  3233. h%=n%!(f%+&C)
  3234. IA%=!_EVNTS_POPUPS_DATA%
  3235. IA%>0
  3236. B$=$(IA%+n%!(f%+16))
  3237. f%+=_EVNTS_POPUPS_REC_SIZE%
  3238. *|Stop PROCshell_ListPopUps
  3239. l-*|Start PROCshell_EvntSelectButtonPressed
  3240. shell_EvntSelectButtonPressed(e%,h%,UI%)
  3241. shell_EvntHandle_ClickSelect(e%,h%)
  3242. s,*|Stop PROCshell_EvntSelectButtonPressed
  3243. w-*|Start PROCshell_EvntAdjustButtonPressed
  3244. shell_EvntAdjustButtonPressed(e%,h%)
  3245. shell_EvntHandle_ClickAdjust(e%,h%)
  3246. ~,*|Stop PROCshell_EvntAdjustButtonPressed
  3247. +*|Start PROCshell_EvntMenuButtonPressed
  3248. shell_EvntMenuButtonPressed(e%,h%,UI%)
  3249. shell_EvntHandle_ClickMenu(e%,h%)
  3250. **|Stop PROCshell_EvntMenuButtonPressed
  3251. '*|Start PROCshell_EvntSave_AllEvnts
  3252. shell_EvntSave_AllEvnts(PA$)
  3253. (PA$)
  3254. Evnts_SaveEvnt(u%,_EVNTS_CLICKSELECT_ANCHOR%,_EVNTS_CLICKSELECT_DATA%,_EVNTS_CLICKSELECT_DATAOFFSET%)
  3255. Evnts_SaveEvnt(u%,_EVNTS_CLICKADJUST_ANCHOR%,_EVNTS_CLICKADJUST_DATA%,_EVNTS_CLICKADJUST_DATAOFFSET%)
  3256. Evnts_SaveEvnt(u%,_EVNTS_CLICKMENU_ANCHOR%,_EVNTS_CLICKMENU_DATA%,_EVNTS_CLICKMENU_DATAOFFSET%)
  3257. Evnts_SaveEvnt(u%,_EVNTS_HELPTAG_ANCHOR%,_EVNTS_HELPTAG_DATA%,_EVNTS_HELPTAG_DATAOFFSET%)
  3258. shell_PointerSaveEvnts(u%)
  3259. Evnts_SaveEvnt(u%,_EVNTS_REDRAW_ANCHOR%,_EVNTS_REDRAW_DATA%,_EVNTS_REDRAW_DATAOFFSET%)
  3260. &*|Stop PROCshell_EvntSave_AllEvnts
  3261. *|Start PROCEvnts_SaveEvnt
  3262. Evnts_SaveEvnt(u%,OD%,PD%,RA%)
  3263. b%,cA%,vA%
  3264. b%=!OD%
  3265. vA%=!PD%
  3266. !HE%=RA%
  3267. #u%,0
  3268. cA%=!b%
  3269. #u%,1
  3270. &C,2,u%,b%,cA%+_EVNTS_HEADER_SIZE%
  3271. &C,2,u%,HE%,4
  3272. &C,2,u%,vA%,RA%
  3273. *|Stop PROCEvnts_SaveEvnt
  3274. '*|Start PROCshell_EvntLoad_AllEvnts
  3275. shell_EvntLoad_AllEvnts(PA$)
  3276. (PA$)
  3277. Evnts_LoadEvnt(u%,_EVNTS_CLICKSELECT_ANCHOR%,_EVNTS_CLICKSELECT_DATA%,_EVNTS_CLICKSELECT_DATAOFFSET%)
  3278. Evnts_LoadEvnt(u%,_EVNTS_CLICKADJUST_ANCHOR%,_EVNTS_CLICKADJUST_DATA%,_EVNTS_CLICKADJUST_DATAOFFSET%)
  3279. Evnts_LoadEvnt(u%,_EVNTS_CLICKMENU_ANCHOR%,_EVNTS_CLICKMENU_DATA%,_EVNTS_CLICKMENU_DATAOFFSET%)
  3280. Evnts_LoadEvnt(u%,_EVNTS_HELPTAG_ANCHOR%,_EVNTS_HELPTAG_DATA%,_EVNTS_HELPTAG_DATAOFFSET%)
  3281. shell_PointerLoadEvnts(u%)
  3282. Evnts_LoadEvnt(u%,_EVNTS_REDRAW_ANCHOR%,_EVNTS_REDRAW_DATA%,_EVNTS_REDRAW_DATAOFFSET%)
  3283. &*|Stop PROCshell_EvntLoad_AllEvnts
  3284. *|Start PROCEvnts_LoadEvnt
  3285. Evnts_LoadEvnt(u%,OD%,PD%,
  3286. HH%,cA%,b%,cA%,kB%,vA%
  3287. !OD%<>0
  3288. shell_HeapBlockReturn(!OD%)
  3289. !PD%<>0
  3290. shell_HeapBlockReturn(!PD%)
  3291. HH%=1
  3292. shell_HeapBlockFetch(_EVNTS_HEADER_SIZE%)
  3293. &C,4,u%,b%,_EVNTS_HEADER_SIZE%
  3294. cA%=!b%
  3295. shell_HeapBlockExtend(b%,cA%)
  3296. &C,4,u%,b%+_EVNTS_HEADER_SIZE%,cA%
  3297. !OD%=b%
  3298. &C,4,u%,HE%,4
  3299. kB%=!HE%
  3300. kB%>0
  3301. "vA%=
  3302. shell_HeapBlockFetch(kB%)
  3303. &C,4,u%,vA%,kB%
  3304. !PD%=vA%
  3305. RA%=kB%
  3306. *|Stop PROCEvnts_LoadEvnt
  3307. +*|Start PROCshell_EvntHandle_MenuSelect
  3308. shell_EvntHandle_MenuSelect(PC%)
  3309. qF%,AE%,bA%,o%
  3310. !bA%=
  3311. shell_HeapBlockFetch(20)
  3312. &400CF,,bA%
  3313. "_EVNTS_LAST_MOUSEBUTTON%=bA%!8
  3314. shell_HeapBlockReturn(bA%)
  3315. shell_GetLastIconClicked>=0
  3316. shell_EvntHandle_PopupSelect(PC%)
  3317. "AE%=
  3318. shell_HeapBlockFetch(256)
  3319. &65BC4,_m_Menu_HandleLastOpened%,PC%
  3320. qF%,,AE%;o%
  3321. o%<>1
  3322. Evnts_CallMenuHandler(qF%,AE%)
  3323. shell_HeapBlockReturn(AE%)
  3324. shell_GetLastMouseButton=_MSE_ADJUSTBUT
  3325. _EVNTS_LAST_MENUMAKER_FN$<>""
  3326. "=j%=
  3327. ("FN"+_EVNTS_LAST_MENUMAKER_FN$+"( _U%!52, _U%!56 )")
  3328. shell_MenuOpenLast
  3329. ***|Stop PROCshell_EvntHandle_MenuSelect
  3330. .,*|Start PROCshell_EvntHandle_PopupSelect
  3331. shell_EvntHandle_PopupSelect(PC%)
  3332. A$,c%,k%,q$,s%,rF%
  3333. vA%,BE%,t%,Y$
  3334. WA%,TI%,SH%
  3335. 5>A$=
  3336. shell_GetWindowIdentifier(
  3337. shell_GetLastWindowClicked)
  3338. 6mc%=
  3339. Evnts_GetEvntListOffset(A$,
  3340. shell_GetLastIconClicked,_EVNTS_POPUPS_ANCHOR%,_EVNTS_POPUPS_REC_SIZE%,
  3341. c%>=0
  3342. 8 k%=!_EVNTS_POPUPS_ANCHOR%+c%
  3343. rF%=k%!24
  3344. s%=k%!28
  3345. vA%=!_EVNTS_POPUPS_DATA%
  3346. BE%=k%!16
  3347. WA%=k%!20
  3348. PC%!4<>-1
  3349. s%<>_POPUP_TYPE_FONTMENU
  3350. 99,"Unable to handle popup with submenus!"
  3351. s%=_POPUP_TYPE_FONTMENU
  3352. D"q$=
  3353. shell_FontMenu_Decode(PC%)
  3354. F&q$=
  3355. shell_MenuGetItemText(s%,!PC%)
  3356. BE%>-1
  3357. Y$=$(vA%+BE%)
  3358. q$<>""
  3359. OTt%=
  3360. ("FN"+Y$+"("+
  3361. shell_GetLastWindowClicked)+","+
  3362. WA%+","+
  3363. (34)+q$+
  3364. (34)+")")
  3365. t%<>0
  3366. BE%=-1
  3367. WA%>=0
  3368. _POPUP_TYPE_TEXT
  3369. shell_IconPutData(
  3370. shell_GetLastWindowClicked,WA%,q$,
  3371. _POPUP_TYPE_WIMPCOLOUR
  3372. shell_IconSetBGColour(
  3373. shell_GetLastWindowClicked,WA%,!PC%)
  3374. _POPUP_TYPE_FONTMENU
  3375. q$<>""
  3376. shell_IconPutData(
  3377. shell_GetLastWindowClicked,WA%,q$,
  3378. 99,"Unknown Popup type in PROCshell_EvntHandle_PopupSelect (type was "+
  3379. rF%+")"
  3380. j+*|Stop PROCshell_EvntHandle_PopupSelect
  3381. n%*|Start PROCEvnts_CallMenuHandler
  3382. Evnts_CallMenuHandler(y%,VI%)
  3383. ("FN"+$y%+"("+
  3384. VI%+")")
  3385. u$*|Stop PROCEvnts_CallMenuHandler
  3386. x!*|Start FNEvnts_GetHeaderSize
  3387. Evnts_GetHeaderSize
  3388. =_EVNTS_HEADER_SIZE%
  3389. | *|Stop FNEvnts_GetHeaderSize
  3390. &*|Start FNEvnts_GetLastMouseButton
  3391. Evnts_GetLastMouseButton
  3392. =_EVNTS_LAST_MOUSEBUTTON%
  3393. %*|Stop FNEvnts_GetLastMouseButton
  3394. &*|Start FNEvnts_GetLastIconClicked
  3395. Evnts_GetLastIconClicked
  3396. =_EVNTS_LAST_ICONCLICKED%
  3397. %*|Stop FNEvnts_GetLastIconClicked
  3398. (*|Start FNEvnts_GetLastWindowClicked
  3399. Evnts_GetLastWindowClicked
  3400. =_EVNTS_LAST_WINDOWCLICKED%
  3401. '*|Stop FNEvnts_GetLastWindowClicked
  3402. $*|Start FNEvnts_GetLastMouseXPos
  3403. Evnts_GetLastMouseXPos
  3404. =_EVNTS_LAST_MOUSEXPOS%
  3405. #*|Stop FNEvnts_GetLastMouseXPos
  3406. $*|Start FNEvnts_GetLastMouseYPos
  3407. Evnts_GetLastMouseYPos
  3408. =_EVNTS_LAST_MOUSEYPOS%
  3409. #*|Stop FNEvnts_GetLastMouseYPos
  3410.  *|Start PROCEvnts_DeleteData
  3411. Evnts_DeleteData(A$,h%,yB%,vA%,BA%,RA%,
  3412. r$,p%,eB$,b%,c%
  3413. pC%,qC%,rC%,zB%,f%,q%,VA%
  3414. A$="IconBar"
  3415.     h%=-1
  3416. Evnts_GetEvntListOffset(A$,h%,yB%,BA%,
  3417. b%=!yB%
  3418. VA%=b%!4
  3419. b%+=c%
  3420. p%=b%+RA%
  3421. pC%=!p%
  3422. !p%=-1
  3423. pC%=-1
  3424. r$=$(!vA%+pC%)
  3425. qC%=(!vA%+pC%)+
  3426. (r$)+1
  3427. rC%=!vA%+pC%
  3428. zB%=qC%-rC%
  3429. &400F1,_U%!&94,qC%,_U%!&94,rC%,zB%
  3430. dI%-=zB%
  3431. *!vA%=
  3432. shell_HeapBlockExtend(!vA%,-zB%)
  3433. b%=!yB%
  3434. f%=_EVNTS_HEADER_SIZE%+RA%
  3435. b%!f%>pC%
  3436. b%!f%-=zB%
  3437. f%+=BA%
  3438. *|Stop PROCEvnts_DeleteData
  3439.  *|Start PROCEvnts_DeleteEvnt
  3440. Evnts_DeleteEvnt(A$,h%,yB%,vA%,BA%)
  3441. c%,b%,VA%,qC%,rC%,VA%
  3442. Evnts_GetEvntListOffset(A$,h%,yB%,BA%,
  3443. b%=!yB%
  3444. VA%=b%!4
  3445. VA%>0
  3446. b%!0-=BA%
  3447. b%!4-=1
  3448. b%+=c%
  3449. qC%=b%+BA%
  3450. rC%=b%
  3451. zB%=BA%
  3452. VA%>1
  3453. &400F1,_U%!&94,qC%,_U%!&94,rC%,zB%
  3454. *!yB%=
  3455. shell_HeapBlockExtend(!yB%,-zB%)
  3456. *|Stop PROCEvnts_DeleteEvnt
  3457. +*|Start FNshell_EvntHandle_AttachedHelp
  3458. shell_EvntHandle_AttachedHelp(c%)
  3459. k%,kC%,jC%,W$
  3460. !k%=!_EVNTS_HELPTAG_ANCHOR%+c%
  3461. kC%=k%!16
  3462. jC%=!_EVNTS_HELPTAG_DATA%
  3463. W$=$(jC%+kC%)
  3464. **|Stop FNshell_EvntHandle_AttachedHelp
  3465. '*|Start FNshell_EvntHandle_MenuHelp
  3466. shell_EvntHandle_MenuHelp(EG%)
  3467. W$,PG%,f%,PA%,c%
  3468. kC%,jC%
  3469. shell_MenuLastHandle
  3470. EG%!f%<>-1
  3471. XJ%=EG%!f%
  3472. !    f%+=4
  3473. $)PA%=
  3474. shell_MenuGetItemHandle(PG%,EG%)
  3475. PA%<>0
  3476. (ec%=
  3477. Evnts_GetEvntListOffset("menu",PA%,_EVNTS_MENUHELPTAG_ANCHOR%,_EVNTS_MENUHELPTAG_REC_SIZE%,
  3478. c%>=0
  3479. *%k%=!_EVNTS_MENUHELPTAG_ANCHOR%+c%
  3480. kC%=k%!16
  3481. ,!jC%=!_EVNTS_MENUHELPTAG_DATA%
  3482. W$=$(jC%+kC%)
  3483. 1    W$=""
  3484. 6&*|Stop FNshell_EvntHandle_MenuHelp
  3485. !*|Start FN_shell_Windows_Init
  3486. _shell_Windows_Init
  3487. _WINDOWS_GETSTATE_BLK%36
  3488. _WINDOWS_GETWINFO_BLK%88
  3489. _WINDOWS_GETPINFO_BLK%20
  3490. _WINDOWS_SETEXTENT_BLK%20
  3491. CK%=-1
  3492. lJ%=-1
  3493.  *|Stop FN_shell_Windows_Init
  3494. %*|Start FNshell_WindowHasTitleBar
  3495. shell_WindowHasTitleBar(a%)
  3496. shell_WindowGetFlags(a%)
  3497. 1<<26)
  3498. $*|Stop FNshell_WindowHasTitleBar
  3499. $*|Start FNshell_WindowIsMoveable
  3500. shell_WindowIsMoveable(a%)
  3501. shell_WindowGetFlags(a%)
  3502. 1<<1)
  3503. #*|Stop FNshell_WindowIsMoveable
  3504. !*|Start FNshell_WindowIsAPane
  3505. shell_WindowIsAPane(a%)
  3506. shell_WindowGetFlags(a%)
  3507. 1<<5)
  3508.  *|Stop FNshell_WindowIsAPane
  3509. &*|Start FNshell_WindowIsNotBounded
  3510. shell_WindowIsNotBounded(a%)
  3511. shell_WindowGetFlags(a%)
  3512. 1<<6)
  3513. %*|Stop FNshell_WindowIsNotBounded
  3514. &*|Start FNshell_WindowTrapsHotKeys
  3515. shell_WindowTrapsHotKeys(a%)
  3516. shell_WindowGetFlags(a%)
  3517. 1<<&C)
  3518. %*|Stop FNshell_WindowTrapsHotKeys
  3519.  *|Start FNshell_WindowIsOpen
  3520. shell_WindowIsOpen(e%)
  3521. shell_WindowGetFlags(e%)
  3522. 1<<16)
  3523. e%=-1
  3524. e%=-2
  3525. *|Stop FNshell_WindowIsOpen
  3526. !*|Start FNshell_WindowIsOnTop
  3527. shell_WindowIsOnTop(a%)
  3528. shell_WindowGetFlags(a%)
  3529. 1<<17)
  3530.  *|Stop FNshell_WindowIsOnTop
  3531. (*|Start FNshell_WindowHasBeenToggled
  3532. shell_WindowHasBeenToggled(a%)
  3533. shell_WindowGetFlags(a%)
  3534. 1<<18)
  3535. '*|Stop FNshell_WindowHasBeenToggled
  3536. '*|Start FNshell_WindowHasInputFocus
  3537. shell_WindowHasInputFocus(a%)
  3538. shell_WindowGetFlags(a%)
  3539. 1<<20)
  3540. &*|Stop FNshell_WindowHasInputFocus
  3541. %*|Start FNshell_WindowHasBackIcon
  3542. shell_WindowHasBackIcon(a%)
  3543. shell_WindowGetFlags(a%)
  3544. 1<<24)
  3545. $*|Stop FNshell_WindowHasBackIcon
  3546. &*|Start FNshell_WindowHasCloseIcon
  3547. shell_WindowHasCloseIcon(a%)
  3548. shell_WindowGetFlags(a%)
  3549. 1<<25)
  3550. %*|Stop FNshell_WindowHasCloseIcon
  3551. '*|Start FNshell_WindowHasToggleIcon
  3552. shell_WindowHasToggleIcon(a%)
  3553. shell_WindowGetFlags(a%)
  3554. 1<<27)
  3555. &*|Stop FNshell_WindowHasToggleIcon
  3556. '*|Start FNshell_WindowHasVScrollBar
  3557. shell_WindowHasVScrollBar(a%)
  3558. shell_WindowGetFlags(a%)
  3559. 1<<28)
  3560. &*|Stop FNshell_WindowHasVScrollBar
  3561. +*|Start FNshell_WindowHasAdjustSizeIcon
  3562. shell_WindowHasAdjustSizeIcon(a%)
  3563. shell_WindowGetFlags(a%)
  3564. 1<<29)
  3565. **|Stop FNshell_WindowHasAdjustSizeIcon
  3566. '*|Start FNshell_WindowHasHScrollBar
  3567. shell_WindowHasHScrollBar(a%)
  3568. shell_WindowGetFlags(a%)
  3569. 1<<30)
  3570. &*|Stop FNshell_WindowHasHScrollBar
  3571. "*|Start FNshell_WindowGetFlags
  3572. shell_WindowGetFlags(e%)
  3573. _WINDOWS_GETSTATE_BLK%!0=e%
  3574. &400CB,,_WINDOWS_GETSTATE_BLK%
  3575.  o%=_WINDOWS_GETSTATE_BLK%!32
  3576. !*|Stop FNshell_WindowGetFlags
  3577. '*|Start FNshell_WindowGetTitleFlags
  3578. shell_WindowGetTitleFlags(a%)
  3579. o%,d%
  3580. Windows_ClaimInfoBlock(a%)
  3581. d%!0=a%
  3582. &400CC,,d%
  3583. o%=d%!60
  3584. Windows_ReturnInfoBlock(d%)
  3585. &&*|Stop FNshell_WindowGetTitleFlags
  3586. *$*|Start FNshell_WindowTitleFlags
  3587. shell_WindowTitleFlags(a%)
  3588. o%,d%
  3589. -"d%=
  3590. Windows_ClaimInfoBlock(a%)
  3591. d%!0=a%
  3592. &400CC,,d%
  3593. o%=d%!60
  3594. Windows_ReturnInfoBlock(d%)
  3595. 4#*|Stop FNshell_WindowTitleFlags
  3596. 8(*|Start FNshell_WindowTitleHasBorder
  3597. shell_WindowTitleHasBorder(a%)
  3598. shell_WindowTitleFlags(a%)
  3599. 1<<2)
  3600. <'*|Stop FNshell_WindowTitleHasBorder
  3601. @'*|Start FNshell_WindowTitleIsSprite
  3602. shell_WindowTitleIsSprite(a%)
  3603. shell_WindowTitleFlags(a%)
  3604. 1<<1)
  3605. D&*|Stop FNshell_WindowTitleIsSprite
  3606. H%*|Start FNshell_WindowTitleIsText
  3607. shell_WindowTitleIsText(a%)
  3608. shell_WindowTitleFlags(a%)
  3609. 1<<0)
  3610. L$*|Stop FNshell_WindowTitleIsText
  3611. P)*|Start FNshell_WindowTitleIsHCentred
  3612. shell_WindowTitleIsHCentred(a%)
  3613. shell_WindowTitleFlags(a%)
  3614. 1<<3)
  3615. T(*|Stop FNshell_WindowTitleIsHCentred
  3616. X)*|Start FNshell_WindowTitleIsVCentred
  3617. shell_WindowTitleIsVCentred(a%)
  3618. shell_WindowTitleFlags(a%)
  3619. 1<<4)
  3620. \(*|Stop FNshell_WindowTitleIsVCentred
  3621. `'*|Start FNshell_WindowTitleIsFilled
  3622. shell_WindowTitleIsFilled(a%)
  3623. shell_WindowTitleFlags(a%)
  3624. 1<<5)
  3625. d&*|Stop FNshell_WindowTitleIsFilled
  3626. h)*|Start FNshell_WindowTitleIsAAliased
  3627. shell_WindowTitleIsAAliased(a%)
  3628. shell_WindowTitleFlags(a%)
  3629. 1<<6)
  3630. l(*|Stop FNshell_WindowTitleIsAAliased
  3631. p+*|Start FNshell_WindowTitleIsIndirected
  3632. shell_WindowTitleIsIndirected(a%)
  3633. shell_WindowTitleFlags(a%)
  3634. 1<<8)
  3635. t**|Stop FNshell_WindowTitleIsIndirected
  3636. x"*|Start FNshell_WindowGetTitle
  3637. shell_WindowGetTitle(a%)
  3638. l$,d%
  3639. |"d%=
  3640. Windows_ClaimInfoBlock(a%)
  3641. d%!0=a%
  3642. &400CC,,d%
  3643. (d%!32
  3644. 1<<26)
  3645. ((d%!60)
  3646. 256)=0
  3647. l$=$(d%+76)
  3648. l$=$(!(d%+76))
  3649. Windows_ReturnInfoBlock(d%)
  3650. !*|Stop FNshell_WindowGetTitle
  3651. +*|Start FNshell_WindowTitleBufferLength
  3652. shell_WindowTitleBufferLength(a%)
  3653. t%,d%
  3654. Windows_ClaimInfoBlock(a%)
  3655. d%!0=a%
  3656. &400CC,,d%
  3657. ((d%!60)
  3658. 256)=0
  3659.     t%=&C
  3660. t%=d%!84
  3661. Windows_ReturnInfoBlock(d%)
  3662. **|Stop FNshell_WindowTitleBufferLength
  3663. &*|Start PROCshell_WindowMoveToIcon
  3664. shell_WindowMoveToIcon(a%,OG%,r%,BB%,CB%)
  3665. LA%,v%
  3666. !LA%=
  3667. shell_HeapBlockFetch(50)
  3668. shell_HeapBlockFetch(36)
  3669. v%!20=0
  3670. shell_OSCheckVersion(3)
  3671. OG%=-1
  3672. !v%=-2
  3673. !v%=OG%
  3674. &400CB,,v%
  3675. LA%!0=OG%:LA%!4=r%
  3676. &400CE,,LA%
  3677. shell_WindowMoveTo(a%,LA%!8+BB%-v%!20,LA%!20+CB%)
  3678. shell_HeapBlockReturn(LA%)
  3679. shell_HeapBlockReturn(v%)
  3680. %*|Stop PROCshell_WindowMoveToIcon
  3681. "*|Start PROCshell_WindowMoveTo
  3682. shell_WindowMoveTo(a%,SA%,TA%)
  3683. WG%,UG%,c%,d%
  3684. Windows_ClaimInfoBlock(a%)
  3685. d%!0=a%
  3686. &400CC,,d%
  3687. WG%=d%!&C-d%!4
  3688. UG%=d%!16-d%!8
  3689. d%!4=SA%
  3690. d%!8=TA%
  3691. d%!&C=SA%+WG%
  3692. d%!16=TA%+UG%
  3693. &400C5,,d%
  3694. &400C6,,d%
  3695. shell_IsWindowStatic(a%)
  3696. shell_OpenWindowStatic(a%)
  3697. shell_OpenWindowDynamic2(a%,0,0)
  3698. Windows_ReturnInfoBlock(d%)
  3699. !*|Stop PROCshell_WindowMoveTo
  3700. &*|Start PROCshell_WindowBringToTop
  3701. shell_WindowBringToTop(a%)
  3702. "QC%=
  3703. shell_HeapBlockFetch(256)
  3704. QC%!0=a%
  3705. &400CB,,QC%
  3706. QC%!28=-1
  3707. &400E7,2,QC%,a%
  3708. &400C7,0,QC%
  3709. shell_HeapBlockReturn(QC%)
  3710. %*|Stop PROCshell_WindowBringToTop
  3711. !*|Start PROCshell_CloseWindow
  3712. shell_CloseWindow(e%)
  3713. c%,_%,vJ%,zA%,wD%,A$
  3714. k%,b$,HA%,MD%
  3715. shell_GetWindowIdentifier(e%)
  3716.     zA%=0
  3717. Evnts_GetEvntListOffset(A$,zA%,_EVNTS_PANES_ANCHOR%,_EVNTS_PANES_REC_SIZE%,
  3718. c%=GE%
  3719. k%=!_EVNTS_PANES_ANCHOR%+c%
  3720. wD%=k%!16
  3721. x%=!_EVNTS_PANES_DATA%
  3722. b$=$(x%+wD%)
  3723. &HA%=
  3724. shell_GetWindowHandleList(b$)
  3725. MD%=!HA%
  3726. _EVNTS_PANE_BLK%!0=MD%
  3727. &400C6,,_EVNTS_PANE_BLK%
  3728. zA%+=1
  3729. _EVNTS_PANE_BLK%!0=e%
  3730. &400C6,,_EVNTS_PANE_BLK%
  3731.  *|Stop PROCshell_CloseWindow
  3732. **|Start FNshell_GetDynamicWindowHandle
  3733. shell_GetDynamicWindowHandle
  3734. =_U%!20
  3735. )*|Stop FNshell_GetDynamicWindowHandle
  3736.  *|Start FNshell_DeleteWindow
  3737. shell_DeleteWindow(m%)
  3738. shell_HeapBlockFetch(20)
  3739. oktodeletew(m%)
  3740. shell_RemoveHandleFromWindowList(m%)
  3741. m%=_U%!20
  3742. _U%!20=0
  3743. shell_RemoveStaticWindowFromList(m%)
  3744. _%!0=m%
  3745. &600C3,,_%
  3746. shell_HeapBlockReturn(_%)
  3747. *|Stop FNshell_DeleteWindow
  3748. *$*|Start FNshell_WindowCountIcons
  3749. shell_WindowCountIcons(a%)
  3750. sC%,eC%,MB%
  3751. (_U%!&64
  3752. 1<<&A)
  3753. a%=-1
  3754. a%=-2
  3755. 2!sC%=
  3756. shell_HeapBlockFetch(88)
  3757. !_WINDOWS_GETWINFO_BLK%=a%
  3758. &400CC,,_WINDOWS_GETWINFO_BLK%+1
  3759. 5!MB%=_WINDOWS_GETWINFO_BLK%!88
  3760. 9#sC%=
  3761. shell_HeapBlockFetch(6000)
  3762. !sC%=a%
  3763. &400CC,,sC%
  3764. MB%=sC%!88
  3765. shell_HeapBlockReturn(sC%)
  3766. E#*|Stop FNshell_WindowCountIcons
  3767. I**|Start PROCshell_WindowToggleBackIcon
  3768. shell_WindowToggleBackIcon(
  3769. shell_WindowToggleFlags(a%,1<<24)
  3770. N)*|Stop PROCshell_WindowToggleBackIcon
  3771. R+*|Start PROCshell_WindowToggleCloseIcon
  3772. shell_WindowToggleCloseIcon(
  3773. shell_WindowToggleFlags(a%,1<<25)
  3774. W**|Stop PROCshell_WindowToggleCloseIcon
  3775. Z**|Start PROCshell_WindowToggleTitleBar
  3776. shell_WindowToggleTitleBar(
  3777. shell_WindowToggleFlags(a%,1<<26)
  3778. _)*|Stop PROCshell_WindowToggleTitleBar
  3779. c,*|Start PROCshell_WindowToggleToggleIcon
  3780. shell_WindowToggleToggleIcon(
  3781. shell_WindowToggleFlags(a%,1<<27)
  3782. h+*|Stop PROCshell_WindowToggleToggleIcon
  3783. l,*|Start PROCshell_WindowToggleHScrollBar
  3784. shell_WindowToggleHScrollBar(
  3785. shell_WindowToggleFlags(a%,1<<30)
  3786. q+*|Stop PROCshell_WindowToggleHScrollBar
  3787. u0*|Start PROCshell_WindowToggleAdjustSizeIcon
  3788. shell_WindowToggleAdjustSizeIcon(
  3789. shell_WindowToggleFlags(a%,1<<29)
  3790. z/*|Stop PROCshell_WindowToggleAdjustSizeIcon
  3791. ~,*|Start PROCshell_WindowToggleVScrollBar
  3792. shell_WindowToggleVScrollBar(
  3793. shell_WindowToggleFlags(a%,1<<28)
  3794. +*|Stop PROCshell_WindowToggleVScrollBar
  3795. '*|Start PROCshell_WindowToggleFlags
  3796. shell_WindowToggleFlags(
  3797. a%,_A%)
  3798. d%,o%,DE%,m%
  3799. *|ifdef TraceInit
  3800. shell_Tracef0("WindowToggleFlags:wh% = &"+
  3801. *|endif
  3802. shell_WindowIsOpen(a%)
  3803. Windows_ClaimInfoBlock(a%)
  3804. d%!0=a%
  3805. &400CC,,d%
  3806. o%=d%!32
  3807. o%=(o%
  3808. d%!32=o%
  3809. &400C3,,d%
  3810. &400C1,,d%+4
  3811. !d%=m%
  3812. &400C5,,d%
  3813. Windows_ReturnInfoBlock(d%)
  3814. m%<>a%
  3815. shell_UpdateWindowHandle(a%,m%)
  3816. shell_UpdateWindowHandleList(a%,m%)
  3817.     a%=m%
  3818. &*|Stop PROCshell_WindowToggleFlags
  3819. "*|Start PROCshell_UpdateWindow
  3820. shell_UpdateWindow(m%,jF%,dB%,bB%,ZF%)
  3821. shell_HeapBlockFetch(d%)
  3822. 1d%!0=m%:d%!4=jF%:d%!8=dB%:d%!&C=bB%:d%!16=ZF%
  3823. &400C9,,d%
  3824. &400CB,,d%
  3825. shell_HeapBlockReturn(d%)
  3826. !*|Stop PROCshell_UpdateWindow
  3827. (*|Start PROCshell_OpenWindowDynamic2
  3828. shell_OpenWindowDynamic2(a%,BB%,CB%)
  3829. j%,QD%
  3830. !QD%=
  3831. shell_HeapBlockFetch(20)
  3832. _U%!20=a%
  3833. &400CF,,QD%
  3834. &400D4,,a%,QD%!0+BB%,QD%!4+CB%
  3835. shell_HeapBlockReturn(QD%)
  3836. '*|Stop PROCshell_OpenWindowDynamic2
  3837. '*|Start PROCshell_WindowGetPosition
  3838. shell_WindowGetPosition(e%,
  3839. !_WINDOWS_GETSTATE_BLK%=e%
  3840. &400CB,,_WINDOWS_GETSTATE_BLK%
  3841.  tC%=_WINDOWS_GETSTATE_BLK%!4
  3842.  uC%=_WINDOWS_GETSTATE_BLK%!8
  3843. !vC%=_WINDOWS_GETSTATE_BLK%!&C
  3844. !wC%=_WINDOWS_GETSTATE_BLK%!16
  3845. &*|Stop PROCshell_WindowGetPosition
  3846. #*|Start PROCshell_WindowGetSize
  3847. shell_WindowGetSize(e%,
  3848. tC%,uC%,vC%,wC%
  3849. shell_WindowGetPosition(e%,tC%,uC%,vC%,wC%)
  3850. jI%=vC%-tC%
  3851. CJ%=wC%-uC%
  3852. "*|Stop PROCshell_WindowGetSize
  3853. '*|Start PROCshell_OpenWindowDynamic
  3854. shell_OpenWindowDynamic(EB$,sA$,uA$)
  3855. y%,BB%,CB%,pE%
  3856. %pE%=
  3857. shell_GetDynamicWindowHandle
  3858. pE%<>0
  3859. &400D4,,-1
  3860. shell_DeleteWindow(pE%)
  3861. shell_CreateWindow(EB$,y%)
  3862. _WINDOWS_GETSTATE_BLK%!0=y%
  3863. &400CB,,_WINDOWS_GETSTATE_BLK%
  3864. >BB%=(_WINDOWS_GETSTATE_BLK%!4-_WINDOWS_GETSTATE_BLK%!&C)/2
  3865. >CB%=(_WINDOWS_GETSTATE_BLK%!16-_WINDOWS_GETSTATE_BLK%!8)/2
  3866. _U%!20=y%
  3867. sA$<>""
  3868. ("FN"+sA$+"("+
  3869. y%+")")
  3870. shell_OpenWindowDynamic2(y%,BB%,CB%)
  3871. uA$<>""
  3872. ("FN"+uA$+"("+
  3873. y%+")")
  3874. &*|Stop PROCshell_OpenWindowDynamic
  3875. "*|Start PROCshell_CreateWindow
  3876. shell_CreateWindow(H$,
  3877. shell_GetWB(H$)
  3878. _B%!64=_U%!16
  3879. &400C1,,_B%
  3880. shell_WindowListAddHandle(H$,e%)
  3881. !*|Stop PROCshell_CreateWindow
  3882. $*|Start FNWindows_ClaimInfoBlock
  3883. Windows_ClaimInfoBlock(e%)
  3884. shell_HeapBlockFetch(&64+(
  3885. shell_WindowCountIcons(e%)*32))
  3886. #*|Stop FNWindows_ClaimInfoBlock
  3887. '*|Start PROCWindows_ReturnInfoBlock
  3888. Windows_ReturnInfoBlock(GA%)
  3889. shell_HeapBlockReturn(GA%)
  3890. &*|Stop PROCWindows_ReturnInfoBlock
  3891. #"*|Start PROCshell_WindowResize
  3892. shell_WindowResize(QA%,QI%,bI%,mI%,PI%,DE%)
  3893. '$SD%=
  3894. Windows_ClaimInfoBlock(QA%)
  3895. )!_WINDOWS_SETEXTENT_BLK%!0=QI%
  3896. *!_WINDOWS_SETEXTENT_BLK%!4=bI%
  3897. +!_WINDOWS_SETEXTENT_BLK%!8=mI%
  3898. ,"_WINDOWS_SETEXTENT_BLK%!&C=PI%
  3899. &400D7,QA%,_WINDOWS_SETEXTENT_BLK%
  3900. SD%!0=QA%
  3901. &400CC,,SD%
  3902. &400C5,,SD%
  3903. Windows_ReturnInfoBlock(SD%)
  3904. 8!*|Stop PROCshell_WindowResize
  3905. ;#*|Start PROCshell_WindowRetitle
  3906. shell_WindowRetitle(
  3907. QA%,l$)
  3908. g%,_%,m%,ZG%
  3909. >#_%=
  3910. Windows_ClaimInfoBlock(QA%)
  3911. _%!0=QA%
  3912. &400CC,,_%
  3913. ((_%!60)
  3914. 256)=0
  3915. g%=_%+76
  3916. l$,&B)
  3917. &400C3,,_%
  3918. &400C1,,_%+4
  3919. m%<>QA%
  3920. shell_UpdateWindowHandle(QA%,m%)
  3921. QA%=m%
  3922. ZG%=_%!84
  3923. $(!(_%+76))=
  3924. l$,ZG%-1)
  3925. ((_%!32)
  3926. (1<<16))<>0
  3927. &400D1,-1,_%!4,_%!16,_%!&C,_%!16+44
  3928. Windows_ReturnInfoBlock(_%)
  3929. Y"*|Stop PROCshell_WindowRetitle
  3930. \)*|Start FNshell_WindowTitleIndirected
  3931. shell_WindowTitleIndirected(yD%)
  3932. (1<<8))=(1<<8)
  3933. a(*|Stop FNshell_WindowTitleIndirected
  3934. e**|Start PROCshell_WindowMoveToPopUpPos
  3935. shell_WindowMoveToPopUpPos(e%,h%,aG%)
  3936. RC%,JB%,dG%,fG%,gG%,hG%
  3937. i!RC%=
  3938. shell_HeapBlockFetch(40)
  3939. RC%!0=e%
  3940. RC%!4=h%
  3941. &400CE,,RC%
  3942. dG%=RC%!16
  3943. fG%=RC%!20
  3944. o!JB%=
  3945. shell_HeapBlockFetch(40)
  3946. JB%!0=e%
  3947. &400CB,,JB%
  3948. gG%=JB%!4
  3949. hG%=JB%!16
  3950. JB%!0=aG%
  3951. &400CB,,JB%
  3952. iG%=JB%!16-JB%!8
  3953. shell_WindowMoveTo(aG%,gG%+dG%,hG%+fG%-(iG%/2))
  3954. shell_HeapBlockReturn(RC%)
  3955. shell_HeapBlockReturn(JB%)
  3956. {)*|Stop PROCshell_WindowMoveToPopUpPos
  3957. $*|Start PROCshell_WindowScrollTo
  3958. shell_WindowScrollTo(e%,TD%,UD%)
  3959. !gA%=
  3960. shell_HeapBlockFetch(36)
  3961. !gA%=e%
  3962. &400CB,,gA%
  3963. gA%!20=TD%
  3964. gA%!24=UD%
  3965. shell_WindowIsOpen(e%)
  3966. &400C5,,gA%
  3967. &400C5,,gA%
  3968. &400C6,,gA%
  3969. shell_HeapBlockReturn(gA%)
  3970. #*|Stop PROCshell_WindowScrollTo
  3971. $*|Start PROCshell_WindowScrollBy
  3972. shell_WindowScrollBy(e%,TD%,UD%)
  3973. !gA%=
  3974. shell_HeapBlockFetch(36)
  3975. !gA%=e%
  3976. &400CB,,gA%
  3977. gA%!20+=TD%
  3978. gA%!24+=UD%
  3979. shell_WindowIsOpen(e%)
  3980. &400C5,,gA%
  3981. &400C5,,gA%
  3982. &400C6,,gA%
  3983. shell_HeapBlockReturn(gA%)
  3984. #*|Stop PROCshell_WindowScrollBy
  3985. /*|Start PROCshell_WindowSetBackgroundColour
  3986. shell_WindowSetBackgroundColour(
  3987. y%,WB%)
  3988. v%,m%,uG%,QB%,MB%
  3989. #MB%=
  3990. shell_WindowCountIcons(y%)
  3991. shell_WindowIsOpen(y%)
  3992. shell_HeapBlockFetch(&64+(MB%*32))
  3993. v%!0=y%
  3994. &400CC,,v%
  3995. v%?39=WB%
  3996. _shell_open_behind%=v%!28
  3997. QB%=v%!28
  3998. &400C3,,v%
  3999. &400C1,,v%+4
  4000. v%!0=m%
  4001. &400CC,,v%
  4002. y%<>m%
  4003. *|ifdef TraceInit
  4004. *|endif
  4005. shell_UpdateWindowHandle(y%,m%)
  4006.     y%=m%
  4007. shell_OpenWindow(m%,0,QB%)
  4008. shell_HeapBlockReturn(v%)
  4009. .*|Stop PROCshell_WindowSetBackgroundColour
  4010. /*|Start PROCshell_WindowSetForegroundColour
  4011. shell_WindowSetForegroundColour(
  4012. y%,WB%)
  4013. v%,m%,tB%,QB%
  4014. shell_WindowIsOpen(a%)
  4015. shell_HeapBlockFetch(&64+(
  4016. shell_WindowCountIcons(y%)*32))
  4017. v%!0=y%
  4018. &400CC,,v%
  4019. v%?38=WB%
  4020. _shell_open_behind%=v%!28
  4021. QB%=v%!28
  4022. &400C3,,v%
  4023. &400C1,,v%+4
  4024. y%<>m%
  4025. *|ifdef TraceInit
  4026. *|endif
  4027. shell_UpdateWindowHandle(y%,m%)
  4028.     y%=m%
  4029. shell_OpenWindow(m%,0,QB%)
  4030. shell_HeapBlockReturn(v%)
  4031. .*|Stop PROCshell_WindowSetForegroundColour
  4032. *|Start FN_shell_Icons_Init
  4033. _shell_Icons_Init
  4034. _c_Icons_IconDragType%=5
  4035. _c_Icons_DragBBoxXMin%=0
  4036. _c_Icons_DragBBoxYMin%=0
  4037. J$_c_Icons_DragBBoxXMax%=&7FFFFFFF
  4038. K$_c_Icons_DragBBoxYMax%=&7FFFFFFF
  4039. _c_Icons_DragFlags%=&85
  4040. N+_c_Icons_IconOverFlowMess$="SHELLMSG12"
  4041. O-_c_Icons_NotASpriteIconMess$="SHELLMSG19"
  4042. P._c_Icons_WimpColourRangeMess$="SHELLMSG24"
  4043. _c_Icons_MinWimpColour%=0
  4044. _c_Icons_MaxWimpColour%=&F
  4045. _c_Icon_SetIconStateBlk%16
  4046. _c_Icon_GetIconStateBlk%40
  4047. _c_Icon_GetCaretPositionBlk%24
  4048. ["_m_Icons_AllowWritableDrags%=
  4049. *|Stop FN_shell_Icons_Init
  4050. c%*|Start PROCshell_IconSetFGColour
  4051. shell_IconSetFGColour(e%,h%,WB%)
  4052. WB%<_c_Icons_MinWimpColour%
  4053. WB%>_c_Icons_MaxWimpColour%
  4054. shell_MessageOneArg(_c_Icons_WimpColourRangeMess$,"PROCshell_IconSetFGColour")
  4055. shell_IconSetState(e%,h%,WB%<<24,&F000000)
  4056. j$*|Stop PROCshell_IconSetFGColour
  4057. n%*|Start PROCshell_IconSetBGColour
  4058. shell_IconSetBGColour(e%,h%,WB%)
  4059. WB%<_c_Icons_MinWimpColour%
  4060. WB%>_c_Icons_MaxWimpColour%
  4061. shell_MessageOneArg(_c_Icons_WimpColourRangeMess$,"PROCshell_IconSetBGColour")
  4062. shell_IconSetState(e%,h%,WB%<<28,&F0000000)
  4063. v$*|Stop PROCshell_IconSetBGColour
  4064. z&*|Start PROCshell_IconUnselectable
  4065. shell_IconUnselectable(e%,h%)
  4066. shell_IconSetUnselectable(e%,h%,1)
  4067. %*|Stop PROCshell_IconUnselectable
  4068. "*|Start PROCshell_IconSetState
  4069. shell_IconSetState(e%,h%,KJ%,PJ%)
  4070. h%>=0
  4071. !_c_Icon_SetIconStateBlk%!0=e%
  4072. !_c_Icon_SetIconStateBlk%!4=h%
  4073. "_c_Icon_SetIconStateBlk%!8=KJ%
  4074. #_c_Icon_SetIconStateBlk%!&C=PJ%
  4075. &600CD,,_c_Icon_SetIconStateBlk%
  4076. !*|Stop PROCshell_IconSetState
  4077. *|Start PROCshell_IconSet
  4078. shell_IconSet(e%,h%,wA%)
  4079. wA%=0
  4080. shell_IconDeselect(e%,h%)
  4081. shell_IconSelect(e%,h%)
  4082. *|Stop PROCshell_IconSet
  4083. %*|Start PROCshell_IconSetSelected
  4084. shell_IconSetSelected(a%,r%,wA%)
  4085. wA%=0
  4086. shell_IconDeselect(a%,r%)
  4087. shell_IconSelect(a%,r%)
  4088. $*|Stop PROCshell_IconSetSelected
  4089. *|Start PROCIcons_GetState
  4090. Icons_GetState(e%,h%)
  4091. !_c_Icon_GetIconStateBlk%!0=e%
  4092. !_c_Icon_GetIconStateBlk%!4=h%
  4093. &400CE,,_c_Icon_GetIconStateBlk%
  4094. *|Stop PROCIcons_GetState
  4095.  *|Start PROCshell_IconSelect
  4096. shell_IconSelect(dC%,LC%)
  4097. shell_IconSetState(dC%,LC%,&200000,&200000)
  4098. *|Stop PROCshell_IconSelect
  4099. "*|Start PROCshell_IconDeselect
  4100. shell_IconDeselect(dC%,LC%)
  4101. shell_IconSetState(dC%,LC%,0,&200000)
  4102. !*|Stop PROCshell_IconDeselect
  4103. "*|Start FNshell_IsIconSelected
  4104. shell_IsIconSelected(dC%,LC%)
  4105. Icons_GetState(dC%,LC%)
  4106. "o%=_c_Icon_GetIconStateBlk%!24
  4107. g%=(o%
  4108. &200000)
  4109. !*|Stop FNshell_IsIconSelected
  4110. '*|Start PROCshell_IconPutValidation
  4111. shell_IconPutValidation(e%,h%,RA$)
  4112. !_c_Icon_GetIconStateBlk%!0=e%
  4113. !_c_Icon_GetIconStateBlk%!4=h%
  4114. &400CE,,_c_Icon_GetIconStateBlk%
  4115. "o%=_c_Icon_GetIconStateBlk%!24
  4116. &$(_c_Icon_GetIconStateBlk%!32)=RA$
  4117. &*|Stop PROCshell_IconPutValidation
  4118. %*|Start FNshell_IconGetValidation
  4119. shell_IconGetValidation(e%,h%)
  4120. N$,o%
  4121. h%=-1
  4122.     N$=""
  4123. !_c_Icon_GetIconStateBlk%!0=e%
  4124. !_c_Icon_GetIconStateBlk%!4=h%
  4125. &400CE,,_c_Icon_GetIconStateBlk%
  4126. "o%=_c_Icon_GetIconStateBlk%!24
  4127. _c_Icon_GetIconStateBlk%!32>0
  4128. N$=$(_c_Icon_GetIconStateBlk%!32)
  4129. $*|Stop FNshell_IconGetValidation
  4130.  *|Start PROCshell_IconRedraw
  4131. shell_IconRedraw(e%,h%)
  4132. shell_IconSetState(e%,h%,0,0)
  4133. *|Stop PROCshell_IconRedraw
  4134. "*|Start FNshell_IconGetCommand
  4135. shell_IconGetCommand(IE%,UB$)
  4136. I%,Q$
  4137. IE%<=0
  4138.     Q$=""
  4139. shell_StringUpperCase($IE%),";"+
  4140. shell_StringUpperCase(UB$))
  4141.     Q$=""
  4142. $(IE%+I%),
  4143. $(IE%+I%)+";",";")-1)
  4144. !*|Stop FNshell_IconGetCommand
  4145.  *|Start FNshell_IconGetFlags
  4146. shell_IconGetFlags(e%,h%)
  4147. !_c_Icon_GetIconStateBlk%!0=e%
  4148. !_c_Icon_GetIconStateBlk%!4=h%
  4149. &400CE,,_c_Icon_GetIconStateBlk%
  4150. "o%=_c_Icon_GetIconStateBlk%!24
  4151. *|Stop FNshell_IconGetFlags
  4152. "#*|Start FNshell_IconIsDraggable
  4153. shell_IconIsDraggable(e%,h%)
  4154. o%,t%,_A%
  4155. _A%=(1<<&D)+(1<<&E)
  4156. &!o%=
  4157. shell_IconGetFlags(e%,h%)
  4158. t%=(o%
  4159. t%=_A%
  4160. *"*|Stop FNshell_IconIsDraggable
  4161. ."*|Start FNshell_IconIsWritable
  4162. shell_IconIsWritable(e%,h%)
  4163. o%,t%,_A%
  4164. _A%=1<<&E
  4165. 2!o%=
  4166. shell_IconGetFlags(e%,h%)
  4167. t%=(o%
  4168. t%=_A%
  4169. 6!*|Stop FNshell_IconIsWritable
  4170. : *|Start FNshell_IconIsSprite
  4171. shell_IconIsSprite(a%,r%)
  4172. o%,g%
  4173. =!o%=
  4174. shell_IconGetFlags(a%,r%)
  4175. g%=(o%
  4176. 1<<1)
  4177. g%=(1<<1)
  4178. *|Stop FNshell_IconIsSprite
  4179. E *|Start FNshell_IconHasCaret
  4180. shell_IconHasCaret(e%,h%)
  4181. AB%,QA%
  4182. &400D3,,_c_Icon_GetCaretPositionBlk%
  4183. I&QA%=_c_Icon_GetCaretPositionBlk%!0
  4184. J&AB%=_c_Icon_GetCaretPositionBlk%!4
  4185. (AB%=h%
  4186. QA%=e%)
  4187. *|Stop FNshell_IconHasCaret
  4188. *|Start FNshell_IconCreate
  4189. shell_IconCreate(a%,TB%,GB%,ZI%,y%,wE%,xE%,hI%,F$,PB%,KC%,N$)
  4190. kI%,m%,AC%,l%
  4191. U l%=
  4192. shell_HeapBlockFetch(40)
  4193. l%!0=a%
  4194. l%!4=TB%:l%!8=GB%
  4195. l%!&C=TB%+ZI%:l%!16=GB%+y%
  4196. l%!20=hI%
  4197. xE%<<28
  4198. wE%<<24
  4199. l%!20
  4200. F$,",")
  4201. l%!24=PB%
  4202. N$<>""
  4203. ^$AC%=
  4204. shell_HeapBlockFetch(
  4205. N$+1)
  4206. $AC%=N$
  4207. l%!28=AC%
  4208. l%!28=-1
  4209. l%!32=KC%
  4210. $(l%+24)=
  4211. F$,&B)
  4212. &400C2,,l%
  4213. shell_HeapBlockReturn(l%)
  4214. *|Stop FNshell_IconCreate
  4215. p *|Start PROCshell_IconDelete
  4216. shell_IconDelete(a%,r%)
  4217. shell_DoIconDelete(a%,r%,
  4218. *|Stop PROCshell_IconDelete
  4219. y!*|Start PROCshell_IconDelete2
  4220. shell_IconDelete2(a%,r%)
  4221. shell_DoIconDelete(a%,r%,
  4222. ~ *|Stop PROCshell_IconDelete2
  4223. "*|Start PROCshell_DoIconDelete
  4224. shell_DoIconDelete(a%,r%,oI%)
  4225. XA%,aA%,qA%,yA%
  4226. !_c_Icon_GetIconStateBlk%!0=a%
  4227. !_c_Icon_GetIconStateBlk%!4=r%
  4228. &400CE,,_c_Icon_GetIconStateBlk%
  4229. &8168A,,_c_Icon_GetIconStateBlk%+8
  4230. "XA%=_c_Icon_GetIconStateBlk%!8
  4231. #aA%=_c_Icon_GetIconStateBlk%!&C
  4232. #qA%=_c_Icon_GetIconStateBlk%!16
  4233. #yA%=_c_Icon_GetIconStateBlk%!20
  4234. &400CE,,_c_Icon_GetIconStateBlk%
  4235. shell_HeapBlockExists(_c_Icon_GetIconStateBlk%!28)
  4236. shell_HeapBlockReturn(_c_Icon_GetIconStateBlk%!28)
  4237. shell_HeapBlockExists(_c_Icon_GetIconStateBlk%!32)
  4238. shell_HeapBlockReturn(_c_Icon_GetIconStateBlk%!32)
  4239. &400C4,,_c_Icon_GetIconStateBlk%
  4240. &400D1,a%,XA%,aA%,qA%,yA%
  4241. !*|Stop PROCshell_DoIconDelete
  4242. &*|Start FNshell_IconRadioSelection
  4243. shell_IconRadioSelection(e%,BC%)
  4244. GH%,nB%,KH%,LH%
  4245.  nB%=
  4246. shell_HeapBlockFetch(8)
  4247. GH%=(BC%<<16)+(1<<21)
  4248. LH%=(31<<16)+(1<<21)
  4249. &400D6,e%,nB%,LH%,GH%
  4250. KH%=!nB%
  4251. shell_HeapBlockReturn(nB%)
  4252. %*|Stop FNshell_IconRadioSelection
  4253. !*|Start PROCshell_IconPutData
  4254. shell_IconPutData(QA%,AB%,F$,U)
  4255. _U%!&64
  4256. "WimpExt_SetIconString",,,QA%,AB%,F$+
  4257. #_A$=
  4258. shell_IconGetData(QA%,AB%)
  4259. F$<>_A$
  4260. "_c_Icon_GetIconStateBlk%!0=QA%
  4261. "_c_Icon_GetIconStateBlk%!4=AB%
  4262. &400CE,,_c_Icon_GetIconStateBlk%
  4263. (_c_Icon_GetIconStateBlk%!24
  4264. (1<<8))<>0
  4265. F$>_c_Icon_GetIconStateBlk%!36
  4266. shell_MessageNoArgs(_c_Icons_IconOverFlowMess$)
  4267. %$(_c_Icon_GetIconStateBlk%!28)=F$
  4268. *$(_c_Icon_GetIconStateBlk%+28)=
  4269. F$,&B)
  4270. shell_IconHasCaret(QA%,AB%)
  4271. shell_CaretSetRight(QA%,AB%)
  4272.  _c_Icon_GetIconStateBlk%!8=0
  4273. !_c_Icon_GetIconStateBlk%!&C=0
  4274. &400CD,,_c_Icon_GetIconStateBlk%
  4275.  *|Stop PROCshell_IconPutData
  4276. $*|Start PROCshell_IconPutDataNow
  4277. shell_IconPutDataNow(QA%,AB%,F$)
  4278. "_c_Icon_GetIconStateBlk%!0=QA%
  4279. "_c_Icon_GetIconStateBlk%!4=AB%
  4280. &400CE,,_c_Icon_GetIconStateBlk%
  4281. (_c_Icon_GetIconStateBlk%!24
  4282. (1<<8))<>0
  4283. (F$)>_c_Icon_GetIconStateBlk%!36
  4284. shell_MessageNoArgs(_c_Icons_IconOverFlowMess$)
  4285. %$(_c_Icon_GetIconStateBlk%!28)=F$
  4286. *$(_c_Icon_GetIconStateBlk%+28)=
  4287. F$,&B)
  4288.  _c_Icon_GetIconStateBlk%!8=0
  4289. !_c_Icon_GetIconStateBlk%!&C=0
  4290. &400CD,,_c_Icon_GetIconStateBlk%
  4291. shell_EnsurePoll
  4292. #*|Stop PROCshell_IconPutDataNow
  4293. !*|Start FNshell_IconNewSprite
  4294. shell_IconNewSprite(e%,h%,GA$)
  4295. JE%,yE%,zE%,_E%
  4296. !_c_Icon_GetIconStateBlk%!0=e%
  4297. !_c_Icon_GetIconStateBlk%!4=h%
  4298. &400CE,,_c_Icon_GetIconStateBlk%
  4299. (_c_Icon_GetIconStateBlk%!24
  4300. (1<<1))
  4301.     yE%=
  4302.     yE%=
  4303. (_c_Icon_GetIconStateBlk%!24
  4304.     zE%=
  4305.     zE%=
  4306. (_c_Icon_GetIconStateBlk%!24
  4307. (1<<8))
  4308.     _E%=
  4309.     _E%=
  4310. _c_Icon_GetIconStateBlk%!24
  4311. *$(_c_Icon_GetIconStateBlk%!32)="S"+GA$
  4312. &$(_c_Icon_GetIconStateBlk%!28)=GA$
  4313. &_c_Icon_GetIconStateBlk%!36=
  4314. (GA$)
  4315. JE%=h%
  4316. &400C4,,_c_Icon_GetIconStateBlk%
  4317. $9_c_Icon_GetIconStateBlk%!4=_c_Icon_GetIconStateBlk%!8
  4318. %:_c_Icon_GetIconStateBlk%!8=_c_Icon_GetIconStateBlk%!&C
  4319. &;_c_Icon_GetIconStateBlk%!&C=_c_Icon_GetIconStateBlk%!16
  4320. ';_c_Icon_GetIconStateBlk%!16=_c_Icon_GetIconStateBlk%!20
  4321. (;_c_Icon_GetIconStateBlk%!20=_c_Icon_GetIconStateBlk%!24
  4322. )&$(_c_Icon_GetIconStateBlk%+24)=GA$
  4323. &400C2,,_c_Icon_GetIconStateBlk%
  4324. shell_IconRedraw(e%,JE%)
  4325. 2 *|Stop FNshell_IconNewSprite
  4326. *|Start FNshell_IconGetData
  4327. shell_IconGetData(e%,h%)
  4328. e%<-2
  4329. _U%!&64
  4330. "WimpExt_GetIcon",,,e%,h%
  4331. ,,,Q$
  4332. =!_c_Icon_GetIconStateBlk%!0=e%
  4333. >!_c_Icon_GetIconStateBlk%!4=h%
  4334. &400CE,,_c_Icon_GetIconStateBlk%
  4335. (_c_Icon_GetIconStateBlk%!24
  4336. (1<<8))<>0
  4337. A%Q$=$(_c_Icon_GetIconStateBlk%!28)
  4338. C%Q$=$(_c_Icon_GetIconStateBlk%+28)
  4339. *|Stop FNshell_IconGetData
  4340. *|Start FNshell_IconMove2
  4341. shell_IconMove2(e%,h%,YH%,ZH%)
  4342. M!_c_Icon_GetIconStateBlk%!0=e%
  4343. N!_c_Icon_GetIconStateBlk%!4=h%
  4344. &400CE,,_c_Icon_GetIconStateBlk%
  4345. P#_c_Icon_GetIconStateBlk%!8+=YH%
  4346. Q$_c_Icon_GetIconStateBlk%!16+=YH%
  4347. R$_c_Icon_GetIconStateBlk%!&C+=ZH%
  4348. S$_c_Icon_GetIconStateBlk%!20+=ZH%
  4349. shell_IconMove(e%,h%,_c_Icon_GetIconStateBlk%!8,_c_Icon_GetIconStateBlk%!&C,_c_Icon_GetIconStateBlk%!16,_c_Icon_GetIconStateBlk%!20)
  4350. *|Stop FNshell_IconMove2
  4351. *|Start FNshell_IconResize
  4352. shell_IconResize(a%,r%,XA%,aA%,qA%,yA%)
  4353. shell_IconMove(a%,r%,XA%,aA%,qA%,yA%)
  4354. *|Stop FNshell_IconResize
  4355. *|Start FNshell_IconMove
  4356. shell_IconMove(a%,r%,XA%,aA%,qA%,yA%)
  4357. LA%,xJ%,yJ%,XB%,d%
  4358. dH%,fH%,gH%,jH%
  4359. g!LA%=
  4360. shell_HeapBlockFetch(40)
  4361. h d%=
  4362. shell_HeapBlockFetch(40)
  4363. i"!LA%=a%:LA%!4=r%:
  4364. &400CE,,LA%
  4365. !d%=a%:d%!4=r%
  4366. &400CE,,d%
  4367. &8168A,,d%+8
  4368. gI%=LA%!24:AF%=LA%+28
  4369. n)dH%=gI%:fH%=AF%!0:gH%=AF%!4:jH%=AF%!8
  4370. XB%=LA%!8-d%!8
  4371. &400C4,,LA%
  4372. &400D1,!LA%,LA%!8-XB%,LA%!&C-XB%,LA%!16+XB%,LA%!20+XB%
  4373. rAr%=
  4374. shell_CreateIcon2(a%,XA%,aA%,qA%,yA%,dH%,fH%,gH%,jH%,XB%)
  4375. shell_HeapBlockReturn(LA%)
  4376. shell_HeapBlockReturn(d%)
  4377. *|Stop FNshell_IconMove
  4378. *|Start FNshell_CreateIcon2
  4379. shell_CreateIcon2(m%,XA%,aA%,qA%,yA%,o%,nI%,pI%,rI%,XB%)
  4380. lA%,YA%,J$,p$,TB%,GB%
  4381. ~!YA%=
  4382. shell_HeapBlockFetch(60)
  4383. !YA%=m%
  4384. .YA%!20=o%:YA%!24=nI%:YA%!28=pI%:YA%!32=rI%
  4385. J$="":p$=""
  4386. 256J$=$(YA%!24)
  4387. J$=$(YA%+24)
  4388. shell_IconGetCommand(YA%!28,"S")
  4389. p$=$(YA%+24)
  4390. shell_GetMinXY(o%,J$,p$)
  4391. qA%-XA%<TB%
  4392. qA%=XA%+TB%
  4393. yA%-aA%<GB%
  4394. yA%=aA%+GB%
  4395. -YA%!4=XA%:YA%!8=aA%:YA%!&C=qA%:YA%!16=yA%
  4396. &400C2,,YA%
  4397. &400D1,!YA%,YA%!4-XB%,YA%!8-XB%,YA%!&C+XB%,YA%!16+XB%
  4398. &400D3,,YA%
  4399. !YA%=m%:
  4400. YA%!4=lA%:
  4401. &400D2,m%,lA%,0,0,-1,0
  4402. shell_HeapBlockReturn(YA%)
  4403. *|Stop FNshell_CreateIcon2
  4404. *|Start PROCshell_IconSlab
  4405. shell_IconSlab(HD%,a%,r%)
  4406. shell_HeapBlockFetch(50)
  4407. d%!8=HD%:d%!&C=a%:d%!16=r%
  4408. &81680,,d%
  4409. d%!8=0
  4410. &81680,,d%
  4411. shell_HeapBlockReturn(d%)
  4412. *|Stop PROCshell_IconSlab
  4413. '*|Start PROCshell_IconSetButtonType
  4414. shell_IconSetButtonType(a%,r%,VD%)
  4415. VD%=&C
  4416. VD%=&D
  4417. shell_MessageOneArg("SHELLMSG23","PROCshell_IconSetButtonType")
  4418. VD%<0
  4419. VD%>&F
  4420. shell_MessageOneArg("SHELLMSG22","PROCshell_IconSetButtonType")
  4421. shell_IconSetState(a%,r%,VD%<<&C,&F000)
  4422. &*|Stop PROCshell_IconSetButtonType
  4423.  *|Start PROCshell_IconSetESG
  4424. shell_IconSetESG(a%,r%,BC%)
  4425. BC%<0
  4426. BC%>31
  4427. shell_MessageOneArg("SHELLMSG25","PROCshell_IconSetESG")
  4428. shell_IconSetState(a%,r%,BC%<<16,&1F0000)
  4429. *|Stop PROCshell_IconSetESG
  4430. !*|Start PROCshell_IconSetText
  4431. shell_IconSetText(a%,r%,DA%)
  4432. DA%<>0
  4433. DA%=1<<0
  4434. shell_IconSetState(a%,r%,DA%,1<<0)
  4435.  *|Stop PROCshell_IconSetText
  4436. #*|Start PROCshell_IconSetSprite
  4437. shell_IconSetSprite(e%,h%,DA%)
  4438. DA%<>0
  4439. DA%=1<<1
  4440. shell_IconSetState(e%,h%,DA%,1<<1)
  4441. "*|Stop PROCshell_IconSetSprite
  4442. #*|Start PROCshell_IconSetBorder
  4443. shell_IconSetBorder(e%,h%,DA%)
  4444. DA%<>0
  4445. DA%=1<<2
  4446. shell_IconSetState(e%,h%,DA%,1<<2)
  4447. "*|Stop PROCshell_IconSetBorder
  4448. %*|Start PROCshell_IconSetHCentred
  4449. shell_IconSetHCentred(a%,r%,DA%)
  4450. shell_IconSetState(a%,r%,0,1<<9)
  4451. DA%<>0
  4452. DA%=1<<3
  4453. shell_IconSetState(a%,r%,DA%,1<<3)
  4454. $*|Stop PROCshell_IconSetHCentred
  4455. %*|Start PROCshell_IconSetVCentred
  4456. shell_IconSetVCentred(a%,r%,DA%)
  4457. DA%<>0
  4458. DA%=1<<4
  4459. shell_IconSetState(a%,r%,DA%,1<<4)
  4460. $*|Stop PROCshell_IconSetVCentred
  4461. #*|Start PROCshell_IconSetFilled
  4462. shell_IconSetFilled(a%,r%,DA%)
  4463. DA%<>0
  4464. DA%=1<<5
  4465. shell_IconSetState(a%,r%,DA%,1<<5)
  4466. "*|Stop PROCshell_IconSetFilled
  4467. ,*|Start PROCshell_IconSetUsesOutlineFont
  4468. shell_IconSetUsesOutlineFont(a%,r%,DA%)
  4469. DA%<>0
  4470. DA%=1<<6
  4471. shell_IconSetState(a%,r%,DA%,1<<6)
  4472. +*|Stop PROCshell_IconSetUsesOutlineFont
  4473. &*|Start PROCshell_IconSetRightJust
  4474. shell_IconSetRightJust(a%,r%,DA%)
  4475. shell_IconSetHCentred(a%,r%,0)
  4476. DA%<>0
  4477. DA%=1<<9
  4478. shell_IconSetState(a%,r%,DA%,1<<9)
  4479. %*|Stop PROCshell_IconSetRightJust
  4480. %*|Start PROCshell_IconSetLeftJust
  4481. shell_IconSetLeftJust(a%,r%)
  4482. shell_IconSetHCentred(a%,r%,0)
  4483. shell_IconSetRightJust(a%,r%,0)
  4484. $*|Stop PROCshell_IconSetLeftJust
  4485. #)*|Start PROCshell_IconSetUnselectable
  4486. shell_IconSetUnselectable(a%,r%,wA%)
  4487. wA%<>0
  4488. wA%=1<<22
  4489. shell_IconSetState(a%,r%,wA%,1<<22)
  4490. wA%<>0
  4491. shell_IconHasCaret(a%,r%)
  4492. &400D2,-1
  4493. /(*|Stop PROCshell_IconSetUnselectable
  4494. 3#*|Start PROCshell_IconSelectAll
  4495. shell_IconSelectAll(a%)
  4496. d%,I%
  4497. 6"d%=
  4498. shell_HeapBlockFetch(&7D0)
  4499. I%=d%+64:!d%=a%
  4500. d%!8=1<<21:d%!&C=1<<21
  4501. &400D6,!d%,I%,5<<21,0<<21
  4502. !I%>-1
  4503. d%!4=!I%
  4504. &400CD,,d%
  4505. =    I%+=4
  4506. shell_HeapBlockReturn(d%)
  4507. B"*|Stop PROCshell_IconSelectAll
  4508. F%*|Start PROCshell_IconDeselectAll
  4509. shell_IconDeselectAll(a%)
  4510. d%,I%
  4511. I"d%=
  4512. shell_HeapBlockFetch(&7D0)
  4513. J&I%=d%+64:!d%=a%:d%!8=0:d%!&C=1<<21
  4514. &400D6,!d%,I%,5<<21,1<<21
  4515. !I%>-1
  4516. d%!4=!I%
  4517. &400CD,,d%
  4518. O    I%+=4
  4519. shell_HeapBlockReturn(d%)
  4520. T$*|Stop PROCshell_IconDeselectAll
  4521. X'*|Start PROCshell_IconSetSpriteArea
  4522. shell_IconSetSpriteArea(o%,WD%,EJ%)
  4523. 3)=2)
  4524. 256)<>0)
  4525. WD%!4=EJ%
  4526. ^&*|Stop PROCshell_IconSetSpriteArea
  4527. b**|Start PROCshell_IconGetSelectedIcons
  4528. shell_IconGetSelectedIcons(a%,BC%,
  4529. zH%=(BC%<<16)+(1<<21)
  4530. &400D6,a%,LA%,zH%,(BC%<<16)+(1<<21)
  4531. i)*|Stop PROCshell_IconGetSelectedIcons
  4532. m!*|Start FNshell_IconIndirSize
  4533. shell_IconIndirSize(OB%,o%,WD%,X%)
  4534. NB%,BI%,i%,EE%
  4535. &800100)=256
  4536. NB%=WD%!8
  4537. (WD%!4<>-1)
  4538. BI%=WD%!4
  4539. #X%=OB%+BI%
  4540. x    i%+=1
  4541. EE%<32
  4542. NB%+=+i%
  4543. }    NB%=0
  4544.  *|Stop FNshell_IconIndirSize
  4545. (*|Start PROCshell_IconGetBoundingBox
  4546. shell_IconGetBoundingBox(e%,h%,
  4547. Icons_GetState(e%,h%)
  4548. "tC%=_c_Icon_GetIconStateBlk%!8
  4549. #uC%=_c_Icon_GetIconStateBlk%!&C
  4550. #vC%=_c_Icon_GetIconStateBlk%!16
  4551. #wC%=_c_Icon_GetIconStateBlk%!20
  4552. '*|Stop PROCshell_IconGetBoundingBox
  4553. !*|Start PROCshell_IconDragBox
  4554. shell_IconDragBox(e%,h%)
  4555. A$,c%,k%,JA%,x%,B$,j%
  4556. EI%,l%,C,D,FI%,o%,AC%,GI%,eA%,TA$
  4557. shell_HeapBlockFetch(&64+(
  4558. shell_WindowCountIcons(e%)*32))
  4559. !l%=e%
  4560. &400CC,,l%
  4561. C=l%!4-l%!20
  4562. D=l%!16-l%!24
  4563. FI%=l%!68
  4564. l%!4=h%
  4565. &400CE,,l%
  4566. l%!0=e%
  4567. l%!4=_c_Icons_IconDragType%
  4568. o%=l%!24
  4569. AC%=l%!32
  4570. l%!8=l%!8+C
  4571. l%!&C=l%!&C+D
  4572. l%!16=l%!16+C
  4573. l%!20=l%!20+D
  4574.  l%!24=_c_Icons_DragBBoxXMin%
  4575.  l%!28=_c_Icons_DragBBoxYMin%
  4576.  l%!32=_c_Icons_DragBBoxXMax%
  4577.  l%!36=_c_Icons_DragBBoxYMax%
  4578. 6,&A1,28
  4579. ,,eA%
  4580. GI%=((eA%
  4581. 2)=2)
  4582.     LE%=
  4583. shell_DataSaveDragInProgress
  4584. eA%=o%
  4585. &TA$=
  4586. shell_IconGetCommand(AC%,"s")
  4587. shell_OK(
  4588. shell_MessageNoArgs(_c_Icons_NotASpriteIconMess$))
  4589. TA$<>""
  4590. &42400,_c_Icons_DragFlags%,FI%,TA$,l%+8
  4591.     LE%=
  4592. &400D0,,l%
  4593. shell_HeapBlockReturn(l%)
  4594. shell_HandleSlider(e%,h%)
  4595.  *|Stop PROCshell_IconDragBox
  4596. "*|Start PROCshell_IconDragBox2
  4597. shell_IconDragBox2(e%,h%)
  4598. l%,C,D,o%,AC%
  4599. shell_HeapBlockFetch(&64+(
  4600. shell_WindowCountIcons(e%)*32))
  4601. !l%=e%
  4602. &400CC,,l%
  4603. C=l%!4-l%!20
  4604. D=l%!16-l%!24
  4605. l%!4=h%
  4606. &400CE,,l%
  4607. l%!0=e%
  4608. l%!4=_c_Icons_IconDragType%
  4609. o%=l%!24
  4610. AC%=l%!32
  4611. l%!8=l%!8+C
  4612. l%!&C=l%!&C+D
  4613. l%!16=l%!16+C
  4614. l%!20=l%!20+D
  4615.  l%!24=_c_Icons_DragBBoxXMin%
  4616.  l%!28=_c_Icons_DragBBoxYMin%
  4617.  l%!32=_c_Icons_DragBBoxXMax%
  4618.  l%!36=_c_Icons_DragBBoxYMax%
  4619. &400D0,,l%
  4620. shell_HeapBlockReturn(l%)
  4621. !*|Stop PROCshell_IconDragBox2
  4622. #*|Start FNshell_IconGetBGColour
  4623. shell_IconGetBGColour(a%,r%)
  4624. XD%,l%
  4625. shell_HeapBlockFetch(40)
  4626. l%!0=a%
  4627. l%!4=r%
  4628. &400CE,,l%
  4629. XD%=(l%!24>>28)
  4630. shell_HeapBlockReturn(l%)
  4631. "*|Stop FNshell_IconGetBGColour
  4632. #*|Start FNshell_IconGetFGColour
  4633. shell_IconGetFGColour(a%,r%)
  4634. XD%,l%
  4635. shell_HeapBlockFetch(40)
  4636. l%!0=a%
  4637. l%!4=r%
  4638. &400CE,,l%
  4639. XD%=(l%!24>>24)
  4640. shell_HeapBlockReturn(l%)
  4641. "*|Stop FNshell_IconGetFGColour
  4642. '*|Start PROCshell_IconEnsureVisible
  4643. shell_IconEnsureVisible(e%,h%)
  4644. eB%,oB%,QG%
  4645. RG%,SG%,TG%
  4646. DF%,EF%,FF%,GF%
  4647. HF%,IF%
  4648. XG%,YG%
  4649. JF%,KF%
  4650. LF%,MF%
  4651. h%>=0
  4652. !eB%=
  4653. shell_HeapBlockFetch(36)
  4654. !oB%=
  4655. shell_HeapBlockFetch(40)
  4656. !eB%=e%
  4657. &400CB,,eB%
  4658. QG%=eB%!4
  4659. RG%=eB%!8
  4660. SG%=eB%!&C
  4661. TG%=eB%!16
  4662. HF%=eB%!20
  4663. IF%=eB%!24
  4664. YG%=SG%-QG%
  4665. XG%=TG%-RG%
  4666. oB%!0=e%
  4667. oB%!4=h%
  4668. &400CE,,oB%
  4669. DF%=oB%!8
  4670. EF%=oB%!&C
  4671. FF%=oB%!16
  4672. GF%=oB%!20
  4673. JF%=HF%
  4674. MF%=IF%
  4675. LF%=HF%+YG%
  4676. KF%=IF%-XG%
  4677. EF%<KF%
  4678. shell_WindowScrollBy(e%,0,EF%-KF%)
  4679. GF%>MF%
  4680. shell_WindowScrollBy(e%,0,GF%-MF%)
  4681. FF%>LF%
  4682. shell_WindowScrollBy(e%,FF%-LF%,0)
  4683. DF%<JF%
  4684. shell_WindowScrollBy(e%,DF%-JF%,0)
  4685. shell_HeapBlockReturn(eB%)
  4686. shell_HeapBlockReturn(oB%)
  4687. H&*|Stop PROCshell_IconEnsureVisible
  4688. L"*|Start PROCshell_Icon_SetFont
  4689. shell_Icon_SetFont(e%,h%,DJ%)
  4690. shell_IconSetUsesOutlineFont(e%,h%,
  4691. shell_IconSetState(e%,h%,DJ%<<24,-&1000000)
  4692. T!*|Stop PROCshell_Icon_SetFont
  4693. #*|Start FN_shell_ProgEvnts_Init
  4694. _shell_ProgEvnts_Init
  4695. #_m_ProgEvnts_DeskFontHandle%=-1
  4696. ,_m_ProgEvnts_DeskFontChangeHandlerFN$=""
  4697. +_m_ProgEvnts_PaletteChangeHandlerFN$=""
  4698. (_m_ProgEvnts_ModeChangeHandlerFN$=""
  4699. )_m_ProgEvnts_SaveDesktopHandlerFN$=""
  4700. ,_m_ProgEvnts_TaskInitialiseHandlerFN$=""
  4701. +_m_ProgEvnts_TaskCloseDownHandlerFN$=""
  4702. &_m_ProgEvnts_ShutdownHandlerFN$=""
  4703. %_m_ProgEvnts_PreQuitHandlerFN$=""
  4704. "*|Stop FN_shell_ProgEvnts_Init
  4705. 1*|Start PROCshell_AttachDeskFontChangeHandler
  4706. shell_AttachDeskFontChangeHandler(E$)
  4707. shell_OSModuleCheckVersion("UtilityModule",3.5)
  4708. E$<>""
  4709. ,_m_ProgEvnts_DeskFontChangeHandlerFN$=E$
  4710. 0*|Stop PROCshell_AttachDeskFontChangeHandler
  4711. /*|Start PROCshell_ProgEvnts_DeskFontChanged
  4712. shell_ProgEvnts_DeskFontChanged(SI%)
  4713. $_m_ProgEvnts_DeskFontHandle%=SI%
  4714. _m_ProgEvnts_DeskFontChangeHandlerFN$<>""
  4715. ("FN"+_m_ProgEvnts_DeskFontChangeHandlerFN$+"("+
  4716. _m_ProgEvnts_DeskFontHandle%+")")
  4717. .*|Stop PROCshell_ProgEvnts_DeskFontChanged
  4718. 0*|Start PROCshell_AttachPaletteChangeHandler
  4719. shell_AttachPaletteChangeHandler(E$)
  4720. E$<>""
  4721. +_m_ProgEvnts_PaletteChangeHandlerFN$=E$
  4722. ("FN"+E$)
  4723. /*|Stop PROCshell_AttachPaletteChangeHandler
  4724. .*|Start PROCshell_ProgEvnts_PaletteChanged
  4725. shell_ProgEvnts_PaletteChanged
  4726. _m_ProgEvnts_PaletteChangeHandlerFN$<>""
  4727. ("FN"+_m_ProgEvnts_PaletteChangeHandlerFN$)
  4728. -*|Stop PROCshell_ProgEvnts_PaletteChanged
  4729. -*|Start PROCshell_AttachModeChangeHandler
  4730. shell_AttachModeChangeHandler(E$)
  4731. E$<>""
  4732. (_m_ProgEvnts_ModeChangeHandlerFN$=E$
  4733. ("FN"+E$)
  4734. ,*|Stop PROCshell_AttachModeChangeHandler
  4735. +*|Start PROCshell_ProgEvnts_ModeChanged
  4736. shell_ProgEvnts_ModeChanged
  4737. _m_ProgEvnts_ModeChangeHandlerFN$<>""
  4738. ("FN"+_m_ProgEvnts_ModeChangeHandlerFN$)
  4739. **|Stop PROCshell_ProgEvnts_ModeChanged
  4740. +.*|Start PROCshell_AttachSaveDesktopHandler
  4741. shell_AttachSaveDesktopHandler(E$)
  4742. E$<>""
  4743. 2)_m_ProgEvnts_SaveDesktopHandlerFN$=E$
  4744. 7-*|Stop PROCshell_AttachSaveDesktopHandler
  4745. ;+*|Start PROCshell_ProgEvnts_SaveDesktop
  4746. shell_ProgEvnts_SaveDesktop(u%)
  4747. _m_ProgEvnts_SaveDesktopHandlerFN$<>""
  4748. F7z$=
  4749. ("FN"+_m_ProgEvnts_SaveDesktopHandlerFN$)+
  4750. z$=""
  4751. L$z$="Run "+
  4752. shell_GetAppDir+
  4753. &C,2,u%,z$,
  4754. V**|Stop PROCshell_ProgEvnts_SaveDesktop
  4755. b1*|Start PROCshell_AttachTaskInitialiseHandler
  4756. shell_AttachTaskInitialiseHandler(E$)
  4757. E$<>""
  4758. i,_m_ProgEvnts_TaskInitialiseHandlerFN$=E$
  4759. n0*|Stop PROCshell_AttachTaskInitialiseHandler
  4760. r.*|Start PROCshell_ProgEvnts_TaskInitialise
  4761. shell_ProgEvnts_TaskInitialise(NF%,OB$)
  4762. _m_ProgEvnts_TaskInitialiseHandlerFN$<>""
  4763. zUj%=
  4764. ("FN"+_m_ProgEvnts_TaskInitialiseHandlerFN$+"("+
  4765. NF%+","+
  4766. (34)+OB$+
  4767. (34)+")")
  4768. -*|Stop PROCshell_ProgEvnts_TaskInitialise
  4769. 0*|Start PROCshell_AttachTaskCloseDownHandler
  4770. shell_AttachTaskCloseDownHandler(E$)
  4771. E$<>""
  4772. +_m_ProgEvnts_TaskCloseDownHandlerFN$=E$
  4773. /*|Stop PROCshell_AttachTaskCloseDownHandler
  4774. -*|Start PROCshell_ProgEvnts_TaskCloseDown
  4775. shell_ProgEvnts_TaskCloseDown(NF%)
  4776. _m_ProgEvnts_TaskCloseDownHandlerFN$<>""
  4777. ("FN"+_m_ProgEvnts_TaskCloseDownHandlerFN$+"("+
  4778. NF%+")")
  4779. ,*|Stop PROCshell_ProgEvnts_TaskCloseDown
  4780. +*|Start PROCshell_AttachShutdownHandler
  4781. shell_AttachShutdownHandler(E$)
  4782. E$<>""
  4783. &_m_ProgEvnts_ShutdownHandlerFN$=E$
  4784. **|Stop PROCshell_AttachShutdownHandler
  4785. (*|Start PROCshell_ProgEvnts_Shutdown
  4786. shell_ProgEvnts_Shutdown
  4787. _m_ProgEvnts_ShutdownHandlerFN$<>""
  4788. ("FN"+_m_ProgEvnts_ShutdownHandlerFN$)
  4789. '*|Stop PROCshell_ProgEvnts_Shutdown
  4790. **|Start PROCshell_AttachPreQuitHandler
  4791. shell_AttachPreQuitHandler(E$)
  4792. E$<>""
  4793. %_m_ProgEvnts_PreQuitHandlerFN$=E$
  4794. )*|Stop PROCshell_AttachPreQuitHandler
  4795. '*|Start PROCshell_ProgEvnts_PreQuit
  4796. shell_ProgEvnts_PreQuit(xA%)
  4797. j%,d%,OF%,PF%,q%
  4798. _m_ProgEvnts_PreQuitHandlerFN$<>""
  4799. shell_HeapBlockFetch(256)
  4800. OF%=xA%!0
  4801. d%!q%=_Q%!q%
  4802. PF%=d%!4
  4803. OF%<24
  4804. QF%=0
  4805. QF%=d%!20
  4806. d%!&C=d%!8
  4807. &400E7,19,d%,PF%
  4808. ("FN"+_m_ProgEvnts_PreQuitHandlerFN$)<>0
  4809. _closedown%=
  4810. !d%=24
  4811. d%!24=508
  4812. &400E7,8,d%,PF%
  4813. _closedown%=
  4814. shell_HeapBlockReturn(d%)
  4815. &*|Stop PROCshell_ProgEvnts_PreQuit
  4816. *|Start FN_shell_Debug_Init
  4817. _shell_Debug_Init
  4818. *|Stop FN_shell_Debug_Init
  4819. *|Start PROCshell_TraceOn
  4820. shell_TraceOn
  4821. _U%!&64=_U%!&64
  4822. shell_BroadcastMessage(&43B00,"ShellDBug:TraceOn")
  4823. *|Stop PROCshell_TraceOn
  4824. *|Start PROCshell_TraceOff
  4825. shell_TraceOff
  4826. (_U%!&64
  4827. (1<<9))
  4828. _U%!&64=_U%!&64
  4829. (1<<9)
  4830. shell_BroadcastMessage(&43B00,"ShellDBug:TraceOff")
  4831. *|Stop PROCshell_TraceOff
  4832. *|Start PROCshell_TraceInit
  4833. *|Define TraceInit
  4834. shell_TraceInit(_$)
  4835. eA%,G$,D$
  4836. _$<>""
  4837. _U%!44=eA%
  4838.  N'D$=
  4839. shell_OSVarGetVal("Obey$Dir",1)
  4840. shell_Leaf(D$),2)
  4841. shell_BroadcastMessage(&43B00,"ShellDBug:Init Debug messages from "+G$)
  4842. _U%!&64
  4843. _U%!&64=(_U%!&64
  4844. 1<<4)
  4845. *|Stop PROCshell_TraceInit
  4846. *|Start FNshell_TraceIsOn
  4847. shell_TraceIsOn
  4848. _U%!&64
  4849. (1<<9)
  4850. *|Stop FNshell_TraceIsOn
  4851. *|Start PROCshell_Tracef0
  4852. shell_Tracef0(nA$)
  4853. shell_TraceIsOn=
  4854. _U%!44<>-1
  4855. eA%=_U%!44
  4856. #eA%,nA$
  4857. _U%!&94>0
  4858. shell_BroadcastMessage(&43B00,"ShellDBug:Trace "+nA$)
  4859. *|Stop PROCshell_Tracef0
  4860. *|Start PROCshell_Tracef2
  4861. shell_Tracef2(PB%)
  4862. ("MEDIT "+
  4863. ~PB%)
  4864. *|Stop PROCshell_Tracef2
  4865. *|Start PROCshell_TraceExit
  4866. shell_TraceExit
  4867. _U%!44<>-1
  4868. #(_U%!44):_U%!44=-1
  4869. *|Stop PROCshell_TraceExit
  4870. *|Start FN_shell_OS_Init
  4871. _shell_OS_Init
  4872. _m_OS_VAR_BUFFER_SIZE%=256
  4873. _m_OS_VAR_BUFFER%_m_OS_VAR_BUFFER_SIZE%
  4874. J_m_OS_RiscOS_3_Found%=
  4875. shell_OSModuleCheckVersion("UtilityModule",3.1)
  4876. *|Stop FN_shell_OS_Init
  4877. !*|Start FNshell_RO3_Available
  4878. shell_RO3_Available
  4879. =_m_OS_RiscOS_3_Found%
  4880.  *|Stop FNshell_RO3_Available
  4881. "*|Start FNshell_OSCheckVersion
  4882. shell_OSCheckVersion(L)
  4883. shell_OSModuleCheckVersion("UtilityModule",L)
  4884. !*|Stop FNshell_OSCheckVersion
  4885. (*|Start FNshell_OSModuleCheckVersion
  4886. shell_OSModuleCheckVersion(aB$,L)
  4887. KC%,Q$
  4888. ("Set Module$Check Y")
  4889. ("RMEnsure "+aB$+" "+
  4890. L+" Set Module$Check N")
  4891. 35,"Module$Check",_m_OS_VAR_BUFFER%,256,0,0
  4892. ,,KC%
  4893. _m_OS_VAR_BUFFER%?KC%=&D
  4894. ("Unset Module$Check")
  4895. Q$=$_m_OS_VAR_BUFFER%
  4896. Q$="N"
  4897. '*|Stop FNshell_OSModuleCheckVersion
  4898. *|Start FNshell_OSVarExists
  4899. shell_OSVarExists(VA$)
  4900. &20023,VA$,_m_OS_VAR_BUFFER%,-1,0,0
  4901. *|Stop FNshell_OSVarExists
  4902. *|Start FNshell_OSVarGetVal
  4903. shell_OSVarGetVal(VA$,Y)
  4904. WA$,F,RJ%,q%
  4905. &20023,VA$,_m_OS_VAR_BUFFER%,_m_OS_VAR_BUFFER_SIZE%,0,-3*(Y=-1)
  4906. ,,F,RJ%
  4907. #WA$=WA$+
  4908. (_m_OS_VAR_BUFFER%?q%)
  4909. *|Stop FNshell_OSVarGetVal
  4910. $*|Start FNshell_OSReadCommandArg
  4911. shell_OSReadCommandArg(Z)
  4912. RF%,h$,c%
  4913. h$="":c%=0
  4914. RF%?c%<>0
  4915. (RF%?c%)
  4916.     c%+=1
  4917. 34)+1)
  4918. 34)+2)
  4919. #*|Stop FNshell_OSReadCommandArg
  4920. *|Start FN_shell_Menus_Init
  4921. _shell_Menus_Init
  4922. _c_Menu_MinMenuItems%=&A
  4923. != _m_Menu_HandleLastOpened%=-1
  4924. _m_Menu_SubLastOpened%=-1
  4925. !?    jG%=0
  4926. !@    kG%=0
  4927. *|Stop FN_shell_Menus_Init
  4928. *|Start PROCshell_OpenMenu
  4929. shell_OpenMenu(SA%,TA%,s%)
  4930. shell_ExReg_FontMenu_Loaded
  4931. shell_FontMenu_GetHandle
  4932. &400D4,,s%,SA%-64,TA%
  4933. _Q%!0=SA%
  4934. _Q%!4=TA%
  4935. &65BC5,s%,_Q%
  4936. _Q%!0=SA%
  4937. _Q%!4=TA%
  4938. &65BC5,s%,_Q%
  4939. !W _m_Menu_HandleLastOpened%=s%
  4940. jG%=SA%
  4941. kG%=TA%
  4942. _U%!52=_U%!28
  4943. _U%!56=_U%!32
  4944. *|Stop PROCshell_OpenMenu
  4945. !a *|Start FNshell_MenuLastXPos
  4946. shell_MenuLastXPos
  4947. *|Stop FNshell_MenuLastXPos
  4948. !g *|Start FNshell_MenuLastYPos
  4949. shell_MenuLastYPos
  4950. *|Stop FNshell_MenuLastYPos
  4951. !o"*|Start FNshell_MenuLastHandle
  4952. shell_MenuLastHandle
  4953. =_m_Menu_HandleLastOpened%
  4954. !s!*|Stop FNshell_MenuLastHandle
  4955. !w%*|Start FNshell_MenuSubLastHandle
  4956. shell_MenuSubLastHandle
  4957. =_m_Menu_SubLastOpened%
  4958. !{$*|Stop FNshell_MenuSubLastHandle
  4959. !~$*|Start PROCshell_MenuAttachDbox
  4960. shell_MenuAttachDbox(s$)
  4961. "Menu_SetSubHandle",_U%!8,
  4962. shell_MenuString(s$),1
  4963. #*|Stop PROCshell_MenuAttachDbox
  4964. !*|Start PROCshell_MenuWarning
  4965. shell_MenuWarning(_Q%)
  4966. O$,SH%,SA%,TA%,j%,_temp%,iA%,L$,GC%,d%
  4967. #SA%=_Q%!24:TA%=_Q%!28:_U%!264=0
  4968. _U%!20<>0
  4969. *|ifdef PROCshell_TraceInit
  4970. *|endif
  4971. shell_DeleteWindow(_U%!20)
  4972. *|ifdef PROCshell_TraceInit
  4973. *|endif
  4974. _Q%!20
  4975. _U%!&E4
  4976. shell_WindowRetitle(_U%!&E4,
  4977. shell_MessageNoArgs("warning"))
  4978. shell_IconPutData(_U%!&E4,1,
  4979. shell_MessageNoArgs("SHELLMSG07"),0)
  4980. &400E8,,_U%!&E4,SA%,TA%
  4981. CGC%=
  4982. shell_MenuGetItemAddress(_m_Menu_HandleLastOpened%,_Q%+32)
  4983. shell_HeapBlockExists(GC%!4)
  4984. shell_MenuWarnDBox(GC%,SA%,TA%)
  4985. shell_HeapBlockFetch(32)
  4986. &45BC4,_m_Menu_HandleLastOpened%,_Q%+32
  4987. shell_FindMenuWarnEvent(d%!8,L$,T$)
  4988. shell_HeapBlockReturn(d%)
  4989. shell_MenuWarnSubMenu(_Q%!20,SA%,TA%,L$,T$)
  4990.  *|Stop PROCshell_MenuWarning
  4991. "*|Start PROCshell_MenuWarnDBox
  4992. shell_MenuWarnDBox(PB%,SA%,TA%)
  4993. g%,y%,j%
  4994. g%=PB%!4
  4995. shell_CreateWindow($g%!0,y%)
  4996. *|ifdef TraceInit
  4997. *|endif
  4998. $g%!4<>""
  4999. *|ifdef TraceInit
  5000. *|endif
  5001. ("FN"+$g%!4+"("+
  5002. y%+")")
  5003. $g%!8<>""
  5004. *|ifdef TraceInit
  5005. *|endif
  5006. ("FN"+$g%!8+"("+
  5007. y%+")")
  5008. &400E8,,y%,SA%,TA%
  5009. _U%!20=y%
  5010. !*|Stop PROCshell_MenuWarnDBox
  5011. %*|Start PROCshell_MenuWarnSubMenu
  5012. shell_MenuWarnSubMenu(ME%,SA%,TA%,L$,T$)
  5013. j%,g%,YD%,i%
  5014. _shell_FontMenuSelFN$=T$
  5015. shell_HeapBlockExists(_U%!&E0)
  5016. shell_HeapBlockReturn(_U%!&E0)
  5017. (_U%!&E0=
  5018. shell_HeapBlockFetch(
  5019. L$+1)
  5020. g%=_U%!&E0
  5021. $g%=L$
  5022. L$<>""
  5023. ("FN"+L$+"(_U%!52,_U%!56)")
  5024. *|ifdef PROCshell_TraceInit
  5025. *|endif
  5026. *|ifdef Using_FontMenu
  5027. ME%=_U%!&FC
  5028. *|ifdef PROCshell_TraceInit
  5029. *|endif
  5030. shell_HeapBlockExists(_U%!256)
  5031. shell_HeapBlockReturn(_U%!256)
  5032. 'i%=0:
  5033. :i%+=4:
  5034. !(_Q%+32+i%)=-1:i%+=4
  5035. 0_U%!256=
  5036. shell_HeapBlockFetch(i%):g%=_U%!256
  5037. g%!i%=!(_Q%+32+i%)
  5038.     i%+=4
  5039. !(_Q%+32+i%)=-1
  5040. g%!i%=!(_Q%+32+i%)
  5041. g%=_U%!256
  5042. *|ifdef PROCshell_TraceInit
  5043. *|endif
  5044. &8D082,
  5045. shell_FontMenuGetLastSelectedFont,_U%!260
  5046. _U%!264=1
  5047. YD%<>_U%!&FC
  5048. shell_FontMenuUpdatePtr(YD%)
  5049. _U%!&FC=YD%:ME%=YD%
  5050. _U%!264=0
  5051. *|endif
  5052. &400E8,,ME%,SA%,TA%
  5053. _m_Menu_SubLastOpened%=ME%
  5054. $*|Stop PROCshell_MenuWarnSubMenu
  5055. #*|Start PROCshell_AttachSubMenu
  5056. shell_AttachSubMenu(UC%,cC%,L$)
  5057. &45BCE,UC%,cC%
  5058. L$<>""
  5059. &45BCC,,
  5060. shell_EventListMenuWarn(UC%,cC%,L$,"")
  5061. "*|Stop PROCshell_AttachSubMenu
  5062. *|Start FNshell_MenuNew
  5063. shell_MenuNew(HB$,Z$,SF%)
  5064. *|ifdef TraceInit
  5065. *|endif
  5066. SF%<_c_Menu_MinMenuItems%
  5067. SF%=_c_Menu_MinMenuItems%
  5068. &45BC1,,HB$,SF%
  5069. shell_MenuList_AddMenu(s%,Z$)
  5070. *|Stop FNshell_MenuNew
  5071. *|Start FNshell_MenuAdd
  5072. shell_MenuAdd(m%,pA$,T$)
  5073. *|ifdef TraceInit
  5074. *|endif
  5075. T$<>""
  5076. &45BC2,m%,pA$,T$
  5077. &45BC2,m%,pA$
  5078. *|Stop FNshell_MenuAdd
  5079. *|Start PROCshell_MenuTick
  5080. shell_MenuTick(PA%,wA%)
  5081. &45BC9,PA%,wA%
  5082. *|Stop PROCshell_MenuTick
  5083. "N"*|Start PROCshell_MenuTickItem
  5084. shell_MenuTickItem(PA%)
  5085. shell_MenuTick(PA%,1)
  5086. "U!*|Stop PROCshell_MenuTickItem
  5087. "Y$*|Start PROCshell_MenuUnTickItem
  5088. shell_MenuUnTickItem(PA%)
  5089. shell_MenuTick(PA%,0)
  5090. "`#*|Stop PROCshell_MenuUnTickItem
  5091. "d#*|Start PROCshell_MenuTickOnly1
  5092. shell_MenuTickOnly1(s%,NA%)
  5093. &45BD1,s%,NA%
  5094. "k"*|Stop PROCshell_MenuTickOnly1
  5095. "o#*|Start PROCshell_MenuTickOnly2
  5096. shell_MenuTickOnly2(PA%)
  5097. &45BD1,PA%
  5098. "t"*|Stop PROCshell_MenuTickOnly2
  5099. *|Start PROCshell_MenuShade
  5100. shell_MenuShade(m%,wA%)
  5101. &45BCB,m%,wA%
  5102. *|Stop PROCshell_MenuShade
  5103.  *|Start PROCshell_MenuDotted
  5104. shell_MenuDotted(PA%,wA%)
  5105. &45BCA,PA%,wA%
  5106. *|Stop PROCshell_MenuDotted
  5107. !*|Start PROCshell_MenuColours
  5108. shell_MenuColours(PA%,wE%,xE%)
  5109. &45BD0,PA%,wE%,xE%
  5110.  *|Stop PROCshell_MenuColours
  5111. "*|Start PROCshell_MenuWritable
  5112. shell_MenuWritable(PA%,wA%,NB%,RA$)
  5113. &45BCD,PA%,wA%,NB%,RA$
  5114. !*|Stop PROCshell_MenuWritable
  5115. !*|Start PROCshell_MenuPutData
  5116. shell_MenuPutData(PA%,F$)
  5117. &45BC8,PA%,F$
  5118.  *|Stop PROCshell_MenuPutData
  5119. #*|Start PROCshell_MenuSortItems
  5120. shell_MenuSortItems(z%,RB$,BJ%,jD%,TF%)
  5121. #VC%=
  5122. shell_MenuGetNrItems(z%)-1
  5123. _shell_MS_handle%=z%
  5124. TF%>VC%
  5125. TF%=VC%
  5126. &406C0
  5127. shell_QuickSort(RB$,"_shell_MS_swap",BJ%,0,TF%)
  5128. &406C1
  5129. "*|Stop PROCshell_MenuSortItems
  5130. "*|Start FNshell_MenuGetNrItems
  5131. shell_MenuGetNrItems(s%)
  5132. z%,t%,oG%
  5133. &45BC7,s%
  5134. z%+=28
  5135. t%=(z%?0
  5136. oG%+=1
  5137. z%+=24
  5138. !*|Stop FNshell_MenuGetNrItems
  5139. #*|Start FNshell_MenuGetNrDotted
  5140. shell_MenuGetNrDotted(s%)
  5141. z%,t%,NE%
  5142. &45BC7,s%
  5143. z%+=28
  5144. t%=(z%?0
  5145. (z%?0
  5146. NE%+=1
  5147. z%+=24
  5148. t%=-1
  5149. "*|Stop FNshell_MenuGetNrDotted
  5150. &*|Start FNshell_MenuGetItemHandler
  5151. shell_MenuGetItemHandler(s%,UF%)
  5152. YB%,f%,XA$
  5153.  YB%=
  5154. shell_HeapBlockFetch(8)
  5155. YB%!0=UF%
  5156. YB%!4=-1
  5157. &45BC4,s%,YB%
  5158. XA$=""
  5159. XA$=$(f%)
  5160. shell_HeapBlockReturn(YB%)
  5161. %*|Stop FNshell_MenuGetItemHandler
  5162. #*|Start FNshell_MenuGetItemText
  5163. shell_MenuGetItemText(s%,UF%)
  5164. YB%,f%,J$
  5165.  YB%=
  5166. shell_HeapBlockFetch(8)
  5167. YB%!0=UF%
  5168. YB%!4=-1
  5169. &45BC4,s%,YB%
  5170. J$=$(f%!&C)
  5171. shell_HeapBlockReturn(YB%)
  5172. "*|Stop FNshell_MenuGetItemText
  5173. %*|Start FNshell_MenuGetItemHandle
  5174. shell_MenuGetItemHandle(s%,nB%)
  5175. f%,PA%,o%
  5176. shell_HeapBlockFetch(40)
  5177. &65BC4,s%,nB%
  5178. ,,f%;o%
  5179.     PA%=0
  5180. PA%=f%!8
  5181. shell_HeapBlockReturn(f%)
  5182. $*|Stop FNshell_MenuGetItemHandle
  5183. # %*|Start FNshell_MenuGetItemHeight
  5184. shell_MenuGetItemHeight(s%)
  5185. &45BC7,s%
  5186. =z%!20
  5187. #&$*|Stop FNshell_MenuGetItemHeight
  5188. #('*|Start FNshell_MenuCalculateHeight
  5189. shell_MenuCalculateHeight(s%)
  5190. #+>oA%=
  5191. shell_MenuGetNrItems(s%)*
  5192. shell_MenuGetItemHeight(s%)
  5193. #,(=oA%+(
  5194. shell_MenuGetNrDotted(s%)*24)
  5195. #.&*|Stop FNshell_MenuCalculateHeight
  5196. #2 *|Start PROCshell_MenuDelete
  5197. shell_MenuDelete(s%,WI%)
  5198. f%,EA%,n%
  5199. s%<>0
  5200. &65BC3,s%,WI%
  5201. shell_MenuList_DeleteMenu(s%)
  5202. *|Stop PROCshell_MenuDelete
  5203. #J"*|Start PROCshell_MenuOpenLast
  5204. shell_MenuOpenLast
  5205. &65BC5,_m_Menu_HandleLastOpened%
  5206. #O!*|Stop PROCshell_MenuOpenLast
  5207. #S"*|Start PROCshell_MenuCloseAll
  5208. shell_MenuCloseAll
  5209. &400D4,,-1
  5210. #X!*|Stop PROCshell_MenuCloseAll
  5211. #\$*|Start FNshell_MenuMakeFromFile
  5212. shell_MenuMakeFromFile(l$,Z$,TB$,_$)
  5213. s%,X%,C$,j%,VC%
  5214. shell_FileExists(_$)
  5215. #c    VC%=0
  5216. C$<>""
  5217. C$,1)<>"#"
  5218. VC%+=1
  5219. #X%=0
  5220. #m s%=
  5221. shell_MenuNew(l$,Z$,VC%)
  5222. C$<>""
  5223. C$,1)<>"#"
  5224. #r j%=
  5225. shell_MenuAdd(s%,C$,TB$)
  5226. #{#*|Stop FNshell_MenuMakeFromFile
  5227. "*|Start FN_shell_MenuList_Init
  5228. _shell_MenuList_Init
  5229. _c_MenuList_HeaderSize%=4
  5230. _c_MenuList_ListTerm%=-1
  5231. _m_MenuList_DataBlk%=-1
  5232. _m_MenuList_NrMenus%=0
  5233. !*|Stop FN_shell_MenuList_Init
  5234. )*|Start FNshell_MenuList_GetSysHandle
  5235. shell_MenuList_GetSysHandle(Z$)
  5236. f%,s%,rA%
  5237. _m_MenuList_DataBlk%<>-1
  5238. _m_MenuList_DataBlk%!f%<>_c_MenuList_ListTerm%
  5239. rA%=_m_MenuList_DataBlk%!f%
  5240. shell_Tracef0("MenuList_GetSysHandle:menu_identifier$ = "+$(rA%+_c_MenuList_HeaderSize%))
  5241. $(rA%+_c_MenuList_HeaderSize%)=Z$
  5242. s%=!rA%
  5243. shell_Tracef0("MenuList_GetSysHandle:menu_handle% = "+
  5244.     f%+=4
  5245. (*|Stop FNshell_MenuList_GetSysHandle
  5246. **|Start FNshell_MenuList_GetIdentifier
  5247. shell_MenuList_GetIdentifier(s%)
  5248. f%,Z$,rA%
  5249. _m_MenuList_DataBlk%<>-1
  5250. _m_MenuList_DataBlk%!f%<>_c_MenuList_ListTerm%
  5251. rA%=_m_MenuList_DataBlk%!f%
  5252. rA%!0=s%
  5253. %Z$=$(rA%+_c_MenuList_HeaderSize%)
  5254.     f%+=4
  5255. )*|Stop FNshell_MenuList_GetIdentifier
  5256. &*|Start PROCshell_MenuList_AddMenu
  5257. shell_MenuList_AddMenu(s%,Z$)
  5258. f%,rA%
  5259. _m_MenuList_DataBlk%=-1
  5260. shell_MenuList_CreateNewList
  5261. G_m_MenuList_DataBlk%=
  5262. shell_HeapBlockExtend(_m_MenuList_DataBlk%,4)
  5263. f%=_m_MenuList_NrMenus%*4
  5264. R_m_MenuList_DataBlk%!f%=
  5265. shell_HeapBlockFetch(_c_MenuList_HeaderSize%+
  5266. (Z$)+1)
  5267. rA%=_m_MenuList_DataBlk%!f%
  5268. rA%!0=s%
  5269. %$(rA%+_c_MenuList_HeaderSize%)=Z$
  5270. _m_MenuList_NrMenus%+=1
  5271. G_m_MenuList_DataBlk%!(_m_MenuList_NrMenus%*4)=_c_MenuList_ListTerm%
  5272. %*|Stop PROCshell_MenuList_AddMenu
  5273. )*|Start PROCshell_MenuList_DeleteMenu
  5274. shell_MenuList_DeleteMenu(s%)
  5275. f%,rA%
  5276. _m_MenuList_NrMenus%>0
  5277. _m_MenuList_NrMenus%=1
  5278. shell_MenuList_DestroyList
  5279. _m_MenuList_DataBlk%!f%<>_c_MenuList_ListTerm%
  5280. rA%=_m_MenuList_DataBlk%!f%
  5281. rA%!0=s%
  5282. %$(rA%+_c_MenuList_HeaderSize%)=""
  5283. rA%!0=0
  5284.     f%+=4
  5285. (*|Stop PROCshell_MenuList_DeleteMenu
  5286. ,*|Start PROCshell_MenuList_CreateNewList
  5287. shell_MenuList_CreateNewList
  5288. shell_MenuList_DestroyList
  5289. 1_m_MenuList_DataBlk%=
  5290. shell_HeapBlockFetch(8)
  5291. 0_m_MenuList_DataBlk%!4=_c_MenuList_ListTerm%
  5292. +*|Stop PROCshell_MenuList_CreateNewList
  5293. $ **|Start PROCshell_MenuList_DestroyList
  5294. shell_MenuList_DestroyList
  5295. _m_MenuList_DataBlk%<>-1
  5296. shell_HeapBlockReturn(_m_MenuList_DataBlk%)
  5297. _m_MenuList_DataBlk%=-1
  5298. _m_MenuList_NrMenus%=0
  5299. $+)*|Stop PROCshell_MenuList_DestroyList
  5300. $D$*|Start FN_shell_StaticList_Init
  5301. _shell_StaticList_Init
  5302. $F    sA%=0
  5303. $H#*|Stop FN_shell_StaticList_Init
  5304. $L/*|Start PROCshell_StaticWindowListAddHandle
  5305. shell_StaticWindowListAddHandle(m%)
  5306. c%,i%,g%
  5307. sA%=0
  5308. $S sA%=
  5309. shell_HeapBlockFetch(8)
  5310. sA%!0=m%
  5311. sA%!4=-1
  5312. shell_SearchStatic(m%)
  5313. c%=-1
  5314. shell_SearchStatic(0)
  5315. c%=-1
  5316. sA%!i%<>-1
  5317. $e    i%+=4
  5318. $g%sA%=
  5319. shell_HeapBlockExtend(sA%,4)
  5320. g%=sA%+i%
  5321. g%!0=m%
  5322. g%!4=-1
  5323. g%=sA%+c%
  5324. g%!0=m%
  5325. $t.*|Stop PROCshell_StaticWindowListAddHandle
  5326. $x0*|Start PROCshell_RemoveStaticWindowFromList
  5327. shell_RemoveStaticWindowFromList(e%)
  5328. c%,i%,w%
  5329. sA%>0
  5330. sA%!i%=e%
  5331. sA%!i%=0
  5332.     i%+=4
  5333. sA%!i%<>-1
  5334. /*|Stop PROCshell_RemoveStaticWindowFromList
  5335. .*|Start PROCshell_UpdateStaticWindowHandle
  5336. shell_UpdateStaticWindowHandle(jA%,ZA%)
  5337. shell_SearchStatic(jA%)
  5338. sA%!c%=ZA%
  5339. -*|Stop PROCshell_UpdateStaticWindowHandle
  5340.  *|Start FNshell_SearchStatic
  5341. shell_SearchStatic(m%)
  5342. w%,i%
  5343. w%=-1:i%=0
  5344. sA%<>0
  5345. sA%!i%<>-1
  5346. sA%!i%=m%
  5347.     w%=i%
  5348.     i%+=4
  5349. *|Stop FNshell_SearchStatic
  5350. "*|Start FNshell_IsWindowStatic
  5351. shell_IsWindowStatic(e%)
  5352. -1,-2
  5353. _U%!20
  5354. shell_SearchStatic(e%)>-1
  5355. !*|Stop FNshell_IsWindowStatic
  5356. "*|Start FN_shell_DataLoad_Init
  5357. _shell_DataLoad_Init
  5358. tG%=-1
  5359. PE%=24
  5360. XC%=-1
  5361. YA$=""
  5362. vG%=-1
  5363. wG%=-1
  5364. ZA$=""
  5365. "AA$=
  5366. shell_OSReadCommandArg(1)
  5367. AA$<>""
  5368.     XF%=
  5369. shell_FileType(AA$)
  5370.     XF%=
  5371. xG%=-1
  5372. !SB%=0
  5373. !OJ%=0
  5374. !_EVNTS_DATALOAD_DATAOFFSET%=0
  5375. !*|Stop FN_shell_DataLoad_Init
  5376. $*|Start PROCshell_AttachDataLoad
  5377. shell_AttachDataLoad(e%,h%,tA%,O$,yG%)
  5378. b%,c%,A$,p%,VA%
  5379. aD%,i%,YC%,zJ%,RE%
  5380. e%=_IBAR_RIGHT%
  5381. e%=_IBAR_LEFT%
  5382. tG%=h%
  5383. tA%=tA%
  5384. 1<<31
  5385. tA%=-1
  5386. shell_GetWindowIdentifier(e%)
  5387. Evnts_GetEvntListOffset(A$,h%,SB%,PE%,
  5388. b%=!SB%
  5389. VA%=b%!4
  5390. b%+=c%
  5391. $b%=A$
  5392. b%!&C=h%
  5393. aD%=b%!16
  5394. aD%=-1
  5395. tA%<>-1
  5396. "b%!16=
  5397. shell_HeapBlockFetch(8)
  5398. aD%=b%!16
  5399. aD%!0=tA%
  5400. aD%!4=-1
  5401. b%!16=-1
  5402. %+"b%!20=
  5403. shell_HeapBlockFetch(8)
  5404. YC%=b%!20
  5405. %-(YC%!0=
  5406. shell_HeapBlockFetch(
  5407. (O$)+1)
  5408. YC%!4=-1
  5409. g%=YC%!0
  5410. $g%=O$
  5411. tA%=-1
  5412. shell_HeapBlockReturn(b%!16)
  5413. shell_HeapBlockReturn(b%!20)
  5414. b%!16=-1
  5415. YC%=b%!20
  5416. %=%!YC%=
  5417. shell_HeapBlockFetch(
  5418. O$+1)
  5419. g%=!YC%
  5420. $g%=O$
  5421. %D)b%!16=
  5422. shell_HeapBlockExtend(b%!16,4)
  5423. %F)b%!20=
  5424. shell_HeapBlockExtend(b%!20,4)
  5425. g%=b%!16
  5426. g%!i%<>-1
  5427. %L    i%+=4
  5428. g%!i%=tA%
  5429. g%!(i%+4)=-1
  5430. g%=b%!20
  5431. %S&g%!i%=
  5432. shell_HeapBlockFetch(
  5433. O$+1)
  5434. g%=g%!i%
  5435. $g%=O$
  5436. AA$<>""
  5437. 1<<31
  5438. RE%=tA%
  5439. 1<<31
  5440. RE%=tA%
  5441. xG%=RE%
  5442. shell_FileExists(AA$)
  5443. shell_MessageSendDataLoad(RE%,AA$)
  5444. %z    XF%=
  5445. #*|Stop PROCshell_AttachDataLoad
  5446. )*|Start PROCshell_EvntHandle_DataLoad
  5447. shell_EvntHandle_DataLoad(SE%,xC%)
  5448. XC%=SE%!40
  5449. wG%=SE%!20
  5450. vG%=SE%!24
  5451.  YA$=
  5452. shell_GetString(SE%+44)
  5453. DataLoad_OKToLoad(xC%)
  5454. DataLoad_ProcessDClickLoad
  5455. 'ZA$=
  5456. shell_GetWindowIdentifier(wG%)
  5457. DataLoad_ProcessDragLoad
  5458. (*|Stop PROCshell_EvntHandle_DataLoad
  5459. **|Start PROCDataLoad_ProcessDClickLoad
  5460. DataLoad_ProcessDClickLoad
  5461. Evnts_GetEvntListOffset("iconbar",tG%,SB%,PE%,
  5462. DataLoad_ProcessLoadRequest
  5463. )*|Stop PROCDataLoad_ProcessDClickLoad
  5464. (*|Start PROCDataLoad_ProcessDragLoad
  5465. DataLoad_ProcessDragLoad
  5466. Evnts_GetEvntListOffset(ZA$,vG%,SB%,PE%,
  5467. b%=!SB%
  5468. Evnts_GetEvntListOffset(ZA$,-1,SB%,PE%,
  5469. b%=!SB%,
  5470. DataLoad_ProcessLoadRequest
  5471. '*|Stop PROCDataLoad_ProcessDragLoad
  5472. +*|Start PROCDataLoad_ProcessLoadRequest
  5473. DataLoad_ProcessLoadRequest
  5474. c%>-1
  5475. b%=!SB%
  5476. b%+=c%
  5477. AH%=b%!16
  5478. DataLoad_CheckType(AH%,
  5479. RI%=_Q%!&C
  5480. _Q%!&C=_Q%!8
  5481. _Q%!16=4
  5482. &400E7,18,_Q%,_Q%!4
  5483. _U%!&64
  5484. VB%=-1
  5485. _U%!&64=_U%!&64
  5486. $VB%=
  5487. shell_LoadFile(RI%=_U%!&6C)
  5488. DataLoad_CallUserFN(VB%,AH%,_Q%!36,b%)
  5489. _U%!&9C<>0
  5490. shell_HeapBlockReturn(_U%!&9C)
  5491. _U%!&9C=0
  5492. **|Stop PROCDataLoad_ProcessLoadRequest
  5493.  *|Start FNDataLoad_CheckType
  5494. DataLoad_CheckType(dA%,xC%)
  5495. pJ%,i%,w%,g%,TE%
  5496. i%=0:w%=-1:TE%=
  5497. _U%!&64
  5498. _U%!&64=_U%!&64
  5499. dA%=-1
  5500. dA%!i%<>-1
  5501. g%=dA%!i%
  5502. 1<<31
  5503. g%=g%
  5504. 1<<31
  5505.     TE%=
  5506.     TE%=
  5507. g%=XC%
  5508.     w%=i%
  5509. _U%!&64=_U%!&64
  5510.     i%+=4
  5511. (XC%>=4096)
  5512. w%=-1
  5513. w%<>-1
  5514. *|Stop FNDataLoad_CheckType
  5515. #*|Start PROCDataLoad_CallUserFN
  5516. DataLoad_CallUserFN(VB%,dA%,_file_size%,b%)
  5517. i%,w%,fB%,j%,CH%,IA$
  5518.     w%=-1
  5519. dA%=-1
  5520. dA%!i%<>-1
  5521. fB%=dA%!i%
  5522. 1<<31
  5523. fB%=fB%
  5524. 1<<31
  5525. fB%=XC%
  5526. w%=i%
  5527.     i%+=4
  5528. CH%=b%!20
  5529. IA$=$(CH%!w%)
  5530. IA$<>""
  5531. shell_Tracef0("UserFNLoadFile:About to call FN"+IA$+"("+
  5532. VB%+","+
  5533. XC%+",m_DLoad_FileName$,"+
  5534. _file_size%+")")
  5535. shell_Tracef0("UserFNLoadFile:filename is '"+YA$+"'")
  5536. &$Ij%=
  5537. ("FN"+IA$+"("+
  5538. VB%+","+
  5539. XC%+","+
  5540. 34+YA$+
  5541. 34+","+
  5542. _file_size%+")")
  5543. &)"*|Stop PROCDataLoad_CallUserFN
  5544. *|Start FNDataLoad_OKToLoad
  5545. DataLoad_OKToLoad(xC%)
  5546. t%,aA$,rA$
  5547. shell_Tracef0("DataLoad_OKToLoad:Message reason code was 3, normal drag load..")
  5548. shell_Tracef0("DataOpenOKToLoad:Message reason code was 5, double click load..")
  5549. &A5aA$=
  5550. shell_OSVarGetVal("Alias$@RunType_"+
  5551. ~XC%,1)
  5552. shell_Tracef0("DataLoad_OKToLoad:Alias$@RunType="+aA$)
  5553. shell_Branch(aA$)
  5554. shell_Leaf(rA$)="!"+
  5555. shell_GetAppName
  5556. *|Stop FNDataLoad_OKToLoad
  5557. &P"*|Start PROCshell_ListDataLoad
  5558. shell_ListDataLoad
  5559. k%,f%,VA%,i%,dA%,zC%
  5560. h%,q%,U$,cA$
  5561. k%=!SB%
  5562. VA%=k%!4
  5563. Evnts_DebugListHeader ("DataLoad ","Window       Icon  Filetype NL LoadFN")
  5564. shell_Tracef0("No DataLoad Events found")
  5565. f%=_EVNTS_HEADER_SIZE%
  5566. A$=$(k%+f%)
  5567. h%=k%!(f%+&C)
  5568. dA%=k%!(f%+16)
  5569. zC%=k%!(f%+20)
  5570. dA%!i%<>-1
  5571. &j*U$=
  5572. shell_StringPadTrailing(A$,".",&C)
  5573. &k.U$+=" "+
  5574. shell_StringPadLeading(
  5575. h%," ",3)
  5576. fB%=dA%!i%
  5577. 1<<31
  5578. cA$=" Y  "
  5579. fB%=fB%
  5580. 1<<31
  5581. cA$=" N  "
  5582. &s!U$+="     &"+
  5583. ~(fB%)+"  "+cA$
  5584. U$+=$(zC%!i%)
  5585. shell_Tracef0(U$)
  5586. &v    i%+=4
  5587. f%+=nJ%
  5588. shell_Tracef0(" ")
  5589. !*|Stop PROCshell_ListDataLoad
  5590. "*|Start PROCDataLoad_SaveEvnts
  5591. DataLoad_SaveEvnts(u%)
  5592. b%,cA%,cD%,q%,f%
  5593. dA%,zC%,i%,B$,dF%
  5594. b%=!SB%
  5595. #u%,0
  5596. cA%=!b%
  5597. #u%,1
  5598. &C,2,u%,b%,cA%+
  5599. Evnts_GetHeaderSize
  5600. cD%=b%!4
  5601. Evnts_GetHeaderSize
  5602. dA%=b%!(f%+16)
  5603. zC%=b%!(f%+20)
  5604. dA%!i%<>-1
  5605.     i%+=4
  5606. #u%,i%/4
  5607. &C,2,u%,dA%,i%+4
  5608. dF%=0
  5609. #u%,$(zC%!dF%)
  5610. !*|Stop PROCDataLoad_SaveEvnts
  5611. "*|Start PROCDataLoad_LoadEvnts
  5612. DataLoad_LoadEvnts(u%)
  5613. DH%,cA%,b%,_J%,cD%
  5614. f%,i%,dA%,zC%,tA%,cI%
  5615. DH%=1
  5616. DataLoad_ReadWord(u%)
  5617. shell_HeapBlockFetch(cA%)
  5618. !SB%=b%
  5619. !b%=cA%
  5620. &C,4,u%,b%+4,cA%+
  5621. Evnts_GetHeaderSize-4
  5622. cD%=b%!4
  5623. Evnts_GetHeaderSize
  5624.  dA%=
  5625. shell_HeapBlockFetch(4)
  5626. DataLoad_ReadWord(u%)
  5627. DataLoad_ReadWord(u%)
  5628. dA%!i%=tA%
  5629. tA%<>-1
  5630. %dA%=
  5631. shell_HeapBlockExtend(dA%,4)
  5632.     i%+=4
  5633. tA%=-1
  5634. b%!(f%+16)=dA%
  5635. !*|Stop PROCDataLoad_LoadEvnts
  5636. *Start FNDataLoad_ReadWord
  5637. DataLoad_ReadWord(u%)
  5638. ZD%?0=
  5639. ZD%?1=
  5640. ZD%?2=
  5641. ZD%?3=
  5642.     =!ZD%
  5643. *Stop FNDataLoad_ReadWord
  5644. "*|Start FN_shell_DataSave_Init
  5645. _shell_DataSave_Init
  5646. !dD%=0
  5647. !eD%=0
  5648.     iI%=0
  5649. tA$=""
  5650. gF%=-1
  5651. fD%=-1
  5652. dA$=""
  5653.     u$=""
  5654. EH%=-1
  5655. gD%=-1
  5656. DC%=-1
  5657. fA$=""
  5658. tI%=-1
  5659. hD%=-1
  5660. ZC%=-1
  5661. kF%=-1
  5662. AJ%=-1
  5663. YE%=-1
  5664. ',    LE%=
  5665. '-    iD%=
  5666. KB$="SHELLMSG29"
  5667. LB$="SHELLMSG28"
  5668. jB$="SHELLMSG19"
  5669. MB$="SHELLMSG21"
  5670. iB$="SHELLMSG39"
  5671. '6    FJ%=6
  5672. JJ%=&64
  5673. JH%=32
  5674. '<!*|Stop FN_shell_DataSave_Init
  5675. '@$*|Start PROCshell_AttachDataSave
  5676. shell_AttachDataSave(e%,h%,lF%,tA%,EI%,B$)
  5677. A$,c%,b%,VA%,p%
  5678. shell_IconIsSprite(e%,h%)
  5679. shell_OK(
  5680. shell_MessageNoArgs(KB$))
  5681. shell_IconSetButtonType(e%,h%,FJ%)
  5682. lF%=0
  5683. lF%=JJ%
  5684. 'R%A$=
  5685. shell_GetWindowIdentifier(e%)
  5686. 'S0c%=
  5687. Evnts_GetEvntListOffset(A$,h%,dD%,JH%,
  5688. b%=!dD%
  5689. VA%=b%!4
  5690. b%+=c%
  5691. $b%=A$
  5692. b%!&C=h%
  5693. b%!16=tA%
  5694. b%!20=EI%
  5695. b%!24=lF%
  5696. !eD%=0
  5697. '_'!eD%=
  5698. shell_HeapBlockFetch(
  5699. (B$)+1)
  5700. p%=b%+28
  5701. Evnts_UpdateData(p%,eD%,iI%,B$)
  5702. 'f#*|Stop PROCshell_AttachDataSave
  5703. 'jN*|Start PROCshell_EvntHandle_DataSaveStartDrag                            
  5704. shell_EvntHandle_DataSaveStartDrag(e%,h%)
  5705. JA%,x%
  5706. 'n    iD%=
  5707. 'o&tA$=
  5708. shell_GetWindowIdentifier(e%)
  5709. 'p2gF%=
  5710. Evnts_GetEvntListOffset(tA$,h%,dD%,JH%,
  5711. gF%>=0
  5712. fD%=!dD%+gF%
  5713. gD%=fD%!16
  5714. EH%=fD%!20
  5715. DC%=fD%!24
  5716. x%=!eD%
  5717. JA%=fD%!28
  5718. fA$=$(x%+JA%)
  5719. '}"dA$=
  5720. shell_IconGetData(e%,EH%)
  5721. dA$=""
  5722. shell_OK(
  5723. shell_MessageNoArgs(LB$))
  5724. shell_IconDragBox(e%,h%)
  5725.     iD%=
  5726. 1*|Stop PROCshell_EvntHandle_DataSaveStartDrag
  5727. 0*|Start PROCshell_EvntHandle_DataSaveEndDrag
  5728. shell_EvntHandle_DataSaveEndDrag
  5729. bA%,xA%,mF%
  5730. &42401
  5731.     LE%=
  5732.     iD%=
  5733. !bA%=
  5734. shell_HeapBlockFetch(30)
  5735. &400CF,,bA%
  5736. tI%=bA%!4
  5737. hD%=bA%!&C
  5738. ZC%=bA%!16
  5739. kF%=bA%!0
  5740. AJ%=bA%!4
  5741. DC%>&8000
  5742. #mF%=
  5743. shell_HeapBlockInfo(DC%)-4
  5744. mF%=DC%
  5745. !xA%=
  5746. shell_HeapBlockFetch(60)
  5747. xA%!0=60
  5748. xA%!&C=0
  5749. xA%!16=1
  5750. xA%!20=hD%
  5751. xA%!24=ZC%
  5752. xA%!28=kF%
  5753. xA%!32=kF%
  5754. xA%!36=mF%
  5755. xA%!40=gD%
  5756. $(xA%+44)=
  5757. shell_Leaf(dA$)
  5758. &400E7,18,xA%,hD%,ZC%
  5759. YE%=xA%!8
  5760. shell_HeapBlockReturn(bA%)
  5761. shell_HeapBlockReturn(xA%)
  5762. /*|Stop PROCshell_EvntHandle_DataSaveEndDrag
  5763. !*|Start PROCshell_DataSaveAck
  5764. shell_DataSaveAck(GA%)
  5765. MH%,j%
  5766. MH%=GA%!&C
  5767. MH%=YE%
  5768. shell_GetString(GA%+44)
  5769. fA$<>""
  5770. ("FN"+fA$+"( "+
  5771. 34+u$+
  5772. 34+" )")
  5773. shell_HeapBlockExists(DC%)
  5774. 8,&A,u$,gD%,,DC%,DC%+
  5775. shell_HeapBlockInfo(DC%)+1
  5776. shell_MessageNoArgs(MB$)
  5777. GA%!36>-1
  5778. GA%!16=3
  5779. GA%!0=256
  5780. GA%!20=hD%
  5781. GA%!24=ZC%
  5782. GA%!40=gD%
  5783.  GA%!36=
  5784. shell_FileLength(u$)
  5785. GA%!&C=GA%!8
  5786. $(GA%+44)=u$+
  5787. &400E7,18,GA%,ZC%,ZC%
  5788. YE%=GA%!8
  5789. Evnts_GetLastWindowClicked<>
  5790. shell_GetDynamicWindowHandle
  5791. shell_CloseWindow(
  5792. Evnts_GetLastWindowClicked)
  5793. shell_MenuCloseAll
  5794. shell_PrintSave(u$,hD%,ZC%,GA%!8,gD%)
  5795. _U%!336>0
  5796. _U%!336-=1
  5797. shell_DoSendPrintSave(&FFF)
  5798.  *|Stop PROCshell_DataSaveAck
  5799. "*|Start PROCshell_ListDataSave
  5800. shell_ListDataSave
  5801. !*|Stop PROCshell_ListDataSave
  5802. "*|Start PROCDataSave_SaveEvnts
  5803. DataSave_SaveEvnts(u%)
  5804. !*|Stop PROCDataSave_SaveEvnts
  5805. !*|Start PROCshell_AckDataLoad
  5806. shell_AckDataLoad(_Q%)
  5807. _Q%!&C<>YE%
  5808.  *|Stop PROCshell_AckDataLoad
  5809. **|Start FNshell_DataSaveDragInProgress
  5810. shell_DataSaveDragInProgress
  5811. )*|Stop FNshell_DataSaveDragInProgress
  5812. (D!*|Start FN_shell_Sliders_Init
  5813. _shell_Sliders_Init
  5814. NH%=-1
  5815. (K    nF%=
  5816. oF%=-1
  5817. QH%=-1
  5818. RH%=-1
  5819. EC%=-1
  5820. _C%=-1
  5821. mA%50
  5822. KA%50
  5823. aE%20
  5824. cJ%50
  5825. *|extract FN_Sliders_Bump
  5826. *|extract FN_Sliders_Drag
  5827. (] *|Stop FN_shell_Sliders_Init
  5828. (a$*|Start PROCshell_SliderSetValue
  5829. shell_SliderSetValue(aC%,_value%)
  5830. b%,b%,VH%,WH%,WA%
  5831. HA%,gA$,l%,iJ%,oJ%
  5832. dJ%,eJ%,fJ%,j%,gA$
  5833. R$,ZB%,bC%,sF%
  5834. aC%<0
  5835. b%=!_EVNTS_SLIDERS_ANCHOR%
  5836. b%+=aC%
  5837. VH%=b%!&C
  5838. WH%=b%!16
  5839. WA%=b%!20
  5840. bC%=b%!36
  5841. gA$=$b%
  5842. (v'HA%=
  5843. shell_GetWindowHandleList(gA$)
  5844. e%=!HA%
  5845. e%<=0
  5846. e%=HA%!4
  5847. mA%!0=e%
  5848. mA%!4=WH%
  5849. &400CE,,mA%
  5850. uF%=mA%!16
  5851. dE%=mA%!8
  5852. eE%=mA%!&C
  5853. vF%=mA%!20
  5854. (eE%)-
  5855. (vF%)
  5856. tF%=uF%-dE%
  5857. mA%!4=VH%
  5858. &400CE,,mA%
  5859. &400C4,,mA%
  5860. mA%!4=e%
  5861. _value%>&64
  5862. _value%=&64
  5863. _value%<=0
  5864. _value%=0
  5865. tF%>sF%
  5866. mA%!16=mA%!8
  5867. mA%!20=mA%!&C
  5868. tF%>sF%
  5869. 6mA%!16=dE%+(uF%*(_value%/&64))-(dE%*(_value%/&64))
  5870. 6mA%!20=eE%+(vF%*(_value%/&64))-(eE%*(_value%/&64))
  5871. b%!36=_value%
  5872. &400C2,,mA%+4
  5873. &400D1,e%,dE%,eE%,uF%,vF%
  5874. ZB%=!_EVNTS_SLIDERS_DATA%
  5875. ZB%>0
  5876. R$=$(ZB%+b%!32)
  5877. R$<>""
  5878. ("FN"+R$+"("+
  5879. _value%+")")
  5880. WA%>=0
  5881. shell_IconPutData(e%,WA%,
  5882. (_value%),
  5883. #*|Stop PROCshell_SliderSetValue
  5884. '*|Start FNshell_AttachSliderHandler
  5885. shell_AttachSliderHandler(e%,cH%,kD%,iC%,wF%,eH%,Y$)
  5886. YI%,c%,A$,b%,p%
  5887. shell_GetWindowIdentifier(e%)
  5888. Evnts_GetEvntListOffset(A$,kD%,_EVNTS_SLIDERS_ANCHOR%,_EVNTS_SLIDERS_REC_SIZE%,
  5889. b%=!_EVNTS_SLIDERS_ANCHOR%
  5890. b%+=c%
  5891. $b%=A$
  5892. b%!&C=kD%
  5893. b%!16=cH%
  5894. b%!20=iC%
  5895. b%!24=wF%
  5896. b%!28=eH%
  5897. b%!36=-1
  5898. !_EVNTS_SLIDERS_DATA%=0
  5899. 2!_EVNTS_SLIDERS_DATA%=
  5900. shell_HeapBlockFetch(1)
  5901. p%=b%+32
  5902. Evnts_UpdateData(p%,_EVNTS_SLIDERS_DATA%,_EVNTS_SLIDERS_DATAOFFSET%,Y$)
  5903. shell_AttachClickSelect(e%,kD%,"_shell_icondrag")
  5904. shell_AttachClickSelect(e%,cH%,"_Sliders_Drag")
  5905. wF%>=0
  5906. shell_AttachBumpHandler(e%,iC%,wF%,eH%,0,&64,1,
  5907. ,"_Sliders_Bump","")
  5908. &*|Stop FNshell_AttachSliderHandler
  5909. *|Start FN_Sliders_Bump
  5910. _Sliders_Bump(ID%,lD%)
  5911. e%,h%,b%,KB%,OA%,cA%
  5912. w%,aC%,A$,mD%,nD%
  5913. shell_GetLastWindowClicked
  5914. shell_GetLastIconClicked
  5915. shell_GetWindowIdentifier(e%)
  5916. b%=!_EVNTS_SLIDERS_ANCHOR%
  5917. cA%=b%!0
  5918. OA%=b%!4
  5919. KB%=_EVNTS_HEADER_SIZE%
  5920. mD%=b%!(KB%+24)
  5921. nD%=b%!(KB%+28)
  5922. A$=$(b%+KB%)
  5923. mD%=h%
  5924. nD%=h%
  5925. aC%=KB%
  5926. !KB%+=_EVNTS_SLIDERS_REC_SIZE%
  5927. KB%>=cA%
  5928. shell_SliderSetValue(aC%,ID%)
  5929. (ID%)
  5930. *|Stop FN_Sliders_Bump
  5931. "*|Start PROCshell_HandleSlider
  5932. shell_HandleSlider(e%,h%)
  5933. A$,b%,iH%,WA%
  5934. KB%,R$,ZB%,bC%,c%
  5935. shell_GetWindowIdentifier(e%)
  5936. b%=!_EVNTS_SLIDERS_ANCHOR%
  5937. Evnts_GetEvntListOffset(A$,h%,_EVNTS_SLIDERS_ANCHOR%,_EVNTS_SLIDERS_REC_SIZE%,
  5938. NH%=c%
  5939. c%>-1
  5940. KB%=b%+c%
  5941. iH%=!(KB%+16)
  5942. WA%=!(KB%+20)
  5943. bC%=!(KB%+36)
  5944. ZB%=!_EVNTS_SLIDERS_DATA%
  5945. ZB%>0
  5946. R$=$(ZB%+KB%!32)
  5947. KA%!0=e%
  5948. KA%!4=iH%
  5949. &400CE,,KA%
  5950. EC%=KA%!16-KA%!8
  5951. _C%=KA%!20-KA%!&C
  5952. RH%=h%
  5953. AK%=WA%
  5954. vA$=R$
  5955. GK%=bC%
  5956. KA%!0=e%
  5957. &400CB,,KA%
  5958. SA%=KA%!4-KA%!20
  5959. TA%=KA%!16-KA%!24
  5960. KA%!4=h%
  5961. &400CE,,KA%
  5962. KA%!4=7
  5963. KA%!8+=SA%
  5964. KA%!&C+=TA%
  5965. KA%!16+=SA%
  5966. KA%!20+=TA%
  5967. KA%!24=KA%!8
  5968. KA%!28=KA%!&C
  5969. EC%>_C%
  5970. KA%!32=KA%!24+EC%
  5971. KA%!36=KA%!20
  5972. KA%!32=KA%!24+EC%
  5973. KA%!36=KA%!28+_C%
  5974. &400D0,,KA%
  5975. )?    nF%=
  5976. )E!*|Stop PROCshell_HandleSlider
  5977. *|Start PROCshell_Slider
  5978. shell_Slider
  5979. e%,oD%,SA%,d%,j%,gE%,TA%
  5980. &400CF,,aE%
  5981. e%=aE%!&C
  5982. oD%=!aE%
  5983. gE%=aE%!4
  5984. oD%<>oF%
  5985. gE%<>QH%
  5986. oF%=oD%
  5987. QH%=gE%
  5988. d%=cJ%
  5989. !d%=e%
  5990. &400CB,,d%
  5991. SA%=oD%-d%!4
  5992. TA%=gE%-d%!16
  5993. d%!4=RH%
  5994. &400CE,,d%
  5995. &400C4,,d%
  5996. d%!4=e%
  5997. EC%>_C%
  5998. d%!16=SA%
  5999. &400C2,,d%+4
  6000. &400D1,e%,d%!8,d%!&C,d%!8+EC%,d%!20
  6001. )c _value%=((SA%-d%!8)*&64)/EC%
  6002. shell_SliderSetValue(NH%,_value%)
  6003. d%!20=TA%
  6004. &400C2,,d%+4
  6005. &400D1,e%,d%!8,d%!&C,d%!8+EC%,d%!20+_C%
  6006. )i!_value%=((TA%-d%!&C)*&64)/_C%
  6007. vA$<>""
  6008. )m#j%=
  6009. ("FN"+vA$+"("+
  6010. _value%+")")
  6011. oF%=oD%
  6012. *|Stop PROCshell_Slider
  6013. )z"*|Start FNshell_SliderGetValue
  6014. shell_SliderGetValue(aC%)
  6015. b%,bC%
  6016. b%=!_EVNTS_SLIDERS_ANCHOR%
  6017. b%+=aC%
  6018. bC%=b%!36
  6019. !*|Stop FNshell_SliderGetValue
  6020. *|Start FN_Sliders_Drag
  6021. _Sliders_Drag(e%,h%)
  6022. b%,OA%,BA%,f%,A$
  6023. w%,cA%
  6024. b%=!_EVNTS_SLIDERS_ANCHOR%
  6025.  BA%=_EVNTS_SLIDERS_REC_SIZE%
  6026. cA%=b%!0
  6027. OA%=k%!4
  6028. f%=_EVNTS_HEADER_SIZE%
  6029. shell_GetWindowIdentifier(e%)
  6030. $(b%+f%)=A$
  6031. b%!(f%+16)=h%
  6032. kD%=b%!(f%+&C)
  6033. f%+=BA%
  6034. f%>=cA%
  6035. shell_IconDragBox(e%,kD%)
  6036. *|Stop FN_Sliders_Drag
  6037. (*|Start FNshell_SliderDragInProgress
  6038. shell_SliderDragInProgress
  6039. '*|Stop FNshell_SliderDragInProgress
  6040. !*|Start FNshell_SliderDragEnd
  6041. shell_SliderDragEnd
  6042.     nF%=
  6043.  *|Stop FNshell_SliderDragEnd
  6044.  *|Start FN_shell_Errors_Init
  6045. _shell_Errors_Init
  6046. _ERRNR_NONFATAL=&D00
  6047. _ERRNR_CLAIMMEM=&903
  6048. _ERRORS_ERR_BLK%256
  6049. *|Stop FN_shell_Errors_Init
  6050. *|Start PROCshell_Error
  6051. shell_Error
  6052. NA%,KA$
  6053. &606C2
  6054. <>_ERRNR_NONFATAL
  6055. <>_ERRNR_CLAIMMEM
  6056. 1<<31)
  6057. shell_FatalError
  6058. shell_OSCheckVersion(3)
  6059. shell_FileExists("Resources:$.Resources.Edit.ThrowBack")
  6060. ("Set Basic$File <"+
  6061. shell_GetAppName+"$BasicFile>")
  6062. "Edit:ThrowBack"
  6063. shell_ErrorBox("Unexpected error:- "+
  6064. $+" (Internal error code "+
  6065. +")")
  6066. +NA%=
  6067. $,"in "+
  6068. 34+"EvntShell:ShellLib")
  6069. NA%>0
  6070. $,NA%-1)
  6071. (KA$+=" (Internal error code "+
  6072. shell_ErrorBox(KA$)
  6073. *|Stop PROCshell_Error
  6074. *|Start PROCshell_OK
  6075. shell_OK(PB$)
  6076. _ERRNR_NONFATAL,PB$
  6077. *|Stop PROCshell_OK
  6078.  *|Start PROCshell_FatalError
  6079. shell_FatalError
  6080. &606C2
  6081. shell_OSCheckVersion(3)
  6082. shell_FileExists("Resources:$.Resources.Edit.ThrowBack")
  6083. 1<<31)
  6084. shell_Exit
  6085. ("Set Basic$File <"+
  6086. shell_GetAppName+"$BasicFile>")
  6087. "Edit:ThrowBack"
  6088. shell_ErrorBox("Unexpected error:- "+
  6089. $+" Internal error code "+
  6090. *|Stop PROCshell_FatalError
  6091. *|Start PROCshell_ErrorBox
  6092. shell_ErrorBox(QB$)
  6093. !_ERRORS_ERR_BLK%=
  6094. *5"$(_ERRORS_ERR_BLK%+4)=QB$+
  6095. =_ERRNR_NONFATAL
  6096. =_ERRNR_CLAIMMEM
  6097. &600DF,_ERRORS_ERR_BLK%,17,"Message from "+
  6098. shell_GetAppName
  6099. &600DF,_ERRORS_ERR_BLK%,1,
  6100. shell_GetAppName
  6101. *|Stop PROCshell_ErrorBox
  6102. *h$*|Start FN_shell_WindowList_Init
  6103. _shell_WindowList_Init
  6104. *l#*|Stop FN_shell_WindowList_Init
  6105. *o#*|Start PROCshell_TemplatesInit
  6106. shell_TemplatesInit(v$,
  6107. pD%,_F%,lH%,FB%
  6108. mH%,NA%,hE%,d$,FA%,nH%,t%
  6109. oH%,qD%
  6110. *t!hE%=
  6111. shell_HeapBlockFetch(&C)
  6112. *u    NA%=0
  6113. *v    FA%=0
  6114. shell_FileLength(v$)
  6115. *y"pH%=
  6116. shell_HeapBlockFetch(mH%)
  6117. pD%=pH%
  6118. shell_TemplateFileInfo(v$,FB%,FA%,t%)
  6119. )rD%=
  6120. shell_HeapBlockFetch(4+(20*FA%))
  6121. _U%!4=rD%
  6122. "qH%=
  6123. shell_HeapBlockFetch(FB%)
  6124. _F%=qH%
  6125. lH%=qH%+FB%
  6126.     FA%=0
  6127.     qD%=4
  6128. &600D9,,v$
  6129. shell_MessageTwoArgs("SHELLMSG34","template",v$)
  6130. $hE%="*"
  6131. &400DB,,pD%,_F%,lH%,_U%!&E8,hE%,NA%
  6132. ,,_F%,,,d$,NA%
  6133. NA%<>0
  6134. rD%!qD%=pD%
  6135. $(rD%+qD%+4)=d$
  6136. rD%!(qD%+16)=-1
  6137. qD%+=20
  6138. shell_Tracef0("TemplatesInit:  Template Loaded: "+d$)
  6139. oH%=(pD%!84)*32
  6140. pD%+=(88+oH%)
  6141. FA%+=1
  6142. NA%=0
  6143. &400DA
  6144. _U%!0=FA%
  6145. shell_Tracef0("TemplatesInit:Templates resource file loaded at       &"+
  6146. ~pH%+" ("+
  6147. FA%+" templates)")
  6148. shell_Tracef0("TemplatesInit:Indirected buffer size used for loading &"+
  6149. ~FB%)
  6150. shell_MessageTwoArgs("SHELLMSG35","template",v$)
  6151. shell_MessageTwoArgs("SHELLMSG36",v$,"template")
  6152. shell_HeapBlockReturn(hE%)
  6153.     eI%=0
  6154. !rD%=FA%
  6155. "*|Stop PROCshell_TemplatesInit
  6156.  *|Start FNshell_WindowLoaded
  6157. shell_WindowLoaded(H$)
  6158. c%,CG%
  6159. shell_GetWindowListOffset(H$)
  6160. c%>=0
  6161. *|Stop FNshell_WindowLoaded
  6162. '*|Start FNshell_GetWindowListOffset
  6163. shell_GetWindowListOffset(H$)
  6164. c%,FA%,LB%,i%
  6165. (H$)>&B
  6166. shell_MessageOneArg("SHELLMSG02",H$)
  6167. #FA%=
  6168. shell_GetNrTemplatesLoaded
  6169. "LB%=
  6170. shell_WindowListGetAddr+4
  6171.     c%=-1
  6172. $(((LB%)+(20*i%))+4)=H$
  6173. c%=i%*20
  6174.     i%+=1
  6175. c%<>-1
  6176. i%>(FA%-1)
  6177. &*|Stop FNshell_GetWindowListOffset
  6178. *|Start FNshell_GetWB
  6179. shell_GetWB(H$)
  6180. c%,JB%,LB%
  6181. shell_GetWindowListOffset(H$)
  6182. 99,H$+":"+
  6183. "LB%=
  6184. shell_WindowListGetAddr+4
  6185. c%>=0
  6186. JB%=LB%!c%
  6187. shell_MessageOneArg("SHELLMSG03",H$)
  6188. *|Stop FNshell_GetWB
  6189. '*|Start FNshell_GetWindowHandleList
  6190. shell_GetWindowHandleList(H$)
  6191. c%,HA%,LB%
  6192. shell_GetWindowListOffset(H$)
  6193. "LB%=
  6194. shell_WindowListGetAddr+4
  6195. c%>=0
  6196. HA%=!(LB%+c%+16)
  6197. shell_MessageOneArg("SHELLMSG03",H$)
  6198. &*|Stop FNshell_GetWindowHandleList
  6199. (*|Start PROCshell_CreateWindowStatic
  6200. shell_CreateWindowStatic(H$,
  6201. shell_GetWB(H$)
  6202. shell_Tracef0("DEBUG::"+
  6203. _B%!64=_U%!16
  6204. &400C1,,_B%
  6205. shell_Tracef0("DEBUG::"+
  6206. shell_StaticWindowListAddHandle(e%)
  6207. shell_WindowListAddHandle(H$,e%)
  6208. '*|Stop PROCshell_CreateWindowStatic
  6209. )*|Start PROCshell_WindowListAddHandle
  6210. shell_WindowListAddHandle(H$,e%)
  6211. rH%,CA%,f%,DG%
  6212. H$=""
  6213. 99,"Bad window name passed to WindowListAddHandle"
  6214. )rH%=
  6215. shell_GetWindowListOffset(H$)+16
  6216. &CA%=
  6217. shell_WindowListGetAddr+4+rH%
  6218. !CA%=-1
  6219. shell_Tracef0("DEBUG::Creating window handle list for window '"+H$+"'")
  6220. shell_Tracef0("DEBUG::Window handle is &"+
  6221. !!CA%=
  6222. shell_HeapBlockFetch(8)
  6223. f%=!CA%
  6224. f%!0=e%
  6225. f%!4=-1
  6226. CA%!16<>-1
  6227. HA%=!CA%
  6228. +%    DG%=
  6229. HA%!f%<>-1
  6230. HA%!f%=0
  6231. HA%!f%=e%
  6232. +)    DG%=
  6233. ++    f%+=4
  6234. shell_Tracef0("DEBUG::Extending window handle list for window '"+H$+"'")
  6235. shell_Tracef0("DEBUG::Window handle is &"+
  6236. +9'!CA%=
  6237. shell_HeapBlockExtend(!CA%,4)
  6238. LB%=!CA%
  6239. LB%!f%<>-1
  6240. +=    f%+=4
  6241. LB%!(f%+0)=e%
  6242. LB%!(f%+4)=-1
  6243. +E(*|Stop PROCshell_WindowListAddHandle
  6244. +I'*|Start FNshell_GetWindowIdentifier
  6245. shell_GetWindowIdentifier(m%)
  6246. CA%,FA%,f%,i%,DA$
  6247. +L#FA%=
  6248. shell_GetNrTemplatesLoaded
  6249. +M"CA%=
  6250. shell_WindowListGetAddr+4
  6251. DA$=""
  6252. -1,-2
  6253. DA$="iconbar"
  6254. CA%!16<>-1
  6255. HA%=CA%!16
  6256. HA%!f%<>-1
  6257. HA%!f%=m%
  6258. DA$=$(CA%+4)
  6259. +[    f%+=4
  6260. +^    i%+=1
  6261. CA%+=20
  6262. DA$<>""
  6263. i%=FA%
  6264. +j&*|Stop FNshell_GetWindowIdentifier
  6265. +n0*|Start PROCshell_RemoveHandleFromWindowList
  6266. shell_RemoveHandleFromWindowList(m%)
  6267. CA%,FA%,I%,f%
  6268. +q#FA%=
  6269. shell_GetNrTemplatesLoaded
  6270. +r"CA%=
  6271. shell_WindowListGetAddr+4
  6272. CA%!16<>-1
  6273. HA%=CA%!16
  6274. HA%!f%<>-1
  6275. HA%!f%=m%
  6276. HA%!f%=0
  6277. +{    f%+=4
  6278. CA%+=20
  6279. /*|Stop PROCshell_RemoveHandleFromWindowList
  6280. ,*|Start PROCshell_UpdateWindowHandleList
  6281. shell_UpdateWindowHandleList(jA%,ZA%)
  6282. CA%,FA%,I%,f%
  6283. #FA%=
  6284. shell_GetNrTemplatesLoaded
  6285. "CA%=
  6286. shell_WindowListGetAddr+4
  6287. CA%!16<>-1
  6288. HA%=CA%!16
  6289. HA%!f%<>-1
  6290. HA%!f%=jA%
  6291. HA%!f%=ZA%
  6292.     f%+=4
  6293. CA%+=20
  6294. +*|Stop PROCshell_UpdateWindowHandleList
  6295. (*|Start FNshell_GetNrTemplatesLoaded
  6296. shell_GetNrTemplatesLoaded
  6297.  CA%=
  6298. shell_WindowListGetAddr
  6299.     =!CA%
  6300. '*|Stop FNshell_GetNrTemplatesLoaded
  6301. %*|Start FNshell_WindowListGetAddr
  6302. shell_WindowListGetAddr
  6303. =_U%!4
  6304. $*|Stop FNshell_WindowListGetAddr
  6305. %*|Start FNshell_WindowHandleKnown
  6306. shell_WindowHandleKnown(e%)
  6307. t%,CA%,w%,I%,FA%,m%
  6308. shell_GetDynamicWindowHandle
  6309. #FA%=
  6310. shell_GetNrTemplatesLoaded
  6311. "CA%=
  6312. shell_WindowListGetAddr+4
  6313. CA%!16<>-1
  6314. HA%=CA%!16
  6315. HA%!f%<>-1
  6316. m%=HA%!f%
  6317. m%=e%
  6318.     f%+=4
  6319. CA%+=20
  6320. $*|Stop FNshell_WindowHandleKnown
  6321. %*|Start PROCshell_WindowListPrint
  6322. shell_WindowListPrint
  6323. CA%,FA%,I%,f%
  6324. #FA%=
  6325. shell_GetNrTemplatesLoaded
  6326. shell_TraceOn
  6327. "CA%=
  6328. shell_WindowListGetAddr+4
  6329. shell_Tracef0("")
  6330. shell_Tracef0("Current Window List ("+
  6331. (FA%)+" templates)")
  6332. shell_Tracef0("-----------------------------------------")
  6333. shell_Tracef0($(CA%+4)+":")
  6334. CA%!16=-1
  6335. shell_Tracef0("No windows defined for this identifier")
  6336. HA%=CA%!16
  6337. HA%!f%<>-1
  6338. shell_Tracef0("  window handle &"+
  6339. ~(HA%!f%))
  6340.     f%+=4
  6341. CA%+=20
  6342. $*|Stop PROCshell_WindowListPrint
  6343. !*|Start FN_shell_Strings_Init
  6344. _shell_Strings_Init
  6345.  *|Stop FN_shell_Strings_Init
  6346. +*|Start FNshell_GetZeroTerminatedString
  6347. shell_GetZeroTerminatedString(sI%)
  6348. "WriteN",sI%,0
  6349. **|Stop FNshell_GetZeroTerminatedString
  6350. *|Start FNshell_GetString
  6351. shell_GetString(sH%)
  6352. zA$,kE%
  6353. ((sH%?kE%)>31
  6354. kE%<&FF)
  6355. zA$+=
  6356. (sH%?kE%)
  6357. kE%+=1
  6358. *|Stop FNshell_GetString
  6359. ,/'*|Start FNshell_StringStripTrailing
  6360. shell_StringStripTrailing(C$,i$)
  6361. C$,1)=i$
  6362. (C$)-1)
  6363. ,6&*|Stop FNshell_StringStripTrailing
  6364. ,:&*|Start FNshell_StringStripLeading
  6365. shell_StringStripLeading(C$,i$)
  6366. C$,1)=i$
  6367. C$,2)
  6368. ,A%*|Stop FNshell_StringStripLeading
  6369. ,E"*|Start FNshell_StringStripAll
  6370. shell_StringStripAll(C$,i$)
  6371. C$,i$)
  6372. C$,I-1)+
  6373. C$,I+1)
  6374. ,T!*|Stop FNshell_StringStripAll
  6375. ,X%*|Start FNshell_StringPadTrailing
  6376. shell_StringPadTrailing(C$,i$,UB%)
  6377. (C$)<UB%
  6378. C$=C$+
  6379. (C$),i$)
  6380. ,_$*|Stop FNshell_StringPadTrailing
  6381. ,c$*|Start FNshell_StringPadLeading
  6382. shell_StringPadLeading(C$,i$,UB%)
  6383. (C$)<UB%
  6384. (C$),i$)+C$
  6385. ,j#*|Stop FNshell_StringPadLeading
  6386. ,n#*|Start FNshell_StringUpperCase
  6387. shell_StringUpperCase(C$)
  6388. (C$)>0
  6389. C$,q%,1)>="a"
  6390. C$,q%,1)<="z"
  6391. C$,q%,1)=
  6392. C$,q%,1))
  6393. ,z"*|Stop FNshell_StringUpperCase
  6394. ,|"*|Start FNshell_StringExchange
  6395. shell_StringExchange(C$,iA$,WB$)
  6396. C$,iA$)
  6397. C$,iA$)
  6398. C$,IB%-1)+WB$+
  6399. C$,IB%+
  6400. !*|Stop FNshell_StringExchange
  6401. )*|Start FNshell_StringArrayGetLongest
  6402. shell_StringArrayGetLongest(A$(),NE%)
  6403. q%,lE%
  6404.     lE%=0
  6405. (A$(q%))>lE%
  6406. (A$(q%))
  6407. (*|Stop FNshell_StringArrayGetLongest
  6408. *|Start FNmem_to_string
  6409. mem_to_string(GA%,c%,wI%)
  6410. GA%?c%<>wI%
  6411. (GA%?c%)
  6412.     c%+=1
  6413. *|Stop FNmem_to_string
  6414. "*|Start FN_shell_Messages_Init
  6415. _shell_Messages_Init
  6416. _MESSAGES_WORK_BLK%256
  6417. _MESSAGE_QUIT=0
  6418. _MESSAGE_DATASAVE=1
  6419. _MESSAGE_DATASAVEACK=2
  6420. _MESSAGE_DATALOAD=3
  6421. _MESSAGE_DATALOADACK=4
  6422. _MESSAGE_RAMFETCH=6
  6423. _MESSAGE_RAMTRANSMIT=7
  6424. _MESSAGE_PREQUIT=8
  6425. _MESSAGE_PALETTECHANGE=9
  6426. _MESSAGE_SAVEDESKTOP=&A
  6427. _MESSAGE_SHUTDOWN=&E
  6428. _MESSAGE_HELP=&502
  6429. _MESSAGE_MENUWARNING=&400C0
  6430. _MESSAGE_MODECHANGE=&400C1
  6431. _MESSAGE_TASKINIT=&400C2
  6432. !_MESSAGE_TASKCLOSEDOWN=&400C3
  6433. _MESSAGE_TASKNAMEIS=&400C7
  6434. $_MESSAGE_DESKFONT_CHANGED=&400CF
  6435. ,_MESSAGE_COLOURPICKERCOLOURCHOICE=&47700
  6436. 4_MESSAGE_COLOURPICKERCLOSEDIALOGUEREQUEST=&47702
  6437. !*|Stop FN_shell_Messages_Init
  6438. &*|Start PROCshell_BroadcastMessage
  6439. shell_BroadcastMessage(xI%,FA$)
  6440. tH%=(
  6441. (FA$)+30)
  6442. _MESSAGES_WORK_BLK%!&C=0
  6443. _MESSAGES_WORK_BLK%!16=xI%
  6444. &$(_MESSAGES_WORK_BLK%+20)=FA$+
  6445. _MESSAGES_WORK_BLK%!0=tH%
  6446. &600E7,17,_MESSAGES_WORK_BLK%,0
  6447. %*|Stop PROCshell_BroadcastMessage
  6448.  *|Start FN_shell_Memory_Init
  6449. _shell_Memory_Init
  6450. *|Stop FN_shell_Memory_Init
  6451. %*|Start PROCshell_HeapManagerInit
  6452. shell_HeapManagerInit(I$,zI%)
  6453. _heap_code%900
  6454. ("LOAD "+I$+"heapcode "+
  6455. ~_heap_code%)
  6456. _heap_code%+0,zI%
  6457. $*|Stop PROCshell_HeapManagerInit
  6458. #*|Start FNshell_HeapBlockExtend
  6459. shell_HeapBlockExtend(uH%,FG%)
  6460. _heap_code%+&C,uH%,FG%
  6461. "*|Stop FNshell_HeapBlockExtend
  6462. "*|Start FNshell_HeapBlockFetch
  6463. shell_HeapBlockFetch(FG%)
  6464. _heap_code%+4,PB%,FG%
  6465. !*|Stop FNshell_HeapBlockFetch
  6466. %*|Start PROCshell_HeapBlockReturn
  6467. shell_HeapBlockReturn(
  6468. shell_HeapBlockExists(iA%)
  6469. _heap_code%+8,iA%
  6470.     iA%=0
  6471. - $*|Stop PROCshell_HeapBlockReturn
  6472. -$#*|Start FNshell_HeapBlockExists
  6473. shell_HeapBlockExists(PB%)
  6474. PB%<&8000
  6475. 99,"No heapblock defined at this address"
  6476. -* j%=
  6477. shell_HeapBlockInfo(PB%)
  6478. -,"*|Stop FNshell_HeapBlockExists
  6479. -/!*|Start FNshell_HeapBlockInfo
  6480. shell_HeapBlockInfo(iA%)
  6481. 29,6,!(_heap_code%+28),iA%
  6482. -5 *|Stop FNshell_HeapBlockInfo
  6483. -9&*|Start FNshell_HeapBlockExtendMid
  6484. -:7*|!Function to extend already allocated heap block.
  6485. -;&*|!a%   = current address of block
  6486. -<L*|!b%   = amount to increase or decrease block size by (-ve to decrease)
  6487. -=,*|!loc% = offset to add or remove memory
  6488. ->4*|!returns address of block (block may be moved)
  6489. shell_HeapBlockExtendMid(iA%,dB%,vH%)
  6490. -A!wH%=
  6491. shell_HeapBlockInfo(iA%)
  6492. _heap_code%+&C,iA%,dB%
  6493. &400F1,_U%!&94,iA%+vH%,_U%!&94,iA%+vH%+dB%,wH%-dB%
  6494. -E%*|Stop FNshell_HeapBlockExtendMid
  6495. *|Start FN_shell_Poll_Init
  6496. _shell_Poll_Init
  6497. xH%256
  6498. _POLL_EARLIEST_TIME%=0
  6499. _POLL_INTERVAL%=&64
  6500. _POLL_PREVINTERVAL%=0
  6501. shell_PollSetInterval(_POLL_INTERVAL%)
  6502. shell_PollSetPrevInterval(_POLL_INTERVAL%)
  6503. _POLL_EARLIEST_TIME%
  6504. -m)_POLL_EARLIEST_TIME%+=_POLL_INTERVAL%
  6505. *|Stop FN_shell_Poll_Init
  6506. *|Start FNshell_PollIdle
  6507. shell_PollIdle(_A%,GG%)
  6508. _U%!&64
  6509. "WimpExt_PrePoll"
  6510. &400E1,_A%,xH%,_POLL_EARLIEST_TIME%
  6511. _U%!&64
  6512. "WimpExt_Action",_U%!&94,xH%,FC%
  6513. *|Stop FNshell_PollIdle
  6514. %*|Start PROCshell_PollSetInterval
  6515. shell_PollSetInterval(HG%)
  6516. _POLL_INTERVAL%=HG%
  6517. $*|Stop PROCshell_PollSetInterval
  6518. )*|Start PROCshell_PollSetPrevInterval
  6519. shell_PollSetPrevInterval(HG%)
  6520. _POLL_PREVINTERVAL%=HG%
  6521. (*|Stop PROCshell_PollSetPrevInterval
  6522. $*|Start FNshell_PollReadInterval
  6523. shell_PollReadInterval
  6524. =_POLL_INTERVAL%
  6525. #*|Stop FNshell_PollReadInterval
  6526. (*|Start FNshell_PollReadPrevInterval
  6527. shell_PollReadPrevInterval
  6528. =_POLL_PREVINTERVAL%
  6529. '*|Stop FNshell_PollReadPrevInterval
  6530. *|Start FNshell_Poll_I
  6531. shell_Poll_I(_A%,GG%)
  6532. _U%!&64
  6533. "WimpExt_PrePoll"
  6534. &400C7,_A%,_Q%
  6535. _U%!&64
  6536. "WimpExt_Action",_U%!&94,_Q%,FC%
  6537. &81686,FC%,,GG%
  6538. *|Stop FNshell_Poll_I
  6539. *|Start FNpoll
  6540. poll(_A%,GG%)
  6541. _U%!&64
  6542. "WimpExt_PrePoll"
  6543. &400C7,_A%,_Q%
  6544. _U%!&64
  6545. "WimpExt_Action",_U%!&94,_Q%,iA%
  6546. *|Stop FNpoll
  6547. !*|Start FN_shell_IntHelp_Init
  6548. _shell_IntHelp_Init
  6549. BK%60
  6550. _IntHelp_IsOn%=
  6551.  *|Stop FN_shell_IntHelp_Init
  6552. %*|Start PROCshell_InteractiveHelp
  6553. shell_InteractiveHelp(_Q%)
  6554. M$,k$,N$,pB%,IG%,hB$,o%
  6555. shell_EvntHandle_HelpTags(_Q%!32,_Q%!36,M$)
  6556. shell_IconGetValidation(_Q%!32,_Q%!36)
  6557. N$<>""
  6558. shell_StringUpperCase(
  6559. N$,1))="I"
  6560. N$,";")
  6561. pB%=0
  6562. N$,2)
  6563. N$,2,pB%-2)
  6564. ApB%=
  6565. shell_StringUpperCase(N$),
  6566. shell_StringUpperCase(";i"))
  6567. FIG%=
  6568. shell_StringUpperCase(N$),
  6569. shell_StringUpperCase(";"),pB%+1)
  6570. pB%>0
  6571. IG%>0
  6572. N$,pB%+2,IG%-pB%-2)
  6573. N$,pB%+2)
  6574. M$<>""
  6575. _Q%!16=&503
  6576. _Q%!&C=_Q%!8
  6577. shell_MessageLookup(M$,"","")
  6578. shell_MessageExpand(k$)
  6579. $(_Q%+20)=k$
  6580. !_Q%=(
  6581. k$+25)
  6582. &400E7,17,_Q%,_Q%!4
  6583. $*|Stop PROCshell_InteractiveHelp
  6584. '*|Start PROCshell_InteractiveHelpOn
  6585. shell_InteractiveHelpOn
  6586. _IntHelp_IsOn%=
  6587. &*|Stop PROCshell_InteractiveHelpOn
  6588. (*|Start PROCshell_InteractiveHelpOff
  6589. shell_InteractiveHelpOff
  6590. _IntHelp_IsOn%=
  6591. '*|Stop PROCshell_InteractiveHelpOff
  6592. ., *|Start FN_shell_PopUps_Init
  6593. _shell_PopUps_Init
  6594. *|Stop FN_shell_PopUps_Init
  6595. .Z!*|Start FN_shell_Bumpers_Init
  6596. _shell_Bumpers_Init
  6597. .^    GJ%=2
  6598. ._    HJ%=4
  6599. .`    IJ%=8
  6600. .f *|Stop FN_shell_Bumpers_Init
  6601. .j'*|Start PROCshell_AttachBumpHandler
  6602. shell_AttachBumpHandler(e%,h%,_H%,AI%,gB%,hB%,MJ%,CI%,XB$,YB$)
  6603. YI%,c%,g%,nA%,kJ%
  6604. A$,b%
  6605. .o%A$=
  6606. shell_GetWindowIdentifier(e%)
  6607. .qSc%=
  6608. Evnts_GetEvntListOffset(A$,_H%,_EVNTS_BUMP_ANCHOR%,_EVNTS_BUMP_REC_SIZE%,
  6609. b%=!_EVNTS_BUMP_ANCHOR%
  6610. b%+=c%
  6611. $b%=A$
  6612. b%!&C=_H%
  6613. b%!16=MJ%
  6614. b%!20=h%
  6615. b%!24=gB%
  6616. b%!28=hB%
  6617. CI%=-1
  6618. b%!40=1
  6619. b%!40=0
  6620. !_EVNTS_BUMP_DATA%=0
  6621. .}/!_EVNTS_BUMP_DATA%=
  6622. shell_HeapBlockFetch(1)
  6623. p%=b%+32
  6624. Evnts_UpdateData(p%,_EVNTS_BUMP_DATA%,_EVNTS_BUMP_DATAOFFSET%,XB$)
  6625. p%=b%+36
  6626. Evnts_UpdateData(p%,_EVNTS_BUMP_DATA%,_EVNTS_BUMP_DATAOFFSET%,YB$)
  6627. Evnts_GetEvntListOffset(A$,AI%,_EVNTS_BUMP_ANCHOR%,_EVNTS_BUMP_REC_SIZE%,
  6628. b%=!_EVNTS_BUMP_ANCHOR%
  6629. b%+=c%
  6630. $b%=A$
  6631. b%!&C=AI%
  6632. CI%=-1
  6633. b%!40=1
  6634. b%!40=0
  6635. b%!40=b%!40
  6636. (1<<2)
  6637. &*|Stop PROCshell_AttachBumpHandler
  6638. (*|Start PROCshell_EvntHandle_Bumpers
  6639. shell_EvntHandle_Bumpers(_window_handle%,_icon_handle%)
  6640. A$,c%,x%,RA%,k%,nE%
  6641. aB%,BD%,gB%,hB%,lD%,KG%,LG%
  6642. CD%,NG%,_new_val$,_new_val%,p%,jA$,kA$
  6643. shell_GetWindowIdentifier(_window_handle%)
  6644. Evnts_GetEvntListOffset(A$,_icon_handle%,_EVNTS_BUMP_ANCHOR%,_EVNTS_BUMP_REC_SIZE%,
  6645. !lD%=
  6646. shell_GetLastMouseButton
  6647. c%>=0
  6648. k%=!_EVNTS_BUMP_ANCHOR%+c%
  6649. k%!40
  6650. (1<<2)
  6651. k%!40
  6652. (1<<0)
  6653. k%-=_EVNTS_BUMP_REC_SIZE%
  6654. aB%=k%!16
  6655. BD%=k%!20
  6656. gB%=k%!24
  6657. hB%=k%!28
  6658. aB%=aB%*IJ%
  6659. aB%=aB%*GJ%
  6660. aB%=aB%*HJ%
  6661. ZB%=!_EVNTS_BUMP_DATA%
  6662. ZB%>0
  6663. jA$=$(ZB%+k%!32)
  6664. kA$=$(ZB%+k%!36)
  6665. /lA$=
  6666. shell_IconGetData(_window_handle%,BD%)
  6667. kA$<>""
  6668. )CD%=
  6669. ("FN"+kA$+"( "+
  6670. 34+lA$+
  6671. 34+" )")
  6672. (lA$)
  6673. lD%=_MSE_ADJUSTBUT
  6674. _new_val%=CD%+aB%
  6675. _new_val%=CD%-aB%
  6676. lD%=_MSE_ADJUSTBUT
  6677. _new_val%=CD%-aB%
  6678. _new_val%=CD%+aB%
  6679. _new_val%>hB%
  6680. _new_val%=hB%
  6681. _new_val%<gB%
  6682. _new_val%=gB%
  6683. _new_val%>hB%
  6684. _new_val%=gB%
  6685. _new_val%<gB%
  6686. _new_val%=hB%
  6687. jA$<>""
  6688. 0_new_val$=
  6689. ("FN"+jA$+"(_new_val%,"+
  6690. lD%+")")
  6691. _new_val$=
  6692. _new_val%
  6693. shell_IconPutData(_window_handle%,BD%,_new_val$,
  6694. '*|Stop PROCshell_EvntHandle_Bumpers
  6695. !*|Start PROCshell_ListBumpers
  6696. shell_ListBumpers
  6697. EA%,n%,BA%,f%,OA%,mB%
  6698. mD%,nD%,CB$,bB$,IA%,q%,U$
  6699. HI%,BD%,gB%,hB%
  6700. n%=!_EVNTS_BUMP_ANCHOR%
  6701. BA%=_EVNTS_BUMP_REC_SIZE%
  6702. OA%=(n%!4)/2
  6703. Evnts_DebugListHeader ("Bump ","Window       Inc Dec Disp Step Lower Upper Value Change FN")
  6704. f%=_EVNTS_HEADER_SIZE%
  6705. A$=$(n%+f%)
  6706. mD%=n%!(f%+&C)
  6707. (nD%=n%!(f%+&C+_EVNTS_BUMP_REC_SIZE%)
  6708. HI%=n%!(f%+16)
  6709. BD%=n%!(f%+20)
  6710. gB%=n%!(f%+24)
  6711. hB%=n%!(f%+28)
  6712. IA%=!_EVNTS_BUMP_DATA%
  6713. IA%>0
  6714. CB$=$(IA%+n%!(f%+32))
  6715. bB$=$(IA%+n%!(f%+36))
  6716. shell_StringPadTrailing(A$,".",&C)
  6717. /U$+=" "+
  6718. shell_StringPadLeading(
  6719. mD%," ",3)
  6720. /U$+=" "+
  6721. shell_StringPadLeading(
  6722. nD%," ",3)
  6723. /U$+=" "+
  6724. shell_StringPadLeading(
  6725. BD%," ",4)
  6726. /U$+=" "+
  6727. shell_StringPadLeading(
  6728. HI%," ",4)
  6729. /U$+=" "+
  6730. shell_StringPadLeading(
  6731. gB%," ",5)
  6732. /U$+=" "+
  6733. shell_StringPadLeading(
  6734. hB%," ",5)
  6735. U$+="   "+CB$
  6736. f%+=_EVNTS_BUMP_REC_SIZE%*2
  6737.  *|Stop PROCshell_ListBumpers
  6738. /=!*|Start FN_shell_Pointer_Init
  6739. _shell_Pointer_Init
  6740. _c_PointerIn_RecSize%=20
  6741. _m_PointerIn_Anchor%4
  6742. _m_PointerIn_DataBlk%4
  6743. !_m_PointerIn_Anchor%=0
  6744. !_m_PointerIn_DataBlk%=0
  6745. _m_PointerIn_DataOffset%=0
  6746. _c_PointerOut_RecSize%=20
  6747. _m_PointerOut_Anchor%4
  6748. _m_PointerOut_DataBlk%4
  6749. !_m_PointerOut_Anchor%=0
  6750. !_m_PointerOut_DataBlk%=0
  6751. _m_PointerOut_DataOffset%=0
  6752. /N"_m_Pointer_SetShape_Reason%=36
  6753. /O!_m_Pointer_SetShape_Ptr_Nr%=2
  6754. _m_Pointer_ShapeChanged%=
  6755. _m_Pointer_CurrentShape$=""
  6756. _m_Pointer_WorkBuffer%4
  6757. /W *|Stop FN_shell_Pointer_Init
  6758. /c8*|Start PROCshell_AttachPointerEnteringWindowHandler
  6759. shell_AttachPointerEnteringWindowHandler(e%,B$)
  6760. b%,c%,A$,p%,VA%
  6761. /j%A$=
  6762. shell_GetWindowIdentifier(e%)
  6763. /kSc%=
  6764. Evnts_GetEvntListOffset(A$,-1,_m_PointerIn_Anchor%,_c_PointerIn_RecSize%,
  6765. b%=!_m_PointerIn_Anchor%
  6766. VA%=b%!4
  6767. b%+=c%
  6768. $b%=A$
  6769. b%!&C=-1
  6770. !_m_PointerIn_DataBlk%=0
  6771. /s9!_m_PointerIn_DataBlk%=
  6772. shell_HeapBlockFetch(
  6773. (B$)+1)
  6774. p%=b%+16
  6775. Evnts_UpdateData(p%,_m_PointerIn_DataBlk%,_m_PointerIn_DataOffset%,B$)
  6776. 7*|Stop PROCshell_AttachPointerEnteringWindowHandler
  6777. 6*|Start PROCshell_EvntHandle_PointerEnteringWindow
  6778. shell_EvntHandle_PointerEnteringWindow(_window_handle%)
  6779. A$,c%,k%,JA%,x%,B$
  6780. shell_GetWindowIdentifier(_window_handle%)
  6781. A$<>""
  6782. Evnts_GetEvntListOffset(A$,-1,_m_PointerIn_Anchor%,_c_PointerIn_RecSize%,
  6783. c%>=0
  6784. k%=!_m_PointerIn_Anchor%+c%
  6785. JA%=k%!16
  6786. x%=!_m_PointerIn_DataBlk%
  6787. B$=$(x%+JA%)
  6788. ("FN"+B$+"( _window_handle% )")
  6789. 5*|Stop PROCshell_EvntHandle_PointerEnteringWindow
  6790. 7*|Start PROCshell_AttachPointerLeavingWindowHandler
  6791. shell_AttachPointerLeavingWindowHandler(e%,B$)
  6792. b%,c%,A$,p%,VA%
  6793. shell_GetWindowIdentifier(e%)
  6794. Evnts_GetEvntListOffset(A$,-1,_m_PointerOut_Anchor%,_c_PointerOut_RecSize%,
  6795. b%=!_m_PointerOut_Anchor%
  6796. VA%=b%!4
  6797. b%+=c%
  6798. $b%=A$
  6799. b%!&C=-1
  6800. !_m_PointerOut_DataBlk%=0
  6801. :!_m_PointerOut_DataBlk%=
  6802. shell_HeapBlockFetch(
  6803. (B$)+1)
  6804. p%=b%+16
  6805. Evnts_UpdateData(p%,_m_PointerOut_DataBlk%,_m_PointerOut_DataOffset%,B$)
  6806. 6*|Stop PROCshell_AttachPointerLeavingWindowHandler
  6807. 5*|Start PROCshell_EvntHandle_PointerLeavingWindow
  6808. shell_EvntHandle_PointerLeavingWindow(_window_handle%)
  6809. A$,c%,k%,JA%,x%,B$
  6810. shell_GetWindowIdentifier(_window_handle%)
  6811. A$<>""
  6812. Evnts_GetEvntListOffset(A$,-1,_m_PointerOut_Anchor%,_c_PointerOut_RecSize%,
  6813. c%>=0
  6814.  k%=!_m_PointerOut_Anchor%+c%
  6815. JA%=k%!16
  6816. x%=!_m_PointerOut_DataBlk%
  6817. B$=$(x%+JA%)
  6818. ("FN"+B$+"( _window_handle% )")
  6819. shell_PointerResetShape
  6820. 4*|Stop PROCshell_EvntHandle_PointerLeavingWindow
  6821. (*|Start PROCshell_PointerChangeShape
  6822. shell_PointerChangeShape(DB$,II%,uJ%)
  6823. &400E9,_m_Pointer_SetShape_Reason%,,DB$,_m_Pointer_SetShape_Ptr_Nr%,II%,II%
  6824. _m_Pointer_ShapeChanged%=
  6825.  _m_Pointer_CurrentShape$=DB$
  6826. '*|Stop PROCshell_PointerChangeShape
  6827. '*|Start PROCshell_PointerResetShape
  6828. shell_PointerResetShape
  6829. _m_Pointer_ShapeChanged%=
  6830. ("Pointer")
  6831. _m_Pointer_ShapeChanged%=
  6832. _m_Pointer_CurrentShape$=""
  6833. &*|Stop PROCshell_PointerResetShape
  6834. **|Start FNshell_PointerGetCurrentShape
  6835. shell_PointerGetCurrentShape
  6836. =_m_Pointer_CurrentShape$
  6837. )*|Stop FNshell_PointerGetCurrentShape
  6838. $*|Start FNshell_PointerIsChanged
  6839. shell_PointerIsChanged
  6840. =_m_Pointer_ShapeChanged%
  6841. #*|Stop FNshell_PointerIsChanged
  6842. &*|Start PROCshell_PointerSaveEvnts
  6843. shell_PointerSaveEvnts(u%)
  6844. Evnts_SaveEvnt(u%,_m_PointerIn_Anchor%,_m_PointerIn_DataBlk%,_m_PointerIn_DataOffset%)
  6845. Evnts_SaveEvnt(u%,_m_PointerOut_Anchor%,_m_PointerOut_DataBlk%,_m_PointerOut_DataOffset%)
  6846. %*|Stop PROCshell_PointerSaveEvnts
  6847. &*|Start PROCshell_PointerLoadEvnts
  6848. shell_PointerLoadEvnts(u%)
  6849. Evnts_LoadEvnt(u%,_m_PointerIn_Anchor%,_m_PointerIn_DataBlk%,_m_PointerIn_DataOffset%)
  6850. Evnts_LoadEvnt(u%,_m_PointerOut_Anchor%,_m_PointerOut_DataBlk%,_m_PointerOut_DataOffset%)
  6851. %*|Stop PROCshell_PointerLoadEvnts
  6852. 05#*|Start FN_shell_CaretMove_Init
  6853. _shell_CaretMove_Init
  6854. JI%=20
  6855. !sD%=0
  6856. !tD%=0
  6857. 0<    WJ%=0
  6858. LI%=20
  6859. !uD%=0
  6860. !vD%=0
  6861. 0C    ZJ%=0
  6862. 0G"*|Stop FN_shell_CaretMove_Init
  6863. 0S/*|Start PROCshell_AttachCaretPreMoveHandler
  6864. shell_AttachCaretPreMoveHandler(e%,B$)
  6865. b%,c%,A$,p%,VA%
  6866. 0Z%A$=
  6867. shell_GetWindowIdentifier(e%)
  6868. 0[0c%=
  6869. Evnts_GetEvntListOffset(A$,-1,sD%,JI%,
  6870. b%=!sD%
  6871. VA%=b%!4
  6872. b%+=c%
  6873. $b%=A$
  6874. b%!&C=-1
  6875. !tD%=0
  6876. 0c'!tD%=
  6877. shell_HeapBlockFetch(
  6878. (B$)+1)
  6879. p%=b%+16
  6880. Evnts_UpdateData(p%,tD%,WJ%,B$)
  6881. 0o.*|Stop PROCshell_AttachCaretPreMoveHandler
  6882. 0s-*|Start PROCshell_EvntHandle_CaretPreMove
  6883. shell_EvntHandle_CaretPreMove(_window_handle%,_icon_handle%)
  6884. A$,c%,k%,JA%,x%,B$
  6885. 0y2A$=
  6886. shell_GetWindowIdentifier(_window_handle%)
  6887. A$<>""
  6888. 0|0c%=
  6889. Evnts_GetEvntListOffset(A$,-1,sD%,JI%,
  6890. c%>=0
  6891. k%=!sD%+c%
  6892. JA%=k%!16
  6893. x%=!tD%
  6894. B$=$(x%+JA%)
  6895. ("FN"+B$+"( _window_handle%, _icon_handle% )")
  6896. ,*|Stop PROCshell_EvntHandle_CaretPreMove
  6897. 0*|Start PROCshell_AttachCaretPostMoveHandler
  6898. shell_AttachCaretPostMoveHandler(e%,B$)
  6899. b%,c%,A$,p%,VA%
  6900. shell_GetWindowIdentifier(e%)
  6901. Evnts_GetEvntListOffset(A$,-1,uD%,LI%,
  6902. b%=!uD%
  6903. VA%=b%!4
  6904. b%+=c%
  6905. $b%=A$
  6906. b%!&C=-1
  6907. !vD%=0
  6908. '!vD%=
  6909. shell_HeapBlockFetch(
  6910. (B$)+1)
  6911. p%=b%+16
  6912. Evnts_UpdateData(p%,vD%,ZJ%,B$)
  6913. /*|Stop PROCshell_AttachCaretPostMoveHandler
  6914. .*|Start PROCshell_EvntHandle_CaretPostMove
  6915. shell_EvntHandle_CaretPostMove(_window_handle%,_icon_handle%)
  6916. A$,c%,k%,JA%,x%,B$
  6917. shell_GetWindowIdentifier(_window_handle%)
  6918. A$<>""
  6919. Evnts_GetEvntListOffset(A$,-1,uD%,LI%,
  6920. c%>=0
  6921. k%=!uD%+c%
  6922. JA%=k%!16
  6923. x%=!vD%
  6924. B$=$(x%+JA%)
  6925. ("FN"+B$+"( _window_handle%, _icon_handle% )")
  6926. -*|Stop PROCshell_EvntHandle_CaretPostMove
  6927. *|Start FN_shell_Caret_Init
  6928. _shell_Caret_Init
  6929. *|Stop FN_shell_Caret_Init
  6930. &*|Start PROCshell_CaretSetPosition
  6931. shell_CaretSetPosition(QA%,AB%,aJ%,bJ%,oA%,IB%)
  6932. &400D2,QA%,AB%,aJ%,bJ%,oA%,IB%
  6933. shell_IconEnsureVisible(QA%,AB%)
  6934. %*|Stop PROCshell_CaretSetPosition
  6935. '*|Start PROCshell_CaretReadPosition
  6936. shell_CaretReadPosition(
  6937. !AA%=
  6938. shell_HeapBlockFetch(24)
  6939. &400D3,,AA%
  6940. QA%=AA%!0
  6941. AB%=AA%!4
  6942. TD%=AA%!8
  6943. UD%=AA%!&C
  6944. IB%=AA%!20
  6945. shell_HeapBlockReturn(AA%)
  6946. &*|Stop PROCshell_CaretReadPosition
  6947. #*|Start PROCshell_CaretSetRight
  6948. shell_CaretSetRight(a%,r%)
  6949. &400D2,a%,r%,-1,-1,-1,
  6950. shell_IconGetData(a%,r%))
  6951. "*|Stop PROCshell_CaretSetRight
  6952. '*|Start PROCshell_CaretPutFirstIcon
  6953. shell_CaretPutFirstIcon(a%)
  6954. 1 #AA%=
  6955. shell_HeapBlockFetch(&800)
  6956. &400D6,a%,AA%,&40E000,&E000
  6957. !AA%<>-1
  6958. shell_CaretSetRight(a%,!AA%)
  6959. shell_IconEnsureVisible(a%,!AA%)
  6960. shell_HeapBlockReturn(AA%)
  6961. 1-&*|Stop PROCshell_CaretPutFirstIcon
  6962. 11&*|Start PROCshell_CaretPutLastIcon
  6963. shell_CaretPutLastIcon(a%)
  6964. shell_CaretMoveCaret(a%,1)
  6965. 16%*|Stop PROCshell_CaretPutLastIcon
  6966. 1:&*|Start PROCshell_CaretPutNextIcon
  6967. shell_CaretPutNextIcon(a%)
  6968. shell_CaretMoveCaret(a%,2)
  6969. 1?%*|Stop PROCshell_CaretPutNextIcon
  6970. 1C&*|Start PROCshell_CaretPutPrevIcon
  6971. shell_CaretPutPrevIcon(a%)
  6972. shell_CaretMoveCaret(a%,3)
  6973. 1H%*|Stop PROCshell_CaretPutPrevIcon
  6974. 1[$*|Start PROCshell_CaretMoveCaret
  6975. shell_CaretMoveCaret(a%,DA%)
  6976. AA%,NI%,i%,f%,qB%
  6977. i%=0:f%=0
  6978. 1_#AA%=
  6979. shell_HeapBlockFetch(&800)
  6980. &400D3,,AA%
  6981. AA%!4<>-1
  6982. NI%=AA%!4
  6983. &400D6,a%,AA%,&40E000,&E000
  6984. AA%!i%=NI%
  6985. f%=i%
  6986. 1i    i%+=4
  6987. AA%!i%=-1
  6988. qB%=!AA%
  6989. qB%=AA%!(i%-4)
  6990. AA%!(f%+4)<>-1
  6991. qB%=AA%!(f%+4)
  6992. qB%=!AA%
  6993. qB%=AA%!(f%-4)
  6994. qB%=AA%!(i%-4)
  6995. &400D2,a%,qB%,-1,-1,-1,
  6996. shell_IconGetData(a%,qB%))
  6997. shell_IconEnsureVisible(a%,qB%)
  6998. shell_HeapBlockReturn(AA%)
  6999. #*|Stop PROCshell_CaretMoveCaret
  7000. *|Start FN_shell_ExReg_Init
  7001. _shell_ExReg_Init
  7002. _m_ExReg_FontMenu_Loaded%=
  7003. _m_ExReg_Fonts_Loaded%=
  7004. _m_ExReg_DrawLib_Loaded%=
  7005. _m_ExReg_OLELib_Loaded%=
  7006. _m_ExReg_FontLib_Loaded%=
  7007. "_m_ExReg_FontPickLib_Loaded%=
  7008. *|Stop FN_shell_ExReg_Init
  7009. )*|Start FNshell_ExReg_FontMenu_Loaded
  7010. shell_ExReg_FontMenu_Loaded
  7011. =_m_ExReg_FontMenu_Loaded%
  7012. (*|Stop FNshell_ExReg_FontMenu_Loaded
  7013. +*|Start PROCshell_ExReg_FontMenu_Loaded
  7014. shell_ExReg_FontMenu_Loaded
  7015. _m_ExReg_FontMenu_Loaded%=
  7016. **|Stop PROCshell_ExReg_FontMenu_Loaded
  7017. &*|Start FNshell_ExReg_Fonts_Loaded
  7018. shell_ExReg_Fonts_Loaded
  7019. =_m_ExReg_Fonts_Loaded%
  7020. %*|Stop FNshell_ExReg_Fonts_Loaded
  7021. (*|Start PROCshell_ExReg_Fonts_Loaded
  7022. shell_ExReg_Fonts_Loaded
  7023. _m_ExReg_Fonts_Loaded%=
  7024. '*|Stop PROCshell_ExReg_Fonts_Loaded
  7025. (*|Start FNshell_ExReg_DrawLib_Loaded
  7026. shell_ExReg_DrawLib_Loaded
  7027. =_m_ExReg_DrawLib_Loaded%
  7028. '*|Stop FNshell_ExReg_DrawLib_Loaded
  7029. **|Start PROCshell_ExReg_DrawLib_Loaded
  7030. shell_ExReg_DrawLib_Loaded
  7031. _m_ExReg_DrawLib_Loaded%=
  7032. )*|Stop PROCshell_ExReg_DrawLib_Loaded
  7033. '*|Start FNshell_ExReg_OLELib_Loaded
  7034. shell_ExReg_OLELib_Loaded
  7035. =_m_ExReg_OLELib_Loaded%
  7036. &*|Stop FNshell_ExReg_OLELib_Loaded
  7037. )*|Start PROCshell_ExReg_OLELib_Loaded
  7038. shell_ExReg_OLELib_Loaded
  7039. _m_ExReg_OLELib_Loaded%=
  7040. (*|Stop PROCshell_ExReg_OLELib_Loaded
  7041. (*|Start FNshell_ExReg_FontLib_Loaded
  7042. shell_ExReg_FontLib_Loaded
  7043. =_m_ExReg_FontLib_Loaded%
  7044. '*|Stop FNshell_ExReg_FontLib_Loaded
  7045. **|Start PROCshell_ExReg_FontLib_Loaded
  7046. shell_ExReg_FontLib_Loaded
  7047. _m_ExReg_FontLib_Loaded%=
  7048. )*|Stop PROCshell_ExReg_FontLib_Loaded
  7049.