Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!know!sdd.hp.com!think.com!mintaka!bloom-beacon!eru!hagbard!sunic!mcsun!ukc!tcdcs!swift.cs.tcd.ie!cjmchale From: cjmchale@swift.cs.tcd.ie Newsgroups: comp.windows.x Subject: Re: How do I block X events? Message-ID: <7507.27444008@swift.cs.tcd.ie> Date: 16 Nov 90 19:37:44 GMT References: <1990Nov15.190220.20413@csug.rdg.ac.uk> Organization: Computer Science Department, Trinity College Dublin Lines: 32 In article <1990Nov15.190220.20413@csug.rdg.ac.uk>, ac1@csug.cs.rdg.ac.uk (Andrew Cunningham) writes: > I am writing an X application using the Motif toolkit (on HP-UX 7.0, if it > makes a difference). The program has to perform a computationally intensive > task from time to time, and I'd like to be able to block the user interface > while this is going on. Ideally I want to > > a) Display an hourglass cursor over the whole application > > b) Ignore any mouse/keyboard events until the operation is > complete. > > Can anyone enlighten me as to how I could perform either or both of > these tasks? Create an InputOnly window big enough to cover the entire appliction. Set up the do_not_propagate_mask on this window so that no no events are propagated; this takes vare of b). Set the cursor of this window to be an hourglass cursor; this takes care of a). When the CPU intensive task is finished you simply either destroy the window or unmap it to return to "normal" operation. Regards, Ciaran. -- Ciaran McHale "An inappropiate joke for every occasion" Department of Computer Science, Trinity College, Dublin 2, Ireland. Telephone: +353-1-772941 ext 1538 FAX: +353-1-772204 Telex: 93782 TCD EI email: cjmchale@cs.tcd.ie or cjmchale%cs.tcd.ie@cunyvm.cuny.edu My opinions are.