Quote:
Originally Posted by baja_yu
How about actually posting the code?
|
its from the photo picker app from apple,
.h file -
Code:
@protocol OverlayViewControllerDelegate;
@interface OverlayViewController : UIViewController <UINavigationControllerDelegate, UIImagePickerControllerDelegate>
{
id <OverlayViewControllerDelegate> delegate;
UIImagePickerController *imagePickerController;
@private
UIBarButtonItem *takePictureButton;
UIBarButtonItem *startStopButton;
UIBarButtonItem *timedButton;
UIBarButtonItem *cancelButton;
NSTimer *tickTimer;
NSTimer *cameraTimer;
SystemSoundID tickSound;
}
@property (nonatomic, assign) id <OverlayViewControllerDelegate> delegate;
.m file,
Code:
#import "OverlayViewController.h"
enum
{
kOneShot, // user wants to take a delayed single shot
kRepeatingShot // user wants to take repeating shots
};
@implementation OverlayViewController
@synthesize delegate, takePictureButton, startStopButton, cancelButton, timedButton, tickTimer, cameraTimer, imagePickerController;