• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Custom initWithFrame?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Custom initWithFrame?


  • Subject: Re: Custom initWithFrame?
  • From: Jean Suisse <email@hidden>
  • Date: Fri, 04 Jan 2013 02:44:34 +0100

On 4 janv. 2013, at 02:28, Eric Dolecki wrote:
> I am creating a UIView-based control that I would also like to pass in parameters at the time of creation. Is this doable? I don't want to keep calling methods on my object if I can pass all with initwithframe somehow.
>
> Thanks,
> Eric

Eric, maybe you could use :

- (id)initWithFrame:(NSRect)frame andOtherObject:(someClass*)myOtherObject
{
	self = [super initWithFrame:frame];
	if (self)
	{
		[self setOtherObject:myOtherObject];
	}

	return self;
}

Best regards,
Jean






-----------
Jean Suisse
Institut de Chimie Moléculaire de l’Université de Bourgogne
(ICMUB) — UMR 6302





_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden


References: 
 >Custom initWithFrame? (From: Eric Dolecki <email@hidden>)

  • Prev by Date: Re: Custom initWithFrame?
  • Next by Date: Re: scroll bars and visible rect
  • Previous by thread: Re: Custom initWithFrame?
  • Next by thread: Re: Custom initWithFrame?
  • Index(es):
    • Date
    • Thread