> On 25 Dec 2014, at 11:30, N!K <[email protected]> wrote:
>
>>
>
> Thank you all for explaining what’s going on. I looked up initWithCoder; it
> is not suitable for my usage.
In what way is initWithCoder: not suitable for your usage? What is the code you
had in initWithFrame: which you want called and why can you not put that code
into initWithCoder:? Have you even implemented a simple initWithCoder: method
and checked that is the one being called during the NIB loading by the way -
before we go any further down this track.
My classes often end up looking something like this with the init code factored
out into a separate method called from any of the initializers.
-(void)My_Class_Internal_Init
{
.. init code ..
}
-(id)init
{
self = [ super init ];
if( self )
[ self My_Class_Internal_Init ];
return self;
}
-(id)initWithCoder:(NSCoder*)coder
{
self = [ super initWithCoder:coder ];
if( self )
[ self My_Class_Internal_Init ];
return self;
}
-(id)initWithFrame: ... // etc etc
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list ([email protected])
Help/Unsubscribe/Update your Subscription:
https://lists.apple.com/mailman/options/xcode-users/archive%40mail-archive.com
This email sent to [email protected]