Re: unexpected nil outlet
Re: unexpected nil outlet
- Subject: Re: unexpected nil outlet
- From: David Reynolds <email@hidden>
- Date: Wed, 18 Jun 2008 18:15:39 +0100
- Resent-date: Wed, 18 Jun 2008 20:08:05 +0100
- Resent-from: David Reynolds <email@hidden>
- Resent-message-id: <email@hidden>
- Resent-to: email@hidden
On 18 Jun 2008, at 13:31, David Reynolds wrote:
Sure, I can email it to you I get home from work if you like?
For anyone following, here is my version of the code:
Controller.h:
#import <Cocoa/Cocoa.h>
@interface Controller : NSObject {
}
@end
No instance variables and no methods- is this bad?
Controller.m:
#import "Controller.h"
@implementation Controller
- (NSSize)windowWillResize:(NSWindow *)sender
toSize:(NSSize)frameSize
{
NSSize mySize;
mySize.width = frameSize.width;
mySize.height = (frameSize.width / 2);
NSLog(@"mySize is %f wide and %f tall", mySize.width, mySize.height);
return mySize;
}
@end
I set the initial height and width of the window in Interface Builder
and also set the windows delegate to be my controller instance and I
think that was it.
As I said earlier, I'd be very interested to know if my method is the
best or the "right" way to do it and if not, which method is the best.
Thanks for your help
--
David Reynolds
email@hidden
_______________________________________________
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