bug-gnustep
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

NSApplication bug


From: Ludovic Marcotte
Subject: NSApplication bug
Date: Tue, 30 Oct 2001 14:50:25 -0500 (EST)

Hi,

In NSApplication: -run we have:

..
  while (_app_is_running)
    {
      IF_NO_GC(pool = [arpClass new]);

      e = [self nextEventMatchingMask: NSAnyEventMask
                            untilDate: distantFuture 
                               inMode: NSDefaultRunLoopMode
                              dequeue: YES];

Where distantFuture == [NSDate distantFuture]. I don't think this does 
make sense since were are going to block if we don't receiving any events 
and that will prevent windows to get updated.

I think we should replace distantFuture by [NSDate 
dateWithTimeIntervalSinceNow: 0.25] (or any other value other that 0.25).

I found this bug while writing my 'blinking cursor' patch. The cursor 
won't be redrawn if you don't generate any event - which is quite wrong.

The same thing happen when the little Blink program I sent on the list on 
sunday.

This bug fix corrects everything and don't do anything bad if the value 
(of 0.25) isn't set to low.

Nicola, I can send you an updated version of my patch (and we can now 
safely ignore the postEvent of a dummy event I was doing).

Thanks,
        Ludovic

-- 
Live as if you were to die tomorrow.
Learn as if you were to live forever.
 - Gandhi





reply via email to

[Prev in Thread] Current Thread [Next in Thread]