Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!uunet!mcsun!ukc!icdoc!qmc-cs!jeremyr From: jeremyr@cs.qmc.ac.uk (Jeremy Roussak) Newsgroups: comp.sys.mac.programmer Subject: Re: Tail patches Message-ID: <1467@sequent.cs.qmc.ac.uk> Date: 9 Nov 89 22:29:15 GMT References: <1459@sequent.cs.qmc.ac.uk> <36250@apple.Apple.COM> <5056@internal.Apple.COM> <1989Nov7.212837.5146@oracle.com> <5080@internal.Apple.COM> Reply-To: jeremyr@cs.qmc.ac.uk (Jeremy Roussak) Organization: Computer Science Dept, Queen Mary College, University of London, UK. Lines: 21 >As for "sometimes you just gotta," all I can say is: don't do whatever it >is you're doing that's "just gotta." Find a "more inventive" way. Since I initiated this thread, perhaps I could explain what I was doing, and ask if anyone can suggest an alternative way of doing it. I was challenged to write a patch which would play a sound, preferably whenever the Finder emptied the wastebasket (doesn't appear to be possible) or at least when "Empty Wastebasket" was chosen from the menu. The reason for this curious request was that the person concerned had changed the wastebasket icon to look like a toilet and wanted it to flush! The obvious thing to do, (and we all do obvious things, don't we...) was to do a tail patch on MenuSelect, look for a return of 0x00050002, check that CurApName is the same as FinderName and to play the sound if it is. I did it. It worked. It's not subtle, or particularly clever, I confess. How should I have done this, without using a tail patch? Jeremy Roussak