Path: utzoo!attcan!uunet!convex!killer!osu-cis!tut.cis.ohio-state.edu!mailrus!iuvax!ndmath!thelink!oliver From: oliver@thelink.UUCP (Joel Sumner) Newsgroups: comp.sys.apple Subject: Re: windows Message-ID: <152@thelink.UUCP> Date: 30 Jun 88 21:42:42 GMT References: <148@thelink.UUCP> <13029@apple.Apple.COM> Organization: TheLink-Public Access Unix, South Bend, IN. Lines: 54 Keith Rollin writes.... >Joel Sumner Writes >>I have a Toolbox question.. In Applications such as DeluxePaint II, >>clicking the mouse in the tools (to select, say the pen) does not deactivate >>other windows How is this accomplished? > When writing a quickie sample >program, it is very tempting to simply set the TaskMask to $0000FFFF and >leave your worries behind. (Isn't the TaskMask $1FFF? That is the way I see it in TML but they may not be setting a bit or two) >However, TaskMaster will automatically call >SelectWindow if its call to FindWindow detects a click on an incactive window. >That is why many programs do not use windows that float in the background all >the time (because they use TaskMaster). >You can get around this in several ways. 1) Don't use TaskMaster. This is >a pain and not really necessary. 2) Don't set the tmFindW bit in the >TaskMask. This will cause TaskMaster to return to you immediately after a >mouse click. 3) Clear bits tmDragW, tmContent, and tmInfo in the TaskMask >(you may have to fiddle with the last bit...I think the documentation is >wrong that you have to SET it in order to get TaskMaster to ignore clicks >in the infobar...). >Anyway, this last option seems to be the best in terms of getting >TaskMaster to do everything except activate windows. I hope that there are >no problems with this; the last time I tried it, it didn't work, but that >was with some unreleased System Software -- I have been assured that it has >been fixed (knock on wood!). I will keep this in mind... I was also thinking that GetNextEvent would work fine also. My main idea was to make an NDA to take advantage of the unactivated window usage. Since the Task Master manipulates the windows, it sounds like it would be impossible to make an NDA stay in the backround but still perform since the NDA has no control whatsoever over the program that it is running under. Though you could create an Application that allows the windows not to me "brought forward" but then you get into trouble if you activate other NDA's that do not benefit from this 'feature'. Oh well, it was just another thought (anyone want to try this one? If not, it will go into the "old ideas" box.) >Keith Rollin amdahl\ >Developer Technical Support pyramid!sun !apple!keith >Apple Computer decwrl/ >"You can do what you want to me, but leave my computer alone!" ---------------------------------------------------------------------------| | oliver@thelink.UUCP |AT&T (219) 291-8343| GEnie K.SUMNER [Joel] | | (Joel Sumner) |----------------------------------------------------| |USnail 1505 Sheffield Ct. | It is always darkest before the lights go out | | South Bend, IN 46614| | !--------------------------------------------------------------------------!