[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
windowWillResize delegate not invoked (bug #24093)
From: |
Derek Fawcus |
Subject: |
windowWillResize delegate not invoked (bug #24093) |
Date: |
Fri, 8 May 2009 13:55:22 +0100 |
User-agent: |
Mutt/1.4.1i |
I just ran in to this, and found it is already known.
Would it not be sufficient to simply call the delegated method from within
the handler for the GSAppKitWindowResized event?
i.e. NSWindow.m sendEvent: has the following:
case GSAppKitWindowResized:
{
...
[_wv setFrame: newFrame];
[_wv setNeedsDisplay: YES]
...
[nc postNotificationName: NSWindowDidResizeNotification object: self]
break;
}
how about if the following was inserted before the call to setFrame:
newFrame.size = [_delegate windowWillResize: _wv toSize: newFrame.size];
or more accurately, the block in setFrame:display: (with redundant size
check and the delegate being supported) was moved from it
to here?
For a window manager which does live resize, this would seem to give the same
result as seen on OSX - namely adjacent calls to the 'will' and 'did' resize
delegates. For a window manager which only sends the change after adjusting
an outline (e.g. window maker) this would also seem to give a chance to perform
a size 'correction'.
DF
- windowWillResize delegate not invoked (bug #24093),
Derek Fawcus <=