Skip navigation.
 
mlBasic info about outlets
FROM : John Love
DATE : Thu May 15 13:30:09 2008

I *think* I understand about outlets and actions .. but now I am not so
sure.

Specifically, if I set (NSWindow *)documentWindow as an Outlet in my main
nib and I declare in MyDocument.h file:

interface MyDocument:NSDocument {
          IBOutlet NSWindow *documentWindow;
}
...

- (void) someMethod:documentWindow;

and in MyDocument.m file:

- (void) someMethod {
      // some operation that accesses a property of documentWindow
}

Okay, documentWindow is typed as a outlet in the main nib and in the
interface,.h, file ... and I have control-dragged from the FileOwner to the
title bar of the Window, selecting "documentWindow" as the Outlet.  But,
just exactly HOW does the actual documentWindow object get passed so that
someMethod can look at one of its properties?

This question is oriented to "behind the scenes".

Thanks in advance>

John Love

Related mailsAuthorDate
mlBasic info about outlets John Love May 15, 13:30
mlRe: Basic info about outlets Graham Cox May 15, 13:53
mlRe: Basic info about outlets Torsten Curdt May 15, 15:21
mlRe: Basic info about outlets Graham Cox May 15, 15:32
mlRe: Basic info about outlets Mike Abdullah May 15, 15:36
mlRe: Basic info about outlets Torsten Curdt May 15, 15:53
mlRe: Basic info about outlets Erik Buck May 15, 16:08
mlRe: Basic info about outlets Graham Cox May 15, 16:13
mlRe: Basic info about outlets John Love May 17, 16:01