From: Shawn Hargreaves Newsgroups: comp.os.msdos.djgpp Subject: Re: trapping alt-tab ? Date: Sat, 2 May 1998 13:55:14 +0100 Organization: None Message-ID: References: <6idl15$ln4$1 AT o DOT online DOT no> NNTP-Posting-Host: talula.demon.co.uk MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain; charset=iso-8859-1 Lines: 25 To: djgpp AT delorie DOT com DJ-Gateway: from newsgroup comp.os.msdos.djgpp Precedence: bulk jan åge johnsen [iC] writes: >ok, I have understood that windows and allegro dosen't allways fit very >well, especial in hig resoultion modes (for some machines), well I was >thinking of is there anyway of trapping alt-tab, alt-space, alt-enter >presses change to a working resolution(with win95) and then change to >windows, so that I would allow switching to windows without chrasing my >program ? The Interrupt List decribes various hook functions that might be useful for this, but it isn't totally clear whether they will work under win95, or only 3.1. At best I think you would only be able to disable the tab altogether, because even if you could hook the switch event, there would be no safe way to save the program state from this. It would require a complete shutdown of the Allegro graphics system, which cannot safely be done from inside an interrupt call. Most win95 systems handle the switching quite happily, though (myself, I have yet to meet one that doesn't). It seems like a very minor thing to be concerned about: if your drivers don't support it, just don't hit alt+tab :-) -- Shawn Hargreaves - shawn AT talula DOT demon DOT co DOT uk - http://www.talula.demon.co.uk/ "Pigs use it for a tambourine" - Frank Zappa