Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!swrinde!zaphod.mps.ohio-state.edu!ncar!news.miami.edu!umiami!dweisman From: dweisman@umiami.ir.miami.edu (Ordinary Man) Newsgroups: comp.sys.mac.programmer Subject: Re: Weird Update with System 7 Message-ID: <1991Jun15.234140.10650@umiami.ir.miami.edu> Date: 16 Jun 91 03:41:39 GMT References: Organization: Univ of Miami IR Lines: 25 In article , morris@mrcnext.cso.uiuc.edu (Brad Morris) writes: > Hi! I am writing a game with a button and I use: > SetCTitle(gButtonHandle,s); > This seemed to work fine under system 6, this procedure would set the > title and redraw the button. In System 7, however, I get an > unexplainded update window event which seems to just redraw the > control whenever I call SetCTitle. Did they change how the control > manager has handled this or do I have a really well hidden bug somewhere? > Thanks. Well, I'm not sure what might cause this off-hand, but here's how I deal with unexplained/unexpected update events. Just save the current port, set it to the window in question, call ValidRect(theWindow^^.portRect) and then set the port back. That will make sure the window doesn't get updated. Dan /-------------------------------------------------------------------------\ | Dan Weisman - University of Miami - Florida | || || || || | |--------------------------------------------------| || || ||\ /|| | | INTERNET -----> dweisman@umiami.IR.Miami.edu | || || || | || | | BITNET -----> dweisman@umiami | ||||||| || | || | |-------------------------------------------------------------------------| | "...the fact is- this friction will only be worn by persistance." -RUSH | \_________________________________________________________________________/