ftp.nice.ch/pub/next/developer/resources/classes/misckit/MiscKit.1.10.0.s.gnutar.gz#/MiscKit/Documentation/Classes/MiscAwakeAction.rtf

This is MiscAwakeAction.rtf in view mode; [Download] [Up]

Release 0.1  Copyright ©1994 by Steve Hayman  All Rights Reserved.






MiscAwakeAction






Inherits From:	Object

Declared In:	MiscAwakeAction.h

Library:	libMiscShell.a





Class Description

MiscAwakeAction is a simple object that automatically sends a target/action message when an application starts up.  It sends the message in two circumstances:
·	Upon receipt of an - awakeFromNib message (which every object in a nib file gets when the file is loaded);
·	Upon receipt of an - awake message, if it looks like we're about to enter Interface Builder's test mode.

The idea is that you can drag one of these objects off of a palette and drop it in your nib file, and connect its target to some other object in the usual way, and that other object will get some sort of message as soon as the application has started (or the nib file has loaded), or as soon as Interface Builder enters test mode.  This lets you create an application where something happens right away when it's launched.

This isn't a particularly sophisticated object, just something that you might find handy for certain quickie programs, especially those that you put together entirely from Interface Builder palettes without any Objective-C.  It is used by the MiscShell palette to cause a shell to be activated right away when a .nib file is opened.




Instance Variables

id target;
SEL action;





Method Types

	- action
	± fire
	- setAction:
	- setTarget:
	- target





Instance Methods

action
-  (SEL)action

setAction:
-  setAction:(SEL)a


setTarget:
-  setTarget:t


target
-  target

These simple methods are just here so that you can hook up a target and action in Interface Builder.

fire
-  fire

This method sends the target/action message, and is called automatically from within - awakeFromNib or - awake as appropriate.






These are the contents of the former NiCE NeXT User Group NeXTSTEP/OpenStep software archive, currently hosted by Netfuture.ch.