On 2005-08-23 10:13:43 +0100 Stéphane Goujet <[EMAIL PROTECTED]> wrote:
> Hello,
>
> is this method known to work or to be broken ?
It is implemented to do nothing.
> The problem I have is that, for a view which is a subview of a subview of
> [...] of a window, this method is called only once with GNUStep, when it is
> added to its superview, but it is not called anymore later, when its
> superview is added to another superview, etc., and when the last superview is
> added to the window.
> So, if I write in my view code :
>
> -(void) viewDidMoveToWindow {
> printf("window=%p\n", [self window]);
> }
>
> I will only get 1 line of result :
> window=(null)
>
> With Cocoa, I will get :
> window=0x0
> window=0x0
> window=0x0
> window=0x0
> window=0x52a730
>
> which is the result I expect.
... the problem was with the code calling it, which wasn't calling it for
subviews.
I've changed the code in CVS to call -viewDidMoveToWindow on subviews, as this
appears to be the correct behavior.
_______________________________________________
Discuss-gnustep mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/discuss-gnustep