Page 1 of 1

modified sleep desk accessory

Posted: February 21st, 1985, 11:48 pm
by Info-Mac
Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP
Posting-Version: version B 2.10.2 9/18/84; site uw-beaver
Path: utzoo!watmath!clyde!burl!ulysses!mhuxr!mhuxj!houxm!vax135!cornell!uw-beaver!info-mac
From: info-mac@uw-beaver
Newsgroups: fa.info-mac
Subject: modified sleep desk accessory
Message-ID:
Date: Fri, 25-Jan-85 07:35:04 EST
Article-I.D.: uw-beave.557
Posted: Fri Jan 25 07:35:04 1985
Date-Received: Sun, 27-Jan-85 05:37:08 EST
Sender: daemon@uw-beaver
Organization: U of Washington Computer Science
Lines: 334

From: edmoy%ucbopal.CC@UCB-VAX

Here is a modified version of the sleep desk accessory. Many thanks to
Walter Smith, who submitted it first (Walter, if you're out there, I've held
off submitting the source code until I OK it with you).

For those who missed it the first time, sleep is a desk accessory that blacks
out the screen, so that you can leave it on all the time and instantly start
where you left off. Unlike turning down the brightness control, an apple is
constantly moved around the screen to remind you that it is still on.

The major change is that the desk accessory has been restructured so that
clicking the mouse button causes SystemClick to call CloseDeskAcc so that
memory for it is no longer locked. Also, it uses my dynamic relocation
scheme (another letter from me to info-mac talked about this), so that it
doesn't cause the Mac to bomb when it is restarted after another desk
accessory has been opened.

An added feature (actual hiding a bug) is that if you hold the mouse button
down and release it in the area where the menu bar is normally, sleep
continues. Unfortunately, if the cursor is already in the menu bar area
and you click the mouse, nothing happens ( you just have to move the mouse
down).

I change the cursor to be a hilited close box with an arrow in it when you
hold the mouse button down. Moving it into the menu bar area will cause the
cursor to disappear.

Like the note from Lonnie R. Abelbeck, I prefer a smoothly moving apple to
the jumping apple, so this version has that implemented.

The file is in binhex format and uses the standard desk application to
preview and install it. Again, many thanks to Walter.

Edward Moy
Computing Services
University of California
Berkeley, CA 94720

edmoy@ucbopal
ucbvax!ucbopal!edmoy

----- cut here --------------------------------------------- cut here -----
(This file must be converted with BinHex.Hex)
#APPLCCOM$0000
***COMPRESSED
***RESOURCE FORK
( 0 ", B ((
(
(
(
(
(
(
(
( P / !1 +0!KP$ 554 !> ( %H "@!N
( !0! )/2P 6@$. &X!5 0&0V%N8V5L *
( \ $8!7H@J4F5P;&%C92!S>7-T96T@TY,H6].3)%O3DAXV0
( S@9@ 7B\\ -.$ZY 'S%B/+SP U,3KD >3G5.5@ 2.X +SD W 3KD B\
(%B/(&X #$*H !XS_/__ ,WDZY 'W$IY ,ZF8
( 03KD @,,_P 0 #.HO.0 #;A.N0 "1Q8CR\Y
( #;A.N0 ")Q8CR\\ -3$ZY 'K%B/0GD S@
($ZY ([" \0 & 9@ "3EY.=4Y6__Q([B
(/_\('D W 2B@ ;F0 #3G5.5@ 2.X +SP %6+SP ( +SP
("\\ "\\ -/$ZY (;-_\ %"\\ "\\
( $O//____\O/ (O/ O/ #-0O/
( T\+SP 3KD BLW_P @(\ W ('D W
("/H 'X U((#D U( H#_ (CD SP@($@>0
( W (4 ?B Y -2 * /___R/ -2"!N @A>0
( W !X@;@ ((GD W ,V@ & !L8 DY>3G5.5@
($CN $IY ,WFP Q">0 #-Y@ %4+SP TX
($ZY 'S%B/+SP U,3KD >\6(]*>0 #-YG H
("\Y -1"\Y -O$ZY (+%"/+SP 43KD A0H"0N0 #;PCP
( V\(#D SB1( CP #.(@.0 #.;1N0 #40,N0
( %6 -1&\ "8@/ JR0N0 #40CP #[email protected]
( SF1( CP #.9@ L#+D + -1&P !YP%I"Y
( #40CP #[email protected] #.9$@"/ ,YB\Y -1"\Y
( #;Q.N0 ""Q0CR\\ %$ZY (7%B/+SD TX
($ZY 'O%B/8 DY>3G4 $Y6_^Q([@ _^PO/
( ,2&[_]$ZY ')%"/+4#_\# N__A(P& )X@;O_Z
($HH &YF ,(&[_\$*08 Y@RN !/_T9@ 3$IY
( #.IG ,3KD ?\8 %B\\ ,]$ZY '[%B/
($ZY (#$IY ,ZF8 AP 6 1"@#/ ,ZB!N
(/_P0I!@ "08 0B!N__HO* 82&[_]$ZY (C%"/
($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N
(")?(!^A(BZ(8 #_(B)?(%^@(V _Q@B7R!?H"4N@&H
( (0I=@ /\&8 #_ ")?(!\@7Z D8 #^]B)?(%^A)BZ(
(& _NHB7R!?H2@NB& _MPB7R!?H"M@ /[4(E\@'R!?
(* G8 #^R")?(%^@*6 _KXB7R!?H"I@ /ZT(E\@7Z!)
(& _JHB7R!?H$I@ /Z@H#9@ /Z0 %8 !$YU+WD ,H 1.=2)?0EET!&
(/_T= !@ /_N= 9@ /_H-#P "& _^ T/ *8 #_V'0&
("!?/P(O"*WM= A@ /_T= !@ /_N= Y@ /_H= )@ /_B
('008 #_W'0$8 #_UC0\ I@ &-#P #"!?/P(O"*WM
(#0\ I@ &-#P #")O 0@;P (0D!"01 8$ADO2 (
("]) 0@7S\ /P$_ B\(K>T@;P (/SP :GN(&\ !""
(& ! @;P $("\ "#\\ "I[B!?4$].T (&\ !#)\
( $!A* &<*$A 0P! !4HE@\B )(&\ !!" ( A.=2!O
( $(DA"@! 84X!M"A+89@)3B5'(__A"$2 O 1.=2!O
( $0H 0$-' 4HA"$" O 12@$YU("\ ! C !A.=10
($125E( 1FEL90!#;&]S90!);G-T86QL %%U:70 161I
('0 56YD;R]: "@M $-U="]8 $-O<'DO0P!087-T92]6
( !#;&5A<B]" $125E( 1%)64@!$4E92 $125E( 1%)6
(%( 1%)64@!$4E92 $125E(
(
(
(
(
(
( < 'H T%,
(%)4 (D1)5$P N1%)64@ #I#3T1% $ 1@$
(/__( ! /__( $ & , <@
( #__R #MH '__S0 #O8 !@!3;&5E
G
***END OF DATA
***CRC:40DF