home *** CD-ROM | disk | FTP | other *** search
/ The Electronic Whole Earth Catalog / ElectronicWholeEarthCatalog.img / LIVELIHOOD / background_5956.txt < prev    next >
Text File  |  1989-02-07  |  8KB  |  380 lines

  1. -- background: 5956 from stack: in
  2. -- bmap block id: 2211
  3. -- flags: 4000
  4. -- background id: 0
  5. -- name: Picture
  6. ----- HyperTalk script -----
  7. -- bg Picture script 1/19
  8. -- When the user clicks the mouse outside of any active buttons or
  9. -- fields, the caption dissolves away so the user can see more of the
  10. -- picture.  On full screen picture cards, the Earth, Map, Left, Right
  11. -- Up, Down buttons and the Menu field also dissolve away.
  12. --
  13. -- These buttons/fields are restored to visibility when the user clicks
  14. -- again or when he leaves the card.
  15. --
  16. -- 1/19 added fix to closeCard
  17. on mouseUp
  18.   picCardHandler "toggle"
  19. end mouseUp
  20.  
  21. on openCard
  22.   lock screen
  23.   picCardHandler "init"
  24.   if isFSCard() is true then
  25.     hideEMLR
  26.   end if
  27.   unlock screen
  28.   pass openCard
  29. end openCard
  30.  
  31. on closeCard
  32.   lock screen
  33.   if isFSCard() is true then
  34.     showEMLR
  35.   end if
  36.   unlock screen
  37.   pass closeCard
  38. end closeCard
  39.  
  40. on hideEMLR
  41.   hide bg btn "Earth"
  42.   hide bg btn "Map"
  43.   hide bg btn "Left"
  44.   hide bg btn "Right"
  45. end hideEMLR
  46.  
  47. on showEMLR
  48.   show bg btn "Earth"
  49.   show bg btn "Map"
  50.   show bg btn "Left"
  51.   show bg btn "Right"
  52. end showEMLR
  53.  
  54. function isFSCard
  55. if fld "fullScreen" is empty then
  56.   return false
  57. else
  58.   return true
  59. end if
  60. end isFSCard
  61.  
  62. on picCardHandler picMsg
  63.   global picToggle
  64.  
  65.   if picMsg is "init" then
  66.     showPicCardObjects
  67.     put "hide" into picToggle
  68.   else if picMsg is "toggle" then
  69.     if picToggle = "hide" then
  70.       hidePicCardObjects
  71.       put "show" into picToggle
  72.     else
  73.       showPicCardObjects
  74.       put "hide" into picToggle
  75.     end if
  76.   end if
  77. end picCardHandler
  78.  
  79. on hidePicCardObjects
  80.   if isFSCard() then
  81.     hidePicCardObjectsFS
  82.   else
  83.     hideCaption
  84.   end if
  85. end hidePicCardObjects
  86.  
  87. on showPicCardObjects
  88.   if isFSCard() then
  89.     showPicCardObjectsFS
  90.   else
  91.     showCaption
  92.   end if
  93. end showPicCardObjects
  94.  
  95. on hidePicCardObjectsFS
  96.   lock screen
  97.   hide cd fld "theHeading"
  98.   hide cd fld "theCaption"
  99.   hide cd fld "thePage"
  100.   hide cd btn "Up"
  101.   hide cd btn "Down"
  102.   unlock screen with "dissolve"
  103. end hidePicCardObjectsFS
  104.  
  105. on showPicCardObjectsFS
  106.   lock screen
  107.   show cd fld "theHeading"
  108.   show cd fld "theCaption"
  109.   show cd fld "thePage"
  110.   show cd btn "Up"
  111.   show cd btn "Down"
  112.   unlock screen with "dissolve"
  113. end showPicCardObjectsFS
  114.  
  115. on showCaption
  116.   lock screen
  117.   if hasCdField("theCaption") is true then
  118.     show cd fld "theCaption"
  119.   end if
  120.   unlock screen with dissolve
  121. end showCaption
  122.  
  123. on hideCaption
  124.   lock screen
  125.   if hasCdField("theCaption") is true then
  126.     hide cd fld "theCaption"
  127.   end if
  128.   unlock screen with dissolve
  129. end hideCaption
  130.  
  131.  
  132.  
  133.  
  134.  
  135.  
  136.  
  137.  
  138. -- part 5 (field)
  139. -- low flags: 81
  140. -- high flags: 4002
  141. -- rect: left=255 top=0 right=18 bottom=396
  142. -- title width / last selected line: 0
  143. -- icon id / first selected line: 0 / 0
  144. -- text alignment: 0
  145. -- font id: 3
  146. -- text size: 12
  147. -- style flags: 0
  148. -- line height: 16
  149. -- part name: theIdent
  150.  
  151.  
  152. -- part 10 (button)
  153. -- low flags: 00
  154. -- high flags: 0000
  155. -- rect: left=463 top=139 right=173 bottom=508
  156. -- title width / last selected line: 0
  157. -- icon id / first selected line: 0 / 0
  158. -- text alignment: 1
  159. -- font id: 0
  160. -- text size: 12
  161. -- style flags: 0
  162. -- line height: 16
  163. -- part name: Map
  164. ----- HyperTalk script -----
  165. on mouseUp
  166.   doArticleMapButton
  167. end mouseUp
  168.  
  169.  
  170.  
  171. -- part 12 (field)
  172. -- low flags: 01
  173. -- high flags: 2000
  174. -- rect: left=28 top=40 right=64 bottom=463
  175. -- title width / last selected line: 0
  176. -- icon id / first selected line: 0 / 0
  177. -- text alignment: 0
  178. -- font id: 3
  179. -- text size: 12
  180. -- style flags: 768
  181. -- line height: 16
  182. -- part name: theTitle
  183.  
  184.  
  185. -- part 13 (field)
  186. -- low flags: 81
  187. -- high flags: 0002
  188. -- rect: left=304 top=9 right=27 bottom=481
  189. -- title width / last selected line: 0
  190. -- icon id / first selected line: 0 / 0
  191. -- text alignment: 0
  192. -- font id: 3
  193. -- text size: 9
  194. -- style flags: 0
  195. -- line height: 18
  196. -- part name: theTopic
  197.  
  198.  
  199. -- part 17 (button)
  200. -- low flags: 00
  201. -- high flags: 0000
  202. -- rect: left=463 top=88 right=130 bottom=507
  203. -- title width / last selected line: 0
  204. -- icon id / first selected line: 0 / 0
  205. -- text alignment: 1
  206. -- font id: 0
  207. -- text size: 12
  208. -- style flags: 0
  209. -- line height: 16
  210. -- part name: Earth
  211. ----- HyperTalk script -----
  212. on mouseUp
  213.   goWholeEarth
  214. end mouseUp
  215.  
  216.  
  217.  
  218. -- part 22 (field)
  219. -- low flags: 81
  220. -- high flags: 0002
  221. -- rect: left=0 top=172 right=232 bottom=165
  222. -- title width / last selected line: 0
  223. -- icon id / first selected line: 0 / 0
  224. -- text alignment: 0
  225. -- font id: 3
  226. -- text size: 10
  227. -- style flags: 0
  228. -- line height: 13
  229. -- part name: Popup
  230.  
  231.  
  232. -- part 23 (field)
  233. -- low flags: 81
  234. -- high flags: 0002
  235. -- rect: left=0 top=0 right=18 bottom=86
  236. -- title width / last selected line: 0
  237. -- icon id / first selected line: 0 / 0
  238. -- text alignment: 0
  239. -- font id: 3
  240. -- text size: 12
  241. -- style flags: 0
  242. -- line height: 16
  243. -- part name: Accession
  244.  
  245.  
  246. -- part 25 (field)
  247. -- low flags: 81
  248. -- high flags: 0001
  249. -- rect: left=67 top=315 right=338 bottom=89
  250. -- title width / last selected line: 0
  251. -- icon id / first selected line: 0 / 0
  252. -- text alignment: 0
  253. -- font id: 3
  254. -- text size: 18
  255. -- style flags: 256
  256. -- line height: 24
  257. -- part name: FullScreen
  258.  
  259.  
  260. -- part 27 (button)
  261. -- low flags: 00
  262. -- high flags: 0000
  263. -- rect: left=463 top=232 right=275 bottom=488
  264. -- title width / last selected line: 0
  265. -- icon id / first selected line: 0 / 0
  266. -- text alignment: 1
  267. -- font id: 0
  268. -- text size: 12
  269. -- style flags: 0
  270. -- line height: 16
  271. -- part name: Left
  272. ----- HyperTalk script -----
  273. on mouseUp
  274.   doArticleLeftButton
  275. end mouseUp
  276.  
  277.  
  278.  
  279. -- part 28 (button)
  280. -- low flags: 00
  281. -- high flags: 0000
  282. -- rect: left=482 top=184 right=230 bottom=507
  283. -- title width / last selected line: 0
  284. -- icon id / first selected line: 0 / 0
  285. -- text alignment: 1
  286. -- font id: 0
  287. -- text size: 12
  288. -- style flags: 0
  289. -- line height: 16
  290. -- part name: Right
  291. ----- HyperTalk script -----
  292. on mouseUp
  293.   doArticleRightButton
  294. end mouseUp
  295.  
  296.  
  297.  
  298. -- part 29 (field)
  299. -- low flags: 81
  300. -- high flags: 0002
  301. -- rect: left=410 top=128 right=143 bottom=512
  302. -- title width / last selected line: 0
  303. -- icon id / first selected line: 0 / 0
  304. -- text alignment: 0
  305. -- font id: 4
  306. -- text size: 9
  307. -- style flags: 0
  308. -- line height: 12
  309. -- part name: MapDest
  310.  
  311.  
  312. -- part 30 (field)
  313. -- low flags: 81
  314. -- high flags: 0002
  315. -- rect: left=410 top=272 right=287 bottom=512
  316. -- title width / last selected line: 0
  317. -- icon id / first selected line: 0 / 0
  318. -- text alignment: 0
  319. -- font id: 4
  320. -- text size: 9
  321. -- style flags: 0
  322. -- line height: 12
  323. -- part name: LeftDest
  324.  
  325.  
  326. -- part 31 (field)
  327. -- low flags: 81
  328. -- high flags: 0002
  329. -- rect: left=410 top=225 right=240 bottom=512
  330. -- title width / last selected line: 0
  331. -- icon id / first selected line: 0 / 0
  332. -- text alignment: 0
  333. -- font id: 4
  334. -- text size: 9
  335. -- style flags: 0
  336. -- line height: 12
  337. -- part name: RightDest
  338.  
  339.  
  340. -- part 32 (field)
  341. -- low flags: 81
  342. -- high flags: 0002
  343. -- rect: left=354 top=285 right=300 bottom=456
  344. -- title width / last selected line: 0
  345. -- icon id / first selected line: 0 / 0
  346. -- text alignment: 0
  347. -- font id: 4
  348. -- text size: 9
  349. -- style flags: 0
  350. -- line height: 12
  351. -- part name: UpDest
  352.  
  353.  
  354. -- part 33 (field)
  355. -- low flags: 81
  356. -- high flags: 0002
  357. -- rect: left=354 top=301 right=316 bottom=456
  358. -- title width / last selected line: 0
  359. -- icon id / first selected line: 0 / 0
  360. -- text alignment: 0
  361. -- font id: 4
  362. -- text size: 9
  363. -- style flags: 0
  364. -- line height: 12
  365. -- part name: DownDest
  366.  
  367.  
  368. -- part 34 (field)
  369. -- low flags: 81
  370. -- high flags: 0002
  371. -- rect: left=163 top=172 right=232 bottom=277
  372. -- title width / last selected line: 0
  373. -- icon id / first selected line: 0 / 0
  374. -- text alignment: 0
  375. -- font id: 3
  376. -- text size: 10
  377. -- style flags: 0
  378. -- line height: 13
  379. -- part name: PopupDest
  380.