moved Classes out of the demo application

This commit is contained in:
Jeena Paradies 2009-11-14 20:51:10 +01:00
parent c4b4108b8b
commit c70793d1f2
18 changed files with 2342 additions and 0 deletions

View file

@ -0,0 +1,195 @@
//
// JPImagePickerController.h
// JPImagePickerController
//
// Created by Jeena on 11.11.09.
// Copyright 2009 Jeena Paradies.
// Licence: MIT-Licence
//
#import <UIKit/UIKit.h>
#import "JPImagePickerOverviewController.h"
@class JPImagePickerController, JPImagePickerOverviewController;
/*!
@enum JPImagePickerControllerThumbnailSize
@abstract Specifies the thumbnail width and height.
@constant kJPImagePickerControllerThumbnailSizeWidth Thumbnail width 75 px.
@constant kJPImagePickerControllerThumbnailSizeHeight Thumbnail height 75 px.
*/
enum JPImagePickerControllerThumbnailSize {
kJPImagePickerControllerThumbnailSizeWidth = 75,
kJPImagePickerControllerThumbnailSizeHeight = 75
};
/*!
@enum JPImagePickerControllerPreviewImageSize
@abstract Specifies the preview image width and height.
@constant kJPImagePickerControllerPreviewImageSizeWidth Preview image width 320 px.
@constant kJPImagePickerControllerPreviewImageSizeHeight Preview image height 420 px.
*/
enum JPImagePickerControllerPreviewImageSize {
kJPImagePickerControllerPreviewImageSizeWidth = 320,
kJPImagePickerControllerPreviewImageSizeHeight = 420
};
#pragma mark -
/*!
@protocol JPImagePickerControllerDelegate
@abstract Delegate protocol for the JPImagePickerController
@discussion You have to implement this delegate in order to
use the JPImagePickerController. This delegate is responsible
for dismissing the picker on cancel or finished picking.
*/
@protocol JPImagePickerControllerDelegate <NSObject>
@optional
/*!
@method imagePickerDidCancel:
@abstract Called when picker did cancel
@discussion This method is called when the user canceled picking.
The delegate is responsible to dismiss the picker here.
@param picker The picker which called this method.
*/
- (void)imagePickerDidCancel:(JPImagePickerController *)picker;
/*!
@method imagePicker:didFinishPickingWithImageNumber:
@abstract Called when the user picked a image.
@discussion This method is called when the user die finish picking.
The delegate is responsible to dismiss the picker here.
@param picker The picker which called this method.
@param imageNumber The number which image the user picked.
*/
- (void)imagePicker:(JPImagePickerController *)picker didFinishPickingWithImageNumber:(NSInteger)imageNumber;
@end
/*!
@protocol JPImagePickerControllerDataSource
@abstract The data source protocol for JPImagePickerController
@discussion The JPImagePickerController asks this data source for all
data which it wants to display.
*/
@protocol JPImagePickerControllerDataSource <NSObject>
@optional
/*!
@method numberOfImagesInImagePicker:
@abstract Should return the number of images.
@discussion This method should return the number of images which the
picker should display.
@param picker The picker which called this method.
*/
- (NSInteger)numberOfImagesInImagePicker:(JPImagePickerController *)picker;
/*!
@method imagePicker:thumbnailForImageNumber:
@abstract Asks the data source for a thumbnail to insert in a particular location
the image picker.
@discussion This method should return a UIImage thumbnail for a image at the
image number position. The image should have the width of kJPImagePickerControllerThumbnailWidth
and height of kJPImagePickerControllerThumbnailWidth. If it is not that size the
image picker will resize it so it fits.
@param picker A picker-object requesting the thumbnail.
@param imageNumber A image number locating the image in the picker.
*/
- (UIImage *)imagePicker:(JPImagePickerController *)picker thumbnailForImageNumber:(NSInteger)imageNumber;
/*!
@method imagePicker:imageForImageNumber:
@abstract Asks the data source for a image to show in a preview.
@discussion This method should return a UIImage image for the preview at
the image number position. The image should have the width of kJPImagePickerControllerPreviewImageWidth
and height of kJPImagePickerControllerPreviewImageWidth. If it is not that size the
image picker will resize it so it fits.
@param picker A picker-object requesting the image.
@param imageNumber A image number locating the image in the picker.
*/
- (UIImage *)imagePicker:(JPImagePickerController *)picker imageForImageNumber:(NSInteger)imageNumber;
@end
#pragma mark -
/*!
@class JPImagePickerController
@abstract A image picker view controller.
@discussion A class which represents a image picker controller like apples UIImagePickerController
but lets you use a external dataSource for the images.
@updated 2009-11-14
*/
@interface JPImagePickerController : UIViewController {
IBOutlet UINavigationController *modalNavigationController;
JPImagePickerOverviewController *overviewController;
UIStatusBarStyle originalStatusBarStyle;
id<JPImagePickerControllerDelegate> delegate;
id<JPImagePickerControllerDataSource> dataSource;
NSString *imagePickerTitle;
}
/*!
@property modalNavigationController
@abstract The additional navigation controller.
@discussion We need it to be able to view a navigation when the user
picks a image.
*/
@property (nonatomic, retain) IBOutlet UINavigationController *modalNavigationController;
/*!
@property overviewController
@abstract Controller for the scrollView.
@discussion This controller holds the scrollView with all the buttons which
represent the images.
*/
@property (nonatomic, retain) JPImagePickerOverviewController *overviewController;
/*!
@property overviewController
@abstract Original StatusBarStyle at the beginning.
@discussion This property saves the UIStatusBarStyle at the beginning, so that
we'll be able to change it back when we dismiss the image picker.
*/
@property (nonatomic, readonly) UIStatusBarStyle originalStatusBarStyle;
/*!
@property delegate
@abstract The image picker's delegate object.
@discussion The delegate receives notifications when the user picks an image,
or exits the picker interface. The delegate also decides when to dismiss
the picker interface, so you must provide a delegate to use a picker.
If this property is nil, the picker is dismissed immediately if you try
to show it.
*/
@property (nonatomic, retain) id<JPImagePickerControllerDelegate> delegate;
/*!
@property dataSource
@abstract The data source for the picker view.
@discussion The data source must adopt the JPImagePickerControllerDataSource protocol
and implement the required methods to return the number of components and the
number of rows in each component.
*/
@property (nonatomic, retain) id<JPImagePickerControllerDataSource> dataSource;
/*!
@property imagePickerTitle
@abstract The image picker title.
@discussion You can set the title for the image overview here.
*/
@property (nonatomic, retain) NSString *imagePickerTitle;
/*!
@method cancelPicking:
@param sender The button which sends the action.
*/
- (void)cancelPicking:(id)sender;
@end

View file

@ -0,0 +1,103 @@
//
// JPImagePickerController.m
// JPImagePickerController
//
// Created by Jeena on 11.11.09.
// Copyright 2009 Jeena Paradies.
// Licence: MIT-Licence
//
#import "JPImagePickerController.h"
@implementation JPImagePickerController
@synthesize overviewController, modalNavigationController, delegate, dataSource, originalStatusBarStyle;
/*
// The designated initializer. Override if you create the controller programmatically and want to perform customization that is not appropriate for viewDidLoad.
- (id)initWithNibName:(NSString *)nibNameOrNil bundle:(NSBundle *)nibBundleOrNil {
if (self = [super initWithNibName:nibNameOrNil bundle:nibBundleOrNil]) {
// Custom initialization
}
return self;
}
*/
// Implement viewDidLoad to do additional setup after loading the view, typically from a nib.
- (void)viewDidLoad {
[super viewDidLoad];
originalStatusBarStyle = [UIApplication sharedApplication].statusBarStyle;
[[UIApplication sharedApplication] setStatusBarStyle:UIStatusBarStyleBlackTranslucent animated:YES];
overviewController = [[JPImagePickerOverviewController alloc] initWithImagePickerController:self];
modalNavigationController = [[UINavigationController alloc] initWithRootViewController:overviewController];
modalNavigationController.view.frame = self.view.bounds;
modalNavigationController.navigationBar.barStyle = UIBarStyleBlackTranslucent;
modalNavigationController.navigationBar.translucent = YES;
[self.view addSubview:modalNavigationController.view];
}
- (void)setImagePickerTitle:(NSString *)newTitle {
imagePickerTitle = newTitle;
[overviewController setImagePickerTitle:newTitle];
}
- (NSString *)imagePickerTitle {
return imagePickerTitle;
}
-(void)viewWillAppear:(BOOL)animated {
[super viewWillAppear:animated];
if (delegate == nil) {
[self.navigationController dismissModalViewControllerAnimated:YES];
}
[modalNavigationController viewWillAppear:animated];
}
-(void)viewWillDisappear:(BOOL)animated {
[super viewWillDisappear:animated];
[modalNavigationController viewWillDisappear:animated];
}
-(void)viewDidAppear:(BOOL)animated {
[super viewDidAppear:animated];
[modalNavigationController viewDidAppear:animated];
}
-(void)viewDidDisappear:(BOOL)animated {
[super viewDidDisappear:animated];
[modalNavigationController viewDidDisappear:animated];
}
/*
// Override to allow orientations other than the default portrait orientation.
- (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation {
// Return YES for supported orientations
return (interfaceOrientation == UIInterfaceOrientationPortrait);
}
*/
- (void)cancelPicking:(id)sender {
[delegate imagePickerDidCancel:self];
}
- (void)didReceiveMemoryWarning {
// Releases the view if it doesn't have a superview.
[super didReceiveMemoryWarning];
// Release any cached data, images, etc that aren't in use.
}
- (void)viewDidUnload {
// Release any retained subviews of the main view.
// e.g. self.myOutlet = nil;
}
- (void)dealloc {
[super dealloc];
}
@end

View file

@ -0,0 +1,35 @@
//
// JPImagePickerDetailController.h
// JPImagePickerController
//
// Created by Jeena on 11.11.09.
// Copyright 2009 Jeena Paradies.
// Licence: MIT-Licence
//
#import <UIKit/UIKit.h>
#import "JPImagePickerController.h"
#import "JPImagePickerOverviewController.h"
#import "UIImageResizing.h"
@protocol JPImagePickerControllerDelegate;
@protocol JPImagePickerControllerDataSource;
@class JPImagePickerOverviewController;
@interface JPImagePickerDetailController : UIViewController {
JPImagePickerOverviewController *overviewController;
IBOutlet UIImageView *previewImageView;
NSInteger imageNumber;
UIStatusBarStyle originalStatusBarStyle;
}
@property (nonatomic, retain) IBOutlet UIImageView *previewImageView;
@property (nonatomic, retain, readonly) JPImagePickerOverviewController *overviewController;
@property (nonatomic) NSInteger imageNumber;
- (id)initWithOverviewController:(JPImagePickerOverviewController *)newOverviewController;
- (void)prepareForImageNumber:(NSInteger)newImageNumber;
- (IBAction)cancelPreview:(id)sender;
- (IBAction)finishedPicking:(id)sender;
@end

View file

@ -0,0 +1,103 @@
//
// JPImagePickerDetailController.m
// JPImagePickerController
//
// Created by Jeena on 11.11.09.
// Copyright 2009 Jeena Paradies.
// Licence: MIT-Licence
//
#import "JPImagePickerDetailController.h"
@implementation JPImagePickerDetailController
@synthesize previewImageView, overviewController, imageNumber;
- (id)initWithOverviewController:(JPImagePickerOverviewController *)newOverviewController {
if (self = [super initWithNibName:@"JPImagePickerDetailController" bundle:nil]) {
// Custom initialization
overviewController = newOverviewController;
imageNumber = -1;
}
return self;
}
// Implement viewDidLoad to do additional setup after loading the view, typically from a nib.
- (void)viewDidLoad {
[super viewDidLoad];
}
- (void)viewWillAppear:(BOOL)animated {
originalStatusBarStyle = [UIApplication sharedApplication].statusBarStyle;
[[UIApplication sharedApplication] setStatusBarStyle:UIStatusBarStyleBlackOpaque animated:YES];
[super viewWillAppear:animated];
[self.navigationController setNavigationBarHidden:YES animated:YES];
[self prepareForImageNumber:imageNumber];
}
/*
- (void)viewDidAppear:(BOOL)animated {
[super viewDidAppear:animated];
}
*/
- (void)viewWillDisappear:(BOOL)animated {
[super viewWillDisappear:animated];
[self.navigationController setNavigationBarHidden:NO animated:YES];
}
/*
- (void)viewDidDisappear:(BOOL)animated {
[super viewDidDisappear:animated];
}
*/
/*
// Override to allow orientations other than the default portrait orientation.
- (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation {
// Return YES for supported orientations
return (interfaceOrientation == UIInterfaceOrientationPortrait);
}
*/
- (void)prepareForImageNumber:(NSInteger)newImageNumber {
imageNumber = newImageNumber;
previewImageView.image = [[overviewController.imagePickerController.dataSource
imagePicker:overviewController.imagePickerController
imageForImageNumber:imageNumber]
scaleToSize:CGSizeMake(kJPImagePickerControllerPreviewImageSizeHeight, kJPImagePickerControllerPreviewImageSizeHeight)
onlyIfNeeded:YES];
}
- (IBAction)cancelPreview:(id)sender {
[[UIApplication sharedApplication] setStatusBarStyle:originalStatusBarStyle animated:YES];
[self.navigationController popViewControllerAnimated:YES];
}
- (IBAction)finishedPicking:(id)sender {
[[UIApplication sharedApplication] setStatusBarStyle:overviewController.imagePickerController.originalStatusBarStyle animated:YES];
[overviewController.imagePickerController.delegate imagePicker:overviewController.imagePickerController didFinishPickingWithImageNumber:imageNumber];
}
- (void)didReceiveMemoryWarning {
// Releases the view if it doesn't have a superview.
[super didReceiveMemoryWarning];
// Release any cached data, images, etc that aren't in use.
}
- (void)viewDidUnload {
// Release any retained subviews of the main view.
// e.g. self.myOutlet = nil;
}
- (void)dealloc {
[super dealloc];
}
@end

View file

@ -0,0 +1,488 @@
<?xml version="1.0" encoding="UTF-8"?>
<archive type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="7.10">
<data>
<int key="IBDocument.SystemTarget">784</int>
<string key="IBDocument.SystemVersion">10C540</string>
<string key="IBDocument.InterfaceBuilderVersion">740</string>
<string key="IBDocument.AppKitVersion">1038.25</string>
<string key="IBDocument.HIToolboxVersion">458.00</string>
<object class="NSMutableDictionary" key="IBDocument.PluginVersions">
<string key="NS.key.0">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
<string key="NS.object.0">62</string>
</object>
<object class="NSMutableArray" key="IBDocument.EditedObjectIDs">
<bool key="EncodedWithXMLCoder">YES</bool>
<integer value="4"/>
</object>
<object class="NSArray" key="IBDocument.PluginDependencies">
<bool key="EncodedWithXMLCoder">YES</bool>
<string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
</object>
<object class="NSMutableDictionary" key="IBDocument.Metadata">
<bool key="EncodedWithXMLCoder">YES</bool>
<object class="NSArray" key="dict.sortedKeys" id="0">
<bool key="EncodedWithXMLCoder">YES</bool>
</object>
<object class="NSMutableArray" key="dict.values">
<bool key="EncodedWithXMLCoder">YES</bool>
</object>
</object>
<object class="NSMutableArray" key="IBDocument.RootObjects" id="1000">
<bool key="EncodedWithXMLCoder">YES</bool>
<object class="IBProxyObject" id="372490531">
<string key="IBProxiedObjectIdentifier">IBFilesOwner</string>
</object>
<object class="IBProxyObject" id="975951072">
<string key="IBProxiedObjectIdentifier">IBFirstResponder</string>
</object>
<object class="IBUIView" id="655272210">
<reference key="NSNextResponder"/>
<int key="NSvFlags">292</int>
<object class="NSMutableArray" key="NSSubviews">
<bool key="EncodedWithXMLCoder">YES</bool>
<object class="IBUIToolbar" id="194791387">
<reference key="NSNextResponder" ref="655272210"/>
<int key="NSvFlags">266</int>
<string key="NSFrame">{{0, 436}, {320, 44}}</string>
<reference key="NSSuperview" ref="655272210"/>
<bool key="IBUIOpaque">NO</bool>
<bool key="IBUIClearsContextBeforeDrawing">NO</bool>
<int key="IBUIBarStyle">2</int>
<object class="NSMutableArray" key="IBUIItems">
<bool key="EncodedWithXMLCoder">YES</bool>
<object class="IBUIBarButtonItem" id="80159321">
<int key="IBUIStyle">1</int>
<reference key="IBUIToolbar" ref="194791387"/>
<int key="IBUISystemItemIdentifier">1</int>
</object>
<object class="IBUIBarButtonItem" id="243887214">
<reference key="IBUIToolbar" ref="194791387"/>
<int key="IBUISystemItemIdentifier">5</int>
</object>
<object class="IBUIBarButtonItem" id="379350294">
<string key="IBUITitle">Choose</string>
<int key="IBUIStyle">2</int>
<reference key="IBUIToolbar" ref="194791387"/>
</object>
</object>
</object>
<object class="IBUIImageView" id="701591828">
<reference key="NSNextResponder" ref="655272210"/>
<int key="NSvFlags">274</int>
<string key="NSFrameSize">{320, 436}</string>
<reference key="NSSuperview" ref="655272210"/>
<bool key="IBUIClearsContextBeforeDrawing">NO</bool>
<int key="IBUIContentMode">4</int>
<bool key="IBUIUserInteractionEnabled">NO</bool>
</object>
</object>
<string key="NSFrameSize">{320, 480}</string>
<reference key="NSSuperview"/>
<object class="NSColor" key="IBUIBackgroundColor">
<int key="NSColorSpace">2</int>
<bytes key="NSRGB">MCAwLjAwNzg0MzEzNzcxOSAwLjAwNzg0MzEzNzcxOQA</bytes>
</object>
<bool key="IBUIClearsContextBeforeDrawing">NO</bool>
<object class="IBUISimulatedStatusBarMetrics" key="IBUISimulatedStatusBarMetrics">
<int key="IBUIStatusBarStyle">1</int>
</object>
</object>
</object>
<object class="IBObjectContainer" key="IBDocument.Objects">
<object class="NSMutableArray" key="connectionRecords">
<bool key="EncodedWithXMLCoder">YES</bool>
<object class="IBConnectionRecord">
<object class="IBCocoaTouchOutletConnection" key="connection">
<string key="label">view</string>
<reference key="source" ref="372490531"/>
<reference key="destination" ref="655272210"/>
</object>
<int key="connectionID">10</int>
</object>
<object class="IBConnectionRecord">
<object class="IBCocoaTouchOutletConnection" key="connection">
<string key="label">previewImageView</string>
<reference key="source" ref="372490531"/>
<reference key="destination" ref="701591828"/>
</object>
<int key="connectionID">11</int>
</object>
<object class="IBConnectionRecord">
<object class="IBCocoaTouchEventConnection" key="connection">
<string key="label">cancelPreview:</string>
<reference key="source" ref="80159321"/>
<reference key="destination" ref="372490531"/>
</object>
<int key="connectionID">12</int>
</object>
<object class="IBConnectionRecord">
<object class="IBCocoaTouchEventConnection" key="connection">
<string key="label">finishedPicking:</string>
<reference key="source" ref="379350294"/>
<reference key="destination" ref="372490531"/>
</object>
<int key="connectionID">13</int>
</object>
</object>
<object class="IBMutableOrderedSet" key="objectRecords">
<object class="NSArray" key="orderedObjects">
<bool key="EncodedWithXMLCoder">YES</bool>
<object class="IBObjectRecord">
<int key="objectID">0</int>
<reference key="object" ref="0"/>
<reference key="children" ref="1000"/>
<nil key="parent"/>
</object>
<object class="IBObjectRecord">
<int key="objectID">-1</int>
<reference key="object" ref="372490531"/>
<reference key="parent" ref="0"/>
<string key="objectName">File's Owner</string>
</object>
<object class="IBObjectRecord">
<int key="objectID">-2</int>
<reference key="object" ref="975951072"/>
<reference key="parent" ref="0"/>
</object>
<object class="IBObjectRecord">
<int key="objectID">4</int>
<reference key="object" ref="655272210"/>
<object class="NSMutableArray" key="children">
<bool key="EncodedWithXMLCoder">YES</bool>
<reference ref="701591828"/>
<reference ref="194791387"/>
</object>
<reference key="parent" ref="0"/>
<string key="objectName">Preview</string>
</object>
<object class="IBObjectRecord">
<int key="objectID">5</int>
<reference key="object" ref="701591828"/>
<reference key="parent" ref="655272210"/>
</object>
<object class="IBObjectRecord">
<int key="objectID">6</int>
<reference key="object" ref="194791387"/>
<object class="NSMutableArray" key="children">
<bool key="EncodedWithXMLCoder">YES</bool>
<reference ref="243887214"/>
<reference ref="379350294"/>
<reference ref="80159321"/>
</object>
<reference key="parent" ref="655272210"/>
</object>
<object class="IBObjectRecord">
<int key="objectID">7</int>
<reference key="object" ref="243887214"/>
<reference key="parent" ref="194791387"/>
</object>
<object class="IBObjectRecord">
<int key="objectID">8</int>
<reference key="object" ref="379350294"/>
<reference key="parent" ref="194791387"/>
</object>
<object class="IBObjectRecord">
<int key="objectID">9</int>
<reference key="object" ref="80159321"/>
<reference key="parent" ref="194791387"/>
</object>
</object>
</object>
<object class="NSMutableDictionary" key="flattenedProperties">
<bool key="EncodedWithXMLCoder">YES</bool>
<object class="NSArray" key="dict.sortedKeys">
<bool key="EncodedWithXMLCoder">YES</bool>
<string>-1.CustomClassName</string>
<string>-2.CustomClassName</string>
<string>4.IBEditorWindowLastContentRect</string>
<string>4.IBPluginDependency</string>
<string>5.IBPluginDependency</string>
<string>6.IBPluginDependency</string>
<string>7.IBPluginDependency</string>
<string>8.IBPluginDependency</string>
<string>9.IBPluginDependency</string>
</object>
<object class="NSMutableArray" key="dict.values">
<bool key="EncodedWithXMLCoder">YES</bool>
<string>JPImagePickerDetailController</string>
<string>UIResponder</string>
<string>{{179, 638}, {320, 480}}</string>
<string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
<string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
<string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
<string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
<string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
<string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
</object>
</object>
<object class="NSMutableDictionary" key="unlocalizedProperties">
<bool key="EncodedWithXMLCoder">YES</bool>
<reference key="dict.sortedKeys" ref="0"/>
<object class="NSMutableArray" key="dict.values">
<bool key="EncodedWithXMLCoder">YES</bool>
</object>
</object>
<nil key="activeLocalization"/>
<object class="NSMutableDictionary" key="localizations">
<bool key="EncodedWithXMLCoder">YES</bool>
<reference key="dict.sortedKeys" ref="0"/>
<object class="NSMutableArray" key="dict.values">
<bool key="EncodedWithXMLCoder">YES</bool>
</object>
</object>
<nil key="sourceID"/>
<int key="maxID">13</int>
</object>
<object class="IBClassDescriber" key="IBDocument.Classes">
<object class="NSMutableArray" key="referencedPartialClassDescriptions">
<bool key="EncodedWithXMLCoder">YES</bool>
<object class="IBPartialClassDescription">
<string key="className">JPImagePickerDetailController</string>
<string key="superclassName">UIViewController</string>
<object class="NSMutableDictionary" key="actions">
<bool key="EncodedWithXMLCoder">YES</bool>
<object class="NSArray" key="dict.sortedKeys">
<bool key="EncodedWithXMLCoder">YES</bool>
<string>cancelPreview:</string>
<string>finishedPicking:</string>
</object>
<object class="NSMutableArray" key="dict.values">
<bool key="EncodedWithXMLCoder">YES</bool>
<string>id</string>
<string>id</string>
</object>
</object>
<object class="NSMutableDictionary" key="outlets">
<string key="NS.key.0">previewImageView</string>
<string key="NS.object.0">UIImageView</string>
</object>
<object class="IBClassDescriptionSource" key="sourceIdentifier">
<string key="majorKey">IBProjectSource</string>
<string key="minorKey">Classes/JPImagePickerDetailController.h</string>
</object>
</object>
</object>
<object class="NSMutableArray" key="referencedPartialClassDescriptionsV3.2+">
<bool key="EncodedWithXMLCoder">YES</bool>
<object class="IBPartialClassDescription">
<string key="className">NSObject</string>
<object class="IBClassDescriptionSource" key="sourceIdentifier">
<string key="majorKey">IBFrameworkSource</string>
<string key="minorKey">Foundation.framework/Headers/NSError.h</string>
</object>
</object>
<object class="IBPartialClassDescription">
<string key="className">NSObject</string>
<object class="IBClassDescriptionSource" key="sourceIdentifier">
<string key="majorKey">IBFrameworkSource</string>
<string key="minorKey">Foundation.framework/Headers/NSFileManager.h</string>
</object>
</object>
<object class="IBPartialClassDescription">
<string key="className">NSObject</string>
<object class="IBClassDescriptionSource" key="sourceIdentifier">
<string key="majorKey">IBFrameworkSource</string>
<string key="minorKey">Foundation.framework/Headers/NSKeyValueCoding.h</string>
</object>
</object>
<object class="IBPartialClassDescription">
<string key="className">NSObject</string>
<object class="IBClassDescriptionSource" key="sourceIdentifier">
<string key="majorKey">IBFrameworkSource</string>
<string key="minorKey">Foundation.framework/Headers/NSKeyValueObserving.h</string>
</object>
</object>
<object class="IBPartialClassDescription">
<string key="className">NSObject</string>
<object class="IBClassDescriptionSource" key="sourceIdentifier">
<string key="majorKey">IBFrameworkSource</string>
<string key="minorKey">Foundation.framework/Headers/NSKeyedArchiver.h</string>
</object>
</object>
<object class="IBPartialClassDescription">
<string key="className">NSObject</string>
<object class="IBClassDescriptionSource" key="sourceIdentifier">
<string key="majorKey">IBFrameworkSource</string>
<string key="minorKey">Foundation.framework/Headers/NSNetServices.h</string>
</object>
</object>
<object class="IBPartialClassDescription">
<string key="className">NSObject</string>
<object class="IBClassDescriptionSource" key="sourceIdentifier">
<string key="majorKey">IBFrameworkSource</string>
<string key="minorKey">Foundation.framework/Headers/NSObject.h</string>
</object>
</object>
<object class="IBPartialClassDescription">
<string key="className">NSObject</string>
<object class="IBClassDescriptionSource" key="sourceIdentifier">
<string key="majorKey">IBFrameworkSource</string>
<string key="minorKey">Foundation.framework/Headers/NSPort.h</string>
</object>
</object>
<object class="IBPartialClassDescription">
<string key="className">NSObject</string>
<object class="IBClassDescriptionSource" key="sourceIdentifier">
<string key="majorKey">IBFrameworkSource</string>
<string key="minorKey">Foundation.framework/Headers/NSRunLoop.h</string>
</object>
</object>
<object class="IBPartialClassDescription">
<string key="className">NSObject</string>
<object class="IBClassDescriptionSource" key="sourceIdentifier">
<string key="majorKey">IBFrameworkSource</string>
<string key="minorKey">Foundation.framework/Headers/NSStream.h</string>
</object>
</object>
<object class="IBPartialClassDescription">
<string key="className">NSObject</string>
<object class="IBClassDescriptionSource" key="sourceIdentifier">
<string key="majorKey">IBFrameworkSource</string>
<string key="minorKey">Foundation.framework/Headers/NSThread.h</string>
</object>
</object>
<object class="IBPartialClassDescription">
<string key="className">NSObject</string>
<object class="IBClassDescriptionSource" key="sourceIdentifier">
<string key="majorKey">IBFrameworkSource</string>
<string key="minorKey">Foundation.framework/Headers/NSURL.h</string>
</object>
</object>
<object class="IBPartialClassDescription">
<string key="className">NSObject</string>
<object class="IBClassDescriptionSource" key="sourceIdentifier">
<string key="majorKey">IBFrameworkSource</string>
<string key="minorKey">Foundation.framework/Headers/NSURLConnection.h</string>
</object>
</object>
<object class="IBPartialClassDescription">
<string key="className">NSObject</string>
<object class="IBClassDescriptionSource" key="sourceIdentifier">
<string key="majorKey">IBFrameworkSource</string>
<string key="minorKey">Foundation.framework/Headers/NSXMLParser.h</string>
</object>
</object>
<object class="IBPartialClassDescription">
<string key="className">NSObject</string>
<object class="IBClassDescriptionSource" key="sourceIdentifier">
<string key="majorKey">IBFrameworkSource</string>
<string key="minorKey">UIKit.framework/Headers/UIAccessibility.h</string>
</object>
</object>
<object class="IBPartialClassDescription">
<string key="className">NSObject</string>
<object class="IBClassDescriptionSource" key="sourceIdentifier">
<string key="majorKey">IBFrameworkSource</string>
<string key="minorKey">UIKit.framework/Headers/UINibLoading.h</string>
</object>
</object>
<object class="IBPartialClassDescription">
<string key="className">NSObject</string>
<object class="IBClassDescriptionSource" key="sourceIdentifier" id="737514611">
<string key="majorKey">IBFrameworkSource</string>
<string key="minorKey">UIKit.framework/Headers/UIResponder.h</string>
</object>
</object>
<object class="IBPartialClassDescription">
<string key="className">UIBarButtonItem</string>
<string key="superclassName">UIBarItem</string>
<object class="IBClassDescriptionSource" key="sourceIdentifier">
<string key="majorKey">IBFrameworkSource</string>
<string key="minorKey">UIKit.framework/Headers/UIBarButtonItem.h</string>
</object>
</object>
<object class="IBPartialClassDescription">
<string key="className">UIBarItem</string>
<string key="superclassName">NSObject</string>
<object class="IBClassDescriptionSource" key="sourceIdentifier">
<string key="majorKey">IBFrameworkSource</string>
<string key="minorKey">UIKit.framework/Headers/UIBarItem.h</string>
</object>
</object>
<object class="IBPartialClassDescription">
<string key="className">UIImageView</string>
<string key="superclassName">UIView</string>
<object class="IBClassDescriptionSource" key="sourceIdentifier">
<string key="majorKey">IBFrameworkSource</string>
<string key="minorKey">UIKit.framework/Headers/UIImageView.h</string>
</object>
</object>
<object class="IBPartialClassDescription">
<string key="className">UIResponder</string>
<string key="superclassName">NSObject</string>
<reference key="sourceIdentifier" ref="737514611"/>
</object>
<object class="IBPartialClassDescription">
<string key="className">UISearchBar</string>
<string key="superclassName">UIView</string>
<object class="IBClassDescriptionSource" key="sourceIdentifier">
<string key="majorKey">IBFrameworkSource</string>
<string key="minorKey">UIKit.framework/Headers/UISearchBar.h</string>
</object>
</object>
<object class="IBPartialClassDescription">
<string key="className">UISearchDisplayController</string>
<string key="superclassName">NSObject</string>
<object class="IBClassDescriptionSource" key="sourceIdentifier">
<string key="majorKey">IBFrameworkSource</string>
<string key="minorKey">UIKit.framework/Headers/UISearchDisplayController.h</string>
</object>
</object>
<object class="IBPartialClassDescription">
<string key="className">UIToolbar</string>
<string key="superclassName">UIView</string>
<object class="IBClassDescriptionSource" key="sourceIdentifier">
<string key="majorKey">IBFrameworkSource</string>
<string key="minorKey">UIKit.framework/Headers/UIToolbar.h</string>
</object>
</object>
<object class="IBPartialClassDescription">
<string key="className">UIView</string>
<object class="IBClassDescriptionSource" key="sourceIdentifier">
<string key="majorKey">IBFrameworkSource</string>
<string key="minorKey">UIKit.framework/Headers/UITextField.h</string>
</object>
</object>
<object class="IBPartialClassDescription">
<string key="className">UIView</string>
<string key="superclassName">UIResponder</string>
<object class="IBClassDescriptionSource" key="sourceIdentifier">
<string key="majorKey">IBFrameworkSource</string>
<string key="minorKey">UIKit.framework/Headers/UIView.h</string>
</object>
</object>
<object class="IBPartialClassDescription">
<string key="className">UIViewController</string>
<object class="IBClassDescriptionSource" key="sourceIdentifier">
<string key="majorKey">IBFrameworkSource</string>
<string key="minorKey">UIKit.framework/Headers/UINavigationController.h</string>
</object>
</object>
<object class="IBPartialClassDescription">
<string key="className">UIViewController</string>
<object class="IBClassDescriptionSource" key="sourceIdentifier">
<string key="majorKey">IBFrameworkSource</string>
<string key="minorKey">UIKit.framework/Headers/UITabBarController.h</string>
</object>
</object>
<object class="IBPartialClassDescription">
<string key="className">UIViewController</string>
<string key="superclassName">UIResponder</string>
<object class="IBClassDescriptionSource" key="sourceIdentifier">
<string key="majorKey">IBFrameworkSource</string>
<string key="minorKey">UIKit.framework/Headers/UIViewController.h</string>
</object>
</object>
</object>
</object>
<int key="IBDocument.localizationMode">0</int>
<object class="NSMutableDictionary" key="IBDocument.PluginDeclaredDevelopmentDependencies">
<string key="NS.key.0">com.apple.InterfaceBuilder.CocoaTouchPlugin.InterfaceBuilder3</string>
<integer value="3000" key="NS.object.0"/>
</object>
<bool key="IBDocument.PluginDeclaredDependenciesTrackSystemTargetVersion">YES</bool>
<string key="IBDocument.LastKnownRelativeProjectPath">../Emoticard.xcodeproj</string>
<int key="IBDocument.defaultPropertyAccessControl">3</int>
<string key="IBCocoaTouchPluginVersion">3.1</string>
</data>
</archive>

View file

@ -0,0 +1,35 @@
//
// JPImagePickerOverviewController.h
// JPImagePickerController
//
// Created by Jeena on 11.11.09.
// Copyright 2009 Jeena Paradies.
// Licence: MIT-Licence
//
#import <UIKit/UIKit.h>
#import "JPImagePickerController.h"
#import "JPImagePickerDetailController.h"
#import "UIImageResizing.h"
@class JPImagePickerController, JPImagePickerDetailController;
@protocol JPImagePickerControllerDelegate, JPImagePickerControllerDataSource;
@interface JPImagePickerOverviewController : UIViewController {
JPImagePickerController *imagePickerController;
JPImagePickerDetailController *detailController;
IBOutlet UIScrollView *scrollView;
}
@property (nonatomic, retain, readonly) JPImagePickerController *imagePickerController;
@property (nonatomic, retain) JPImagePickerDetailController *detailController;
@property (nonatomic, retain) IBOutlet UIScrollView *scrollView;
- (id)initWithImagePickerController:(JPImagePickerController *)newImagePickerController;
- (void)setImagePickerTitle:(NSString *)newTitle;
- (NSString *)imagePickerTitle;
- (IBAction)cancelPicking:(id)sender;
- (void)buttonTouched:(UIButton *)sender;
@end

View file

@ -0,0 +1,128 @@
//
// JPImagePickerOverviewController.m
// JPImagePickerController
//
// Created by Jeena on 11.11.09.
// Copyright 2009 Jeena Paradies.
// Licence: MIT-Licence
//
#import "JPImagePickerOverviewController.h"
@implementation JPImagePickerOverviewController
@synthesize imagePickerController, detailController, scrollView;
#define PADDING_TOP 44
#define PADDING 4
#define THUMBNAIL_COLS 4
- (id)initWithImagePickerController:(JPImagePickerController *)newImagePickerController {
if (self = [super initWithNibName:@"JPImagePickerOverviewController" bundle:nil]) {
// Custom initialization
imagePickerController = newImagePickerController;
}
return self;
}
// Implement viewDidLoad to do additional setup after loading the view, typically from a nib.
- (void)viewDidLoad {
[super viewDidLoad];
[self setImagePickerTitle:imagePickerController.imagePickerTitle];
UIBarButtonItem *cancelButton = [[UIBarButtonItem alloc] initWithBarButtonSystemItem:UIBarButtonSystemItemCancel
target:self
action:@selector(cancelPicking:)];
self.navigationItem.rightBarButtonItem = cancelButton;
[cancelButton release];
UIButton *button;
UIImage *thumbnail;
int images_count = [imagePickerController.dataSource numberOfImagesInImagePicker:imagePickerController];
for (int i=0; i<images_count; i++) {
thumbnail = [[imagePickerController.dataSource imagePicker:imagePickerController thumbnailForImageNumber:(NSInteger)i]
scaleAndCropToSize:CGSizeMake(kJPImagePickerControllerThumbnailSizeWidth, kJPImagePickerControllerThumbnailSizeHeight)
onlyIfNeeded:NO];
button = [UIButton buttonWithType:UIButtonTypeCustom];
[button setImage:thumbnail forState:UIControlStateNormal];
button.showsTouchWhenHighlighted = YES;
button.userInteractionEnabled = YES;
[button addTarget:self action:@selector(buttonTouched:) forControlEvents:UIControlEventTouchUpInside];
button.tag = i;
button.frame = CGRectMake(kJPImagePickerControllerThumbnailSizeWidth * (i % THUMBNAIL_COLS) + PADDING * (i % THUMBNAIL_COLS) + PADDING,
kJPImagePickerControllerThumbnailSizeHeight * (i / THUMBNAIL_COLS) + PADDING * (i / THUMBNAIL_COLS) + PADDING + PADDING_TOP,
kJPImagePickerControllerThumbnailSizeWidth,
kJPImagePickerControllerThumbnailSizeHeight);
[scrollView addSubview:button];
}
int rows = images_count / THUMBNAIL_COLS;
if (((float)images_count / THUMBNAIL_COLS) - rows != 0) {
rows++;
}
int height = kJPImagePickerControllerThumbnailSizeHeight * rows + PADDING * rows + PADDING + PADDING_TOP;
scrollView.contentSize = CGSizeMake(self.view.frame.size.width, height);
scrollView.clipsToBounds = YES;
}
- (void)setImagePickerTitle:(NSString *)newTitle {
self.navigationItem.title = newTitle;
}
- (NSString *)imagePickerTitle {
return self.navigationItem.title;
}
/*
// Override to allow orientations other than the default portrait orientation.
- (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation {
// Return YES for supported orientations
return (interfaceOrientation == UIInterfaceOrientationPortrait);
}
*/
- (IBAction)cancelPicking:(id)sender {
[[UIApplication sharedApplication] setStatusBarStyle:imagePickerController.originalStatusBarStyle animated:YES];
[imagePickerController.delegate imagePickerDidCancel:imagePickerController];
}
- (void)buttonTouched:(UIButton *)sender {
if (detailController == nil) {
detailController = [[JPImagePickerDetailController alloc] initWithOverviewController:self];
}
[detailController prepareForImageNumber:(NSInteger)sender.tag];
[imagePickerController.modalNavigationController pushViewController:detailController animated:YES];
}
- (void)didReceiveMemoryWarning {
// Releases the view if it doesn't have a superview.
[super didReceiveMemoryWarning];
// Release any cached data, images, etc that aren't in use.
}
- (void)viewDidUnload {
// Release any retained subviews of the main view.
// e.g. self.myOutlet = nil;
}
- (void)dealloc {
[imagePickerController release];
[detailController release];
[scrollView release];
[super dealloc];
}
@end

View file

@ -0,0 +1,405 @@
<?xml version="1.0" encoding="UTF-8"?>
<archive type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="7.10">
<data>
<int key="IBDocument.SystemTarget">784</int>
<string key="IBDocument.SystemVersion">10C540</string>
<string key="IBDocument.InterfaceBuilderVersion">740</string>
<string key="IBDocument.AppKitVersion">1038.25</string>
<string key="IBDocument.HIToolboxVersion">458.00</string>
<object class="NSMutableDictionary" key="IBDocument.PluginVersions">
<string key="NS.key.0">com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
<string key="NS.object.0">62</string>
</object>
<object class="NSMutableArray" key="IBDocument.EditedObjectIDs">
<bool key="EncodedWithXMLCoder">YES</bool>
<integer value="1"/>
</object>
<object class="NSArray" key="IBDocument.PluginDependencies">
<bool key="EncodedWithXMLCoder">YES</bool>
<string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
</object>
<object class="NSMutableDictionary" key="IBDocument.Metadata">
<bool key="EncodedWithXMLCoder">YES</bool>
<object class="NSArray" key="dict.sortedKeys" id="0">
<bool key="EncodedWithXMLCoder">YES</bool>
</object>
<object class="NSMutableArray" key="dict.values">
<bool key="EncodedWithXMLCoder">YES</bool>
</object>
</object>
<object class="NSMutableArray" key="IBDocument.RootObjects" id="1000">
<bool key="EncodedWithXMLCoder">YES</bool>
<object class="IBProxyObject" id="372490531">
<string key="IBProxiedObjectIdentifier">IBFilesOwner</string>
</object>
<object class="IBProxyObject" id="975951072">
<string key="IBProxiedObjectIdentifier">IBFirstResponder</string>
</object>
<object class="IBUIView" id="191373211">
<reference key="NSNextResponder"/>
<int key="NSvFlags">264</int>
<object class="NSMutableArray" key="NSSubviews">
<bool key="EncodedWithXMLCoder">YES</bool>
<object class="IBUIScrollView" id="2529775">
<reference key="NSNextResponder" ref="191373211"/>
<int key="NSvFlags">274</int>
<string key="NSFrameSize">{320, 480}</string>
<reference key="NSSuperview" ref="191373211"/>
<bool key="IBUIClipsSubviews">YES</bool>
<bool key="IBUIMultipleTouchEnabled">YES</bool>
<bool key="IBUIBouncesZoom">NO</bool>
</object>
</object>
<string key="NSFrameSize">{320, 480}</string>
<reference key="NSSuperview"/>
<object class="NSColor" key="IBUIBackgroundColor">
<int key="NSColorSpace">3</int>
<bytes key="NSWhite">MQA</bytes>
<object class="NSColorSpace" key="NSCustomColorSpace">
<int key="NSID">2</int>
</object>
</object>
<object class="IBUISimulatedStatusBarMetrics" key="IBUISimulatedStatusBarMetrics">
<int key="IBUIStatusBarStyle">1</int>
</object>
</object>
</object>
<object class="IBObjectContainer" key="IBDocument.Objects">
<object class="NSMutableArray" key="connectionRecords">
<bool key="EncodedWithXMLCoder">YES</bool>
<object class="IBConnectionRecord">
<object class="IBCocoaTouchOutletConnection" key="connection">
<string key="label">view</string>
<reference key="source" ref="372490531"/>
<reference key="destination" ref="191373211"/>
</object>
<int key="connectionID">3</int>
</object>
<object class="IBConnectionRecord">
<object class="IBCocoaTouchOutletConnection" key="connection">
<string key="label">scrollView</string>
<reference key="source" ref="372490531"/>
<reference key="destination" ref="2529775"/>
</object>
<int key="connectionID">5</int>
</object>
</object>
<object class="IBMutableOrderedSet" key="objectRecords">
<object class="NSArray" key="orderedObjects">
<bool key="EncodedWithXMLCoder">YES</bool>
<object class="IBObjectRecord">
<int key="objectID">0</int>
<reference key="object" ref="0"/>
<reference key="children" ref="1000"/>
<nil key="parent"/>
</object>
<object class="IBObjectRecord">
<int key="objectID">1</int>
<reference key="object" ref="191373211"/>
<object class="NSMutableArray" key="children">
<bool key="EncodedWithXMLCoder">YES</bool>
<reference ref="2529775"/>
</object>
<reference key="parent" ref="0"/>
<string key="objectName">ScrollView</string>
</object>
<object class="IBObjectRecord">
<int key="objectID">-1</int>
<reference key="object" ref="372490531"/>
<reference key="parent" ref="0"/>
<string key="objectName">File's Owner</string>
</object>
<object class="IBObjectRecord">
<int key="objectID">-2</int>
<reference key="object" ref="975951072"/>
<reference key="parent" ref="0"/>
</object>
<object class="IBObjectRecord">
<int key="objectID">4</int>
<reference key="object" ref="2529775"/>
<reference key="parent" ref="191373211"/>
</object>
</object>
</object>
<object class="NSMutableDictionary" key="flattenedProperties">
<bool key="EncodedWithXMLCoder">YES</bool>
<object class="NSArray" key="dict.sortedKeys">
<bool key="EncodedWithXMLCoder">YES</bool>
<string>-1.CustomClassName</string>
<string>-2.CustomClassName</string>
<string>1.IBEditorWindowLastContentRect</string>
<string>1.IBPluginDependency</string>
<string>4.IBPluginDependency</string>
</object>
<object class="NSMutableArray" key="dict.values">
<bool key="EncodedWithXMLCoder">YES</bool>
<string>JPImagePickerOverviewController</string>
<string>UIResponder</string>
<string>{{556, 412}, {320, 480}}</string>
<string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
<string>com.apple.InterfaceBuilder.IBCocoaTouchPlugin</string>
</object>
</object>
<object class="NSMutableDictionary" key="unlocalizedProperties">
<bool key="EncodedWithXMLCoder">YES</bool>
<reference key="dict.sortedKeys" ref="0"/>
<object class="NSMutableArray" key="dict.values">
<bool key="EncodedWithXMLCoder">YES</bool>
</object>
</object>
<nil key="activeLocalization"/>
<object class="NSMutableDictionary" key="localizations">
<bool key="EncodedWithXMLCoder">YES</bool>
<reference key="dict.sortedKeys" ref="0"/>
<object class="NSMutableArray" key="dict.values">
<bool key="EncodedWithXMLCoder">YES</bool>
</object>
</object>
<nil key="sourceID"/>
<int key="maxID">5</int>
</object>
<object class="IBClassDescriber" key="IBDocument.Classes">
<object class="NSMutableArray" key="referencedPartialClassDescriptions">
<bool key="EncodedWithXMLCoder">YES</bool>
<object class="IBPartialClassDescription">
<string key="className">JPImagePickerOverviewController</string>
<string key="superclassName">UIViewController</string>
<object class="NSMutableDictionary" key="actions">
<bool key="EncodedWithXMLCoder">YES</bool>
<object class="NSArray" key="dict.sortedKeys">
<bool key="EncodedWithXMLCoder">YES</bool>
<string>buttonTouched:</string>
<string>cancelPicking:</string>
</object>
<object class="NSMutableArray" key="dict.values">
<bool key="EncodedWithXMLCoder">YES</bool>
<string>UIButton</string>
<string>id</string>
</object>
</object>
<object class="NSMutableDictionary" key="outlets">
<string key="NS.key.0">scrollView</string>
<string key="NS.object.0">UIScrollView</string>
</object>
<object class="IBClassDescriptionSource" key="sourceIdentifier">
<string key="majorKey">IBProjectSource</string>
<string key="minorKey">Classes/JPImagePickerOverviewController.h</string>
</object>
</object>
</object>
<object class="NSMutableArray" key="referencedPartialClassDescriptionsV3.2+">
<bool key="EncodedWithXMLCoder">YES</bool>
<object class="IBPartialClassDescription">
<string key="className">NSObject</string>
<object class="IBClassDescriptionSource" key="sourceIdentifier">
<string key="majorKey">IBFrameworkSource</string>
<string key="minorKey">Foundation.framework/Headers/NSError.h</string>
</object>
</object>
<object class="IBPartialClassDescription">
<string key="className">NSObject</string>
<object class="IBClassDescriptionSource" key="sourceIdentifier">
<string key="majorKey">IBFrameworkSource</string>
<string key="minorKey">Foundation.framework/Headers/NSFileManager.h</string>
</object>
</object>
<object class="IBPartialClassDescription">
<string key="className">NSObject</string>
<object class="IBClassDescriptionSource" key="sourceIdentifier">
<string key="majorKey">IBFrameworkSource</string>
<string key="minorKey">Foundation.framework/Headers/NSKeyValueCoding.h</string>
</object>
</object>
<object class="IBPartialClassDescription">
<string key="className">NSObject</string>
<object class="IBClassDescriptionSource" key="sourceIdentifier">
<string key="majorKey">IBFrameworkSource</string>
<string key="minorKey">Foundation.framework/Headers/NSKeyValueObserving.h</string>
</object>
</object>
<object class="IBPartialClassDescription">
<string key="className">NSObject</string>
<object class="IBClassDescriptionSource" key="sourceIdentifier">
<string key="majorKey">IBFrameworkSource</string>
<string key="minorKey">Foundation.framework/Headers/NSKeyedArchiver.h</string>
</object>
</object>
<object class="IBPartialClassDescription">
<string key="className">NSObject</string>
<object class="IBClassDescriptionSource" key="sourceIdentifier">
<string key="majorKey">IBFrameworkSource</string>
<string key="minorKey">Foundation.framework/Headers/NSNetServices.h</string>
</object>
</object>
<object class="IBPartialClassDescription">
<string key="className">NSObject</string>
<object class="IBClassDescriptionSource" key="sourceIdentifier">
<string key="majorKey">IBFrameworkSource</string>
<string key="minorKey">Foundation.framework/Headers/NSObject.h</string>
</object>
</object>
<object class="IBPartialClassDescription">
<string key="className">NSObject</string>
<object class="IBClassDescriptionSource" key="sourceIdentifier">
<string key="majorKey">IBFrameworkSource</string>
<string key="minorKey">Foundation.framework/Headers/NSPort.h</string>
</object>
</object>
<object class="IBPartialClassDescription">
<string key="className">NSObject</string>
<object class="IBClassDescriptionSource" key="sourceIdentifier">
<string key="majorKey">IBFrameworkSource</string>
<string key="minorKey">Foundation.framework/Headers/NSRunLoop.h</string>
</object>
</object>
<object class="IBPartialClassDescription">
<string key="className">NSObject</string>
<object class="IBClassDescriptionSource" key="sourceIdentifier">
<string key="majorKey">IBFrameworkSource</string>
<string key="minorKey">Foundation.framework/Headers/NSStream.h</string>
</object>
</object>
<object class="IBPartialClassDescription">
<string key="className">NSObject</string>
<object class="IBClassDescriptionSource" key="sourceIdentifier">
<string key="majorKey">IBFrameworkSource</string>
<string key="minorKey">Foundation.framework/Headers/NSThread.h</string>
</object>
</object>
<object class="IBPartialClassDescription">
<string key="className">NSObject</string>
<object class="IBClassDescriptionSource" key="sourceIdentifier">
<string key="majorKey">IBFrameworkSource</string>
<string key="minorKey">Foundation.framework/Headers/NSURL.h</string>
</object>
</object>
<object class="IBPartialClassDescription">
<string key="className">NSObject</string>
<object class="IBClassDescriptionSource" key="sourceIdentifier">
<string key="majorKey">IBFrameworkSource</string>
<string key="minorKey">Foundation.framework/Headers/NSURLConnection.h</string>
</object>
</object>
<object class="IBPartialClassDescription">
<string key="className">NSObject</string>
<object class="IBClassDescriptionSource" key="sourceIdentifier">
<string key="majorKey">IBFrameworkSource</string>
<string key="minorKey">Foundation.framework/Headers/NSXMLParser.h</string>
</object>
</object>
<object class="IBPartialClassDescription">
<string key="className">NSObject</string>
<object class="IBClassDescriptionSource" key="sourceIdentifier">
<string key="majorKey">IBFrameworkSource</string>
<string key="minorKey">UIKit.framework/Headers/UIAccessibility.h</string>
</object>
</object>
<object class="IBPartialClassDescription">
<string key="className">NSObject</string>
<object class="IBClassDescriptionSource" key="sourceIdentifier">
<string key="majorKey">IBFrameworkSource</string>
<string key="minorKey">UIKit.framework/Headers/UINibLoading.h</string>
</object>
</object>
<object class="IBPartialClassDescription">
<string key="className">NSObject</string>
<object class="IBClassDescriptionSource" key="sourceIdentifier" id="1039679019">
<string key="majorKey">IBFrameworkSource</string>
<string key="minorKey">UIKit.framework/Headers/UIResponder.h</string>
</object>
</object>
<object class="IBPartialClassDescription">
<string key="className">UIButton</string>
<string key="superclassName">UIControl</string>
<object class="IBClassDescriptionSource" key="sourceIdentifier">
<string key="majorKey">IBFrameworkSource</string>
<string key="minorKey">UIKit.framework/Headers/UIButton.h</string>
</object>
</object>
<object class="IBPartialClassDescription">
<string key="className">UIControl</string>
<string key="superclassName">UIView</string>
<object class="IBClassDescriptionSource" key="sourceIdentifier">
<string key="majorKey">IBFrameworkSource</string>
<string key="minorKey">UIKit.framework/Headers/UIControl.h</string>
</object>
</object>
<object class="IBPartialClassDescription">
<string key="className">UIResponder</string>
<string key="superclassName">NSObject</string>
<reference key="sourceIdentifier" ref="1039679019"/>
</object>
<object class="IBPartialClassDescription">
<string key="className">UIScrollView</string>
<string key="superclassName">UIView</string>
<object class="IBClassDescriptionSource" key="sourceIdentifier">
<string key="majorKey">IBFrameworkSource</string>
<string key="minorKey">UIKit.framework/Headers/UIScrollView.h</string>
</object>
</object>
<object class="IBPartialClassDescription">
<string key="className">UISearchBar</string>
<string key="superclassName">UIView</string>
<object class="IBClassDescriptionSource" key="sourceIdentifier">
<string key="majorKey">IBFrameworkSource</string>
<string key="minorKey">UIKit.framework/Headers/UISearchBar.h</string>
</object>
</object>
<object class="IBPartialClassDescription">
<string key="className">UISearchDisplayController</string>
<string key="superclassName">NSObject</string>
<object class="IBClassDescriptionSource" key="sourceIdentifier">
<string key="majorKey">IBFrameworkSource</string>
<string key="minorKey">UIKit.framework/Headers/UISearchDisplayController.h</string>
</object>
</object>
<object class="IBPartialClassDescription">
<string key="className">UIView</string>
<object class="IBClassDescriptionSource" key="sourceIdentifier">
<string key="majorKey">IBFrameworkSource</string>
<string key="minorKey">UIKit.framework/Headers/UITextField.h</string>
</object>
</object>
<object class="IBPartialClassDescription">
<string key="className">UIView</string>
<string key="superclassName">UIResponder</string>
<object class="IBClassDescriptionSource" key="sourceIdentifier">
<string key="majorKey">IBFrameworkSource</string>
<string key="minorKey">UIKit.framework/Headers/UIView.h</string>
</object>
</object>
<object class="IBPartialClassDescription">
<string key="className">UIViewController</string>
<object class="IBClassDescriptionSource" key="sourceIdentifier">
<string key="majorKey">IBFrameworkSource</string>
<string key="minorKey">UIKit.framework/Headers/UINavigationController.h</string>
</object>
</object>
<object class="IBPartialClassDescription">
<string key="className">UIViewController</string>
<object class="IBClassDescriptionSource" key="sourceIdentifier">
<string key="majorKey">IBFrameworkSource</string>
<string key="minorKey">UIKit.framework/Headers/UITabBarController.h</string>
</object>
</object>
<object class="IBPartialClassDescription">
<string key="className">UIViewController</string>
<string key="superclassName">UIResponder</string>
<object class="IBClassDescriptionSource" key="sourceIdentifier">
<string key="majorKey">IBFrameworkSource</string>
<string key="minorKey">UIKit.framework/Headers/UIViewController.h</string>
</object>
</object>
</object>
</object>
<int key="IBDocument.localizationMode">0</int>
<object class="NSMutableDictionary" key="IBDocument.PluginDeclaredDevelopmentDependencies">
<string key="NS.key.0">com.apple.InterfaceBuilder.CocoaTouchPlugin.InterfaceBuilder3</string>
<integer value="3000" key="NS.object.0"/>
</object>
<bool key="IBDocument.PluginDeclaredDependenciesTrackSystemTargetVersion">YES</bool>
<string key="IBDocument.LastKnownRelativeProjectPath">../Emoticard.xcodeproj</string>
<int key="IBDocument.defaultPropertyAccessControl">3</int>
<string key="IBCocoaTouchPluginVersion">3.1</string>
</data>
</archive>

27
Classes/UIImageResizing.h Normal file
View file

@ -0,0 +1,27 @@
//
// UIImageResizing.h
// JPImagePickerController
//
// Created by Jeena on 07.11.09.
// Copyright 2009 Jeena Paradies.
// Licence: MIT-Licence
//
// Most of this code is from http://stackoverflow.com/questions/603907/uiimage-resize-then-crop
#import <Foundation/Foundation.h>
@interface UIImage (Resize)
+ (UIImage *)image:(UIImage *)sourceImage scaleAndCroppForSize:(CGSize)targetSize;
- (UIImage *)scaleAndCropToSize:(CGSize)newSize;
- (UIImage *)scaleAndCropToSize:(CGSize)targetSize onlyIfNeeded:(BOOL)onlyIfNeeded;
+ (UIImage *)image:(UIImage *)image scaleToSize:(CGSize)newSize;
- (UIImage *)scaleToSize:(CGSize)newSize;
- (UIImage *)scaleToSize:(CGSize)targetSize onlyIfNeeded:(BOOL)onlyIfNeeded;
+ (BOOL)image:(UIImage *)sourceImage needsToScale:(CGSize)targetSize;
- (BOOL)needsToScale:(CGSize)targetSize;
@end

150
Classes/UIImageResizing.m Normal file
View file

@ -0,0 +1,150 @@
//
// UIImageResizing.m
// JPImagePickerController
//
// Created by Jeena on 07.11.09.
// Copyright 2009 Jeena Paradies.
// Licence: MIT-Licence
//
#import "UIImageResizing.h"
@implementation UIImage (Resizing)
+ (UIImage *)image:(UIImage *)sourceImage scaleAndCroppForSize:(CGSize)targetSize {
UIImage *newImage = nil;
CGSize imageSize = sourceImage.size;
CGFloat width = imageSize.width;
CGFloat height = imageSize.height;
CGFloat targetWidth = targetSize.width;
CGFloat targetHeight = targetSize.height;
CGFloat scaleFactor = 0.0;
CGFloat scaledWidth = targetWidth;
CGFloat scaledHeight = targetHeight;
CGPoint thumbnailPoint = CGPointMake(0.0,0.0);
if (CGSizeEqualToSize(imageSize, targetSize) == NO)
{
CGFloat widthFactor = targetWidth / width;
CGFloat heightFactor = targetHeight / height;
if (widthFactor >= heightFactor) {
scaleFactor = widthFactor; // scale to fit height
} else {
scaleFactor = heightFactor; // scale to fit width
}
scaledWidth = width * scaleFactor;
scaledHeight = height * scaleFactor;
// center the image
if (widthFactor >= heightFactor) {
thumbnailPoint.y = (targetHeight - scaledHeight) * 0.5;
} else if (widthFactor < heightFactor) {
thumbnailPoint.x = (targetWidth - scaledWidth) * 0.5;
}
}
UIGraphicsBeginImageContext(targetSize); // this will crop
CGRect thumbnailRect = CGRectZero;
thumbnailRect.origin = thumbnailPoint;
thumbnailRect.size.width = scaledWidth;
thumbnailRect.size.height = scaledHeight;
[sourceImage drawInRect:thumbnailRect];
newImage = UIGraphicsGetImageFromCurrentImageContext();
if(newImage == nil)
NSLog(@"could not scale image");
//pop the context to get back to the default
UIGraphicsEndImageContext();
return newImage;
}
- (UIImage *)scaleAndCropToSize:(CGSize)targetSize {
return [UIImage image:self scaleAndCroppForSize:(CGSize)targetSize];
}
- (UIImage *)scaleAndCropToSize:(CGSize)targetSize onlyIfNeeded:(BOOL)onlyIfNeeded {
UIImage *image;
if (!onlyIfNeeded || [self needsToScale:targetSize]) {
image = [self scaleAndCropToSize:targetSize];
} else {
image = self;
}
return image;
}
+ (UIImage *)image:(UIImage *)sourceImage scaleToSize:(CGSize)targetSize {
CGFloat scaleFactor = 0.0;
CGFloat scaledWidth = targetSize.width;
CGFloat scaledHeight = targetSize.height;
CGFloat widthFactor = targetSize.width / sourceImage.size.width;
CGFloat heightFactor = targetSize.height / sourceImage.size.height;
if (widthFactor < heightFactor) {
scaleFactor = widthFactor; // scale to fit height
} else {
scaleFactor = heightFactor; // scale to fit width
}
scaledWidth = sourceImage.size.width * scaleFactor;
scaledHeight = sourceImage.size.height * scaleFactor;
CGSize propperSize = CGSizeMake(scaledWidth, scaledHeight);
UIGraphicsBeginImageContext( propperSize );
[sourceImage drawInRect:CGRectMake(0, 0, propperSize.width, propperSize.height)];
UIImage* newImage = UIGraphicsGetImageFromCurrentImageContext();
UIGraphicsEndImageContext();
return newImage;
}
- (UIImage *)scaleToSize:(CGSize)newSize {
return [UIImage image:self scaleToSize:newSize];
}
- (UIImage *)scaleToSize:(CGSize)targetSize onlyIfNeeded:(BOOL)onlyIfNeeded {
UIImage *image;
if (!onlyIfNeeded || [self needsToScale:targetSize]) {
image = [self scaleToSize:targetSize];
} else {
image = self;
}
return image;
}
+ (BOOL)image:(UIImage *)sourceImage needsToScale:(CGSize)targetSize {
BOOL needsToScale = NO;
if (sourceImage.size.width > targetSize.width) {
needsToScale = YES;
}
if (sourceImage.size.height > targetSize.height) {
needsToScale = YES;
}
return needsToScale;
}
- (BOOL)needsToScale:(CGSize)targetSize {
return [UIImage image:self needsToScale:targetSize];
}
@end

View file

@ -0,0 +1,188 @@
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"
"http://www.w3.org/TR/1998/REC-html40-19980424/loose.dtd">
<html><head>
<title>JPImagePickerController</title>
<meta http-equiv="Content-Type" content="text/html; charset=ascii" />
<meta name="generator" content="HeaderDoc" />
<meta name="xcode-display" content="render" />
<style><!--
#tocMenu {
display: block;
position:fixed;
top:0px;
left:0px;
width:210px;
height:100%;
background:transparent;
}
#bodyText {
margin-left: 210px;
}
--></style>
<script language="JavaScript" type="text/javascript"><!--
function hidetoc() {
var origURL = parent.document.URL;
var contentURL = origURL.substring(origURL.indexOf('?')+1, origURL.length);
if (contentURL.length == origURL.length) {
jumpPos = origURL.substring(origURL.indexOf('#')+1, origURL.length);
}
if (contentURL == "hidetoc") {
var toc = document.getElementById('tocMenu');
var body = document.getElementById('bodyText');
if (toc && body) {
toc.style.display = 'none';
body.style.marginLeft = '0px';
}
}
}
--></script>
<style type="text/css"><!--.keyword {background:#ffffff; color:#761550;}.template {background:#ffffff; color:#761550;}.number {background: #ffffff; color:#0000ff;}.function {background:#ffffff; color:#000000;}.string {background: #ffffff; color:#891315;}.preprocessor {background:#ffffff; color:#236e25}.comment {background:#ffffff; color:#236e25}.char {background: #ffffff; color:#0000ff;}.var {background:#ffffff; color:#000000;}.type {background:#ffffff; color:#761550;}.param {background:#ffffff; color:#000000;}a:link {text-decoration: none; font-family: lucida grande, geneva, helvetica, arial, sans-serif; font-size: small; color: #0000ff;}a:visited {text-decoration: none; font-family: lucida grande, geneva, helvetica, arial, sans-serif; font-size: small; color: #0000ff;}a:visited:hover {text-decoration: underline; font-family: lucida grande, geneva, helvetica, arial, sans-serif; font-size: small; color: #ff6600;}a:active {text-decoration: none; font-family: lucida grande, geneva, helvetica, arial, sans-serif; font-size: small; color: #ff6600;}a:hover {text-decoration: underline; font-family: lucida grande, geneva, helvetica, arial, sans-serif; font-size: small; color: #ff6600;}h4 {text-decoration: none; font-family: lucida grande, geneva, helvetica, arial, sans-serif; font-size: tiny; font-weight: bold;}body {text-decoration: none; font-family: lucida grande, geneva, helvetica, arial, sans-serif; font-size: 10pt;}.list_indent { margin-left: 40px; }.declaration_indent { margin-left: 40px; }.param_indent { margin-left: 40px; }.group_indent { margin-left: 40px; }.group_desc_indent { margin-left: 20px; }.warning_indent { margin-left: 40px; }.important_indent { margin-left: 40px; }.hd_tocAccess { font-style: italic; font-size: 10px; font-weight: normal; color: #303030; }--></style></head><body bgcolor="#ffffff" onload="hidetoc();">
</div>
<!-- headerDoc=cl; uid=//apple_ref/occ/cl/JPImagePickerController; name=JPImagePickerController-->
<a name="//apple_ref/occ/cl/JPImagePickerController"></a><div id='tocMenu'>
<iframe id='toc_content' name='toc_content' SRC='toc.html' width='210' height='100%' align='left' frameborder='0'>This document set is best viewed in a browser that supports iFrames.</iframe>
</div>
<div id='bodyText'>
<a name="top"></a>
<hr><table border="0" cellpadding="2" cellspacing="2" width="300"><tr><td valign="top" height="12" colspan="5"><h1><a name="JPImagePickerController">JPImagePickerController</a></h1>
</td></tr></table><hr><p><!-- begin abstract --><p>A image picker view controller.
<!-- end abstract --></p>
<p><b>Superclass:</b> <!-- a logicalPath="//apple_ref/occ/cl/UIViewController" -->UIViewController<!-- /a --><br>
<b>Declared In:</b> <a href="../../index.html" target="_top">JPImagePickerController.h</a><br>
</p><div class='declaration_indent'>
</div>
<h5 class="tight"><font face="Lucida Grande,Helvetica,Arial">Discussion</font>
</h5><!-- begin discussion --><p>A class which represents a image picker controller like apples UIImagePickerController
but lets you use a external dataSource for the images.
<!-- end discussion -->
<p></p><dl><dt><i>Updated:</i></dt><dd>Saturday, November 14, 2009</dd>
</dl>
<hr><br><a name="HeaderDoc_methods"></a>
<h2>Methods</h2>
<dl>
<dt><tt><a href="index.html#//apple_ref/occ/instm/JPImagePickerController/cancelPicking:" target="_top">-cancelPicking:</a></tt></dt>
<dd></dd>
</dl>
<hr><!-- headerDoc=instm; uid=//apple_ref/occ/instm/JPImagePickerController/cancelPicking:; name=JPImagePickerController::cancelPicking: -->
<a name="//apple_ref/occ/instm/JPImagePickerController/cancelPicking:"></a>
<table border="0" cellpadding="2" cellspacing="2" width="300"><tr><td valign="top" height="12" colspan="5"><h3><a name="cancelPicking:">cancelPicking:</a></h3>
</td></tr></table><hr><p></p><div class='declaration_indent'>
<pre>- (<!-- a logicalPath="//apple_ref/occ/cl/void //apple_ref/occ/tdef/void //apple_ref/occ/tag/void //apple_ref/occ/econst/void //apple_ref/occ/struct/void //apple_ref/occ/clconst/void //apple_ref/occ/intf/void" --><span class="type">void</span><!-- /a -->)<!-- a logicalPath="//apple_ref/occ/instm/cancelPicking //apple_ref/occ/clm/cancelPicking //apple_ref/occ/intfcm/cancelPicking //apple_ref/occ/intfm/cancelPicking //apple_ref/occ/func/cancelPicking //apple_ref/occ/ftmplt/cancelPicking //apple_ref/occ/defn/cancelPicking //apple_ref/occ/macro/cancelPicking" --><span class="function">cancelPicking</span><!-- /a -->:(<!-- a logicalPath="//apple_ref/occ/cl/id //apple_ref/occ/tdef/id //apple_ref/occ/tag/id //apple_ref/occ/econst/id //apple_ref/occ/struct/id //apple_ref/occ/clconst/id //apple_ref/occ/intf/id" --><span class="type">id</span><!-- /a -->)<!-- a logicalPath="//apple_ref/occ/econst/sender //apple_ref/occ/data/sender" --><span class="var">sender</span><!-- /a -->; </pre>
</div>
<h5 class="tight"><font face="Lucida Grande,Helvetica,Arial">Parameters</font></h5>
<div class='param_indent'>
<dl>
<dt><code>sender</code></dt><dd><p>The button which sends the action.</dd>
</dl>
</div>
<p></p><a name="HeaderDoc_props"></a>
<h2>Properties</h2>
<dl>
<dt><tt><a href="index.html#//apple_ref/occ/instp/JPImagePickerController/dataSource" target="_top">dataSource</a></tt></dt>
<dd><p>The data source for the picker view.
</dd>
<dt><tt><a href="index.html#//apple_ref/occ/instp/JPImagePickerController/delegate" target="_top">delegate</a></tt></dt>
<dd><p>The image picker's delegate object.
</dd>
<dt><tt><a href="index.html#//apple_ref/occ/instp/JPImagePickerController/imagePickerTitle" target="_top">imagePickerTitle</a></tt></dt>
<dd><p>The image picker title.
</dd>
<dt><tt><a href="index.html#//apple_ref/occ/instp/JPImagePickerController/modalNavigationController" target="_top">modalNavigationController</a></tt></dt>
<dd><p>The additional navigation controller.
</dd>
<dt><tt><a href="index.html#//apple_ref/occ/instp/JPImagePickerController/originalStatusBarStyle" target="_top">originalStatusBarStyle</a></tt></dt>
<dd><p>Original StatusBarStyle at the beginning.
</dd>
<dt><tt><a href="index.html#//apple_ref/occ/instp/JPImagePickerController/overviewController" target="_top">overviewController</a></tt></dt>
<dd><p>Controller for the scrollView.
</dd>
</dl>
<hr><!-- headerDoc=instp; uid=//apple_ref/occ/instp/JPImagePickerController/dataSource; name=JPImagePickerController::dataSource -->
<a name="//apple_ref/occ/instp/JPImagePickerController/dataSource"></a>
<table border="0" cellpadding="2" cellspacing="2" width="300"><tr><td valign="top" height="12" colspan="5"><h3><a name="dataSource">dataSource</a></h3>
</td></tr></table><hr><p><!-- begin abstract --><p>The data source for the picker view.
<!-- end abstract --></p>
<p></p><div class='declaration_indent'>
<pre>@property (
<span class="param">nonatomic</span>,
<span class="param">retain</span>) <!-- a logicalPath="//apple_ref/occ/cl/id //apple_ref/occ/tdef/id //apple_ref/occ/tag/id //apple_ref/occ/econst/id //apple_ref/occ/struct/id //apple_ref/occ/clconst/id //apple_ref/occ/intf/id" --><span class="type">id</span><!-- /a -->&lt;<span class="template">JPImagePickerControllerDataSource</span>&gt; <!-- a logicalPath="//apple_ref/occ/econst/dataSource //apple_ref/occ/data/dataSource" --><span class="var">dataSource</span><!-- /a -->; </pre>
</div>
<h5 class="tight"><font face="Lucida Grande,Helvetica,Arial">Discussion</font>
</h5><!-- begin discussion --><p>The data source must adopt the JPImagePickerControllerDataSource protocol
and implement the required methods to return the number of components and the
number of rows in each component.
<!-- end discussion -->
<p></p><hr><!-- headerDoc=instp; uid=//apple_ref/occ/instp/JPImagePickerController/delegate; name=JPImagePickerController::delegate -->
<a name="//apple_ref/occ/instp/JPImagePickerController/delegate"></a>
<table border="0" cellpadding="2" cellspacing="2" width="300"><tr><td valign="top" height="12" colspan="5"><h3><a name="delegate">delegate</a></h3>
</td></tr></table><hr><p><!-- begin abstract --><p>The image picker's delegate object.
<!-- end abstract --></p>
<p></p><div class='declaration_indent'>
<pre>@property (
<span class="param">nonatomic</span>,
<span class="param">retain</span>) <!-- a logicalPath="//apple_ref/occ/cl/id //apple_ref/occ/tdef/id //apple_ref/occ/tag/id //apple_ref/occ/econst/id //apple_ref/occ/struct/id //apple_ref/occ/clconst/id //apple_ref/occ/intf/id" --><span class="type">id</span><!-- /a -->&lt;<span class="template">JPImagePickerControllerDelegate</span>&gt; <!-- a logicalPath="//apple_ref/occ/econst/delegate //apple_ref/occ/data/delegate" --><span class="var">delegate</span><!-- /a -->; </pre>
</div>
<h5 class="tight"><font face="Lucida Grande,Helvetica,Arial">Discussion</font>
</h5><!-- begin discussion --><p>The delegate receives notifications when the user picks an image,
or exits the picker interface. The delegate also decides when to dismiss
the picker interface, so you must provide a delegate to use a picker.
If this property is nil, the picker is dismissed immediately if you try
to show it.
<!-- end discussion -->
<p></p><hr><!-- headerDoc=instp; uid=//apple_ref/occ/instp/JPImagePickerController/imagePickerTitle; name=JPImagePickerController::imagePickerTitle -->
<a name="//apple_ref/occ/instp/JPImagePickerController/imagePickerTitle"></a>
<table border="0" cellpadding="2" cellspacing="2" width="300"><tr><td valign="top" height="12" colspan="5"><h3><a name="imagePickerTitle">imagePickerTitle</a></h3>
</td></tr></table><hr><p><!-- begin abstract --><p>The image picker title.
<!-- end abstract --></p>
<p></p><div class='declaration_indent'>
<pre>@property (
<span class="param">nonatomic</span>,
<span class="param">retain</span>) <!-- a logicalPath="//apple_ref/occ/cl/NSString //apple_ref/occ/tdef/NSString //apple_ref/occ/tag/NSString //apple_ref/occ/econst/NSString //apple_ref/occ/struct/NSString //apple_ref/occ/clconst/NSString //apple_ref/occ/intf/NSString" --><span class="type">NSString</span><!-- /a --> <span class="type">*</span><!-- a logicalPath="//apple_ref/occ/econst/imagePickerTitle //apple_ref/occ/data/imagePickerTitle" --><span class="var">imagePickerTitle</span><!-- /a -->; </pre>
</div>
<h5 class="tight"><font face="Lucida Grande,Helvetica,Arial">Discussion</font>
</h5><!-- begin discussion --><p>You can set the title for the image overview here.
<!-- end discussion -->
<p></p><hr><!-- headerDoc=instp; uid=//apple_ref/occ/instp/JPImagePickerController/modalNavigationController; name=JPImagePickerController::modalNavigationController -->
<a name="//apple_ref/occ/instp/JPImagePickerController/modalNavigationController"></a>
<table border="0" cellpadding="2" cellspacing="2" width="300"><tr><td valign="top" height="12" colspan="5"><h3><a name="modalNavigationController">modalNavigationController</a></h3>
</td></tr></table><hr><p><!-- begin abstract --><p>The additional navigation controller.
<!-- end abstract --></p>
<p></p><div class='declaration_indent'>
<pre>@property (
<span class="param">nonatomic</span>,
<span class="param">retain</span>) <!-- a logicalPath="//apple_ref/occ/cl/IBOutlet //apple_ref/occ/tdef/IBOutlet //apple_ref/occ/tag/IBOutlet //apple_ref/occ/econst/IBOutlet //apple_ref/occ/struct/IBOutlet //apple_ref/occ/clconst/IBOutlet //apple_ref/occ/intf/IBOutlet" --><span class="type">IBOutlet</span><!-- /a --> <!-- a logicalPath="//apple_ref/occ/cl/UINavigationController //apple_ref/occ/tdef/UINavigationController //apple_ref/occ/tag/UINavigationController //apple_ref/occ/econst/UINavigationController //apple_ref/occ/struct/UINavigationController //apple_ref/occ/clconst/UINavigationController //apple_ref/occ/intf/UINavigationController" --><span class="type">UINavigationController</span><!-- /a --> <span class="type">*</span><!-- a logicalPath="//apple_ref/occ/econst/modalNavigationController //apple_ref/occ/data/modalNavigationController" --><span class="var">modalNavigationController</span><!-- /a -->; </pre>
</div>
<h5 class="tight"><font face="Lucida Grande,Helvetica,Arial">Discussion</font>
</h5><!-- begin discussion --><p>We need it to be able to view a navigation when the user
picks a image.
<!-- end discussion -->
<p></p><hr><!-- headerDoc=instp; uid=//apple_ref/occ/instp/JPImagePickerController/originalStatusBarStyle; name=JPImagePickerController::originalStatusBarStyle -->
<a name="//apple_ref/occ/instp/JPImagePickerController/originalStatusBarStyle"></a>
<table border="0" cellpadding="2" cellspacing="2" width="300"><tr><td valign="top" height="12" colspan="5"><h3><a name="originalStatusBarStyle">originalStatusBarStyle</a></h3>
</td></tr></table><hr><p><!-- begin abstract --><p>Original StatusBarStyle at the beginning.
<!-- end abstract --></p>
<p></p><div class='declaration_indent'>
<pre>@property (
<span class="param">nonatomic</span>,
<span class="param">readonly</span>) <!-- a logicalPath="//apple_ref/occ/cl/UIStatusBarStyle //apple_ref/occ/tdef/UIStatusBarStyle //apple_ref/occ/tag/UIStatusBarStyle //apple_ref/occ/econst/UIStatusBarStyle //apple_ref/occ/struct/UIStatusBarStyle //apple_ref/occ/clconst/UIStatusBarStyle //apple_ref/occ/intf/UIStatusBarStyle" --><span class="type">UIStatusBarStyle</span><!-- /a --> <!-- a logicalPath="//apple_ref/occ/econst/originalStatusBarStyle //apple_ref/occ/data/originalStatusBarStyle" --><span class="var">originalStatusBarStyle</span><!-- /a -->; </pre>
</div>
<h5 class="tight"><font face="Lucida Grande,Helvetica,Arial">Discussion</font>
</h5><!-- begin discussion --><p>This property saves the UIStatusBarStyle at the beginning, so that
we'll be able to change it back when we dismiss the image picker.
<!-- end discussion -->
<p></p><hr><!-- headerDoc=instp; uid=//apple_ref/occ/instp/JPImagePickerController/overviewController; name=JPImagePickerController::overviewController -->
<a name="//apple_ref/occ/instp/JPImagePickerController/overviewController"></a>
<table border="0" cellpadding="2" cellspacing="2" width="300"><tr><td valign="top" height="12" colspan="5"><h3><a name="overviewController">overviewController</a></h3>
</td></tr></table><hr><p><!-- begin abstract --><p>Controller for the scrollView.
<!-- end abstract --></p>
<p></p><div class='declaration_indent'>
<pre>@property (
<span class="param">nonatomic</span>,
<span class="param">retain</span>) <!-- a logicalPath="//apple_ref/occ/cl/JPImagePickerOverviewController //apple_ref/occ/tdef/JPImagePickerOverviewController //apple_ref/occ/tag/JPImagePickerOverviewController //apple_ref/occ/econst/JPImagePickerOverviewController //apple_ref/occ/struct/JPImagePickerOverviewController //apple_ref/occ/clconst/JPImagePickerOverviewController //apple_ref/occ/intf/JPImagePickerOverviewController" --><span class="type">JPImagePickerOverviewController</span><!-- /a --> <span class="type">*</span><!-- a logicalPath="//apple_ref/occ/econst/overviewController //apple_ref/occ/data/overviewController" --><span class="var">overviewController</span><!-- /a -->; </pre>
</div>
<h5 class="tight"><font face="Lucida Grande,Helvetica,Arial">Discussion</font>
</h5><!-- begin discussion --><p>This controller holds the scrollView with all the buttons which
represent the images.
<!-- end discussion -->
<p></p><p>Last Updated: Saturday, November 14, 2009
</p></body></html>

View file

@ -0,0 +1,35 @@
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"
"http://www.w3.org/TR/1998/REC-html40-19980424/loose.dtd">
<html><head>
<meta name="ROBOTS" content="NOINDEX" />
<title>Documentation for JPImagePickerController (JPImagePickerController.h)</title>
<meta http-equiv="Content-Type" content="text/html; charset=ascii" />
<meta name="generator" content="HeaderDoc" />
<meta name="xcode-display" content="render" />
<style type="text/css"><!--.keyword {background:#ffffff; color:#761550;}.template {background:#ffffff; color:#761550;}.number {background: #ffffff; color:#0000ff;}.function {background:#ffffff; color:#000000;}.string {background: #ffffff; color:#891315;}.preprocessor {background:#ffffff; color:#236e25}.comment {background:#ffffff; color:#236e25}.char {background: #ffffff; color:#0000ff;}.var {background:#ffffff; color:#000000;}.type {background:#ffffff; color:#761550;}.param {background:#ffffff; color:#000000;}a:link {text-decoration: none; font-family: lucida grande, geneva, helvetica, arial, sans-serif; font-size: small; color: #0000ff;}a:visited {text-decoration: none; font-family: lucida grande, geneva, helvetica, arial, sans-serif; font-size: small; color: #0000ff;}a:visited:hover {text-decoration: underline; font-family: lucida grande, geneva, helvetica, arial, sans-serif; font-size: small; color: #ff6600;}a:active {text-decoration: none; font-family: lucida grande, geneva, helvetica, arial, sans-serif; font-size: small; color: #ff6600;}a:hover {text-decoration: underline; font-family: lucida grande, geneva, helvetica, arial, sans-serif; font-size: small; color: #ff6600;}h4 {text-decoration: none; font-family: lucida grande, geneva, helvetica, arial, sans-serif; font-size: tiny; font-weight: bold;}body {text-decoration: none; font-family: lucida grande, geneva, helvetica, arial, sans-serif; font-size: 10pt;}.list_indent { margin-left: 40px; }.declaration_indent { margin-left: 40px; }.param_indent { margin-left: 40px; }.group_indent { margin-left: 40px; }.group_desc_indent { margin-left: 20px; }.warning_indent { margin-left: 40px; }.important_indent { margin-left: 40px; }.hd_tocAccess { font-style: italic; font-size: 10px; font-weight: normal; color: #303030; }--></style></head>
<body bgcolor="#edf2f6" link="#000099" vlink="#660066"
leftmargin="0" topmargin="0" marginwidth="0"
marginheight="0">
<table width="100%" cellpadding=0 cellspacing=0 border=0><tr height=51 width="100%" bgcolor="#466C9B"><td width="100%">&nbsp;</td></tr><tr><td><br><table border="0" cellpadding="0" cellspacing="2" width="148">
<tr><td width="15">&nbsp;</td><td colspan="2"><font size="5" color="#330066"><b>Class:</b></font></td></tr>
<tr><td width="15">&nbsp;</td><td width="15">&nbsp;</td><td><b><font size="+1">JPImagePickerController</font></b></td></tr>
<tr><td></td><td colspan="2">
<h4><br><nobr><a href="index.html#top" target="doc">Introduction</a></nobr></h4>
<h4><a href="index.html#HeaderDoc_methods" target="doc">Methods</a></h4>
<h5 class='hd_tocAccess'>Instance Methods</h5>
<nobr>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font size="-1">-</font><a href="index.html#//apple_ref/occ/instm/JPImagePickerController/cancelPicking:" target="doc">cancelPicking:</a></nobr><br>
<h4><a href="index.html#HeaderDoc_props" target="doc">Properties</a></h4>
<nobr>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="index.html#//apple_ref/occ/instp/JPImagePickerController/dataSource" target="doc">dataSource</a></nobr><br>
<nobr>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="index.html#//apple_ref/occ/instp/JPImagePickerController/delegate" target="doc">delegate</a></nobr><br>
<nobr>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="index.html#//apple_ref/occ/instp/JPImagePickerController/imagePickerTitle" target="doc">imagePickerTitle</a></nobr><br>
<nobr>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="index.html#//apple_ref/occ/instp/JPImagePickerController/modalNavigationController" target="doc">modalNavigationController</a></nobr><br>
<nobr>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="index.html#//apple_ref/occ/instp/JPImagePickerController/originalStatusBarStyle" target="doc">originalStatusBarStyle</a></nobr><br>
<nobr>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="index.html#//apple_ref/occ/instp/JPImagePickerController/overviewController" target="doc">overviewController</a></nobr><br>
<br><h4>Other Reference</h4><hr>
<nobr>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="../../index.html" target="_top">Header</a></nobr><br>
<p><i>Updated: Saturday, November 14, 2009</i><p></td></tr>
</table><p>&nbsp;<p>
</td></tr></table>
</body></html>

View file

@ -0,0 +1,136 @@
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"
"http://www.w3.org/TR/1998/REC-html40-19980424/loose.dtd">
<html><head>
<title>JPImagePickerControllerDataSource</title>
<meta http-equiv="Content-Type" content="text/html; charset=ascii" />
<meta name="generator" content="HeaderDoc" />
<meta name="xcode-display" content="render" />
<style><!--
#tocMenu {
display: block;
position:fixed;
top:0px;
left:0px;
width:210px;
height:100%;
background:transparent;
}
#bodyText {
margin-left: 210px;
}
--></style>
<script language="JavaScript" type="text/javascript"><!--
function hidetoc() {
var origURL = parent.document.URL;
var contentURL = origURL.substring(origURL.indexOf('?')+1, origURL.length);
if (contentURL.length == origURL.length) {
jumpPos = origURL.substring(origURL.indexOf('#')+1, origURL.length);
}
if (contentURL == "hidetoc") {
var toc = document.getElementById('tocMenu');
var body = document.getElementById('bodyText');
if (toc && body) {
toc.style.display = 'none';
body.style.marginLeft = '0px';
}
}
}
--></script>
<style type="text/css"><!--.keyword {background:#ffffff; color:#761550;}.template {background:#ffffff; color:#761550;}.number {background: #ffffff; color:#0000ff;}.function {background:#ffffff; color:#000000;}.string {background: #ffffff; color:#891315;}.preprocessor {background:#ffffff; color:#236e25}.comment {background:#ffffff; color:#236e25}.char {background: #ffffff; color:#0000ff;}.var {background:#ffffff; color:#000000;}.type {background:#ffffff; color:#761550;}.param {background:#ffffff; color:#000000;}a:link {text-decoration: none; font-family: lucida grande, geneva, helvetica, arial, sans-serif; font-size: small; color: #0000ff;}a:visited {text-decoration: none; font-family: lucida grande, geneva, helvetica, arial, sans-serif; font-size: small; color: #0000ff;}a:visited:hover {text-decoration: underline; font-family: lucida grande, geneva, helvetica, arial, sans-serif; font-size: small; color: #ff6600;}a:active {text-decoration: none; font-family: lucida grande, geneva, helvetica, arial, sans-serif; font-size: small; color: #ff6600;}a:hover {text-decoration: underline; font-family: lucida grande, geneva, helvetica, arial, sans-serif; font-size: small; color: #ff6600;}h4 {text-decoration: none; font-family: lucida grande, geneva, helvetica, arial, sans-serif; font-size: tiny; font-weight: bold;}body {text-decoration: none; font-family: lucida grande, geneva, helvetica, arial, sans-serif; font-size: 10pt;}.list_indent { margin-left: 40px; }.declaration_indent { margin-left: 40px; }.param_indent { margin-left: 40px; }.group_indent { margin-left: 40px; }.group_desc_indent { margin-left: 20px; }.warning_indent { margin-left: 40px; }.important_indent { margin-left: 40px; }.hd_tocAccess { font-style: italic; font-size: 10px; font-weight: normal; color: #303030; }--></style></head><body bgcolor="#ffffff" onload="hidetoc();">
</div>
<!-- headerDoc=intf; uid=//apple_ref/occ/intf/JPImagePickerControllerDataSource; name=JPImagePickerControllerDataSource-->
<a name="//apple_ref/occ/intf/JPImagePickerControllerDataSource"></a><div id='tocMenu'>
<iframe id='toc_content' name='toc_content' SRC='toc.html' width='210' height='100%' align='left' frameborder='0'>This document set is best viewed in a browser that supports iFrames.</iframe>
</div>
<div id='bodyText'>
<a name="top"></a>
<hr><table border="0" cellpadding="2" cellspacing="2" width="300"><tr><td valign="top" height="12" colspan="5"><h1><a name="JPImagePickerControllerDataSource">JPImagePickerControllerDataSource</a></h1>
</td></tr></table><hr><p><!-- begin abstract --><p>The data source protocol for JPImagePickerController
<!-- end abstract --></p>
<p><b>Extends&nbsp;Protocol:</b> <!-- a logicalPath="//apple_ref/occ/intf/NSObject" -->NSObject<!-- /a --><br>
<b>Declared In:</b> <a href="../../index.html" target="_top">JPImagePickerController.h</a><br>
</p><div class='declaration_indent'>
</div>
<h5 class="tight"><font face="Lucida Grande,Helvetica,Arial">Discussion</font>
</h5><!-- begin discussion --><p>The JPImagePickerController asks this data source for all
data which it wants to display.
<!-- end discussion -->
<p></p><hr><br><a name="HeaderDoc_methods"></a>
<h2>Methods</h2>
<dl>
<dt><tt><a href="index.html#//apple_ref/occ/intfm/JPImagePickerControllerDataSource/imagePicker:imageForImageNumber:" target="_top">-imagePicker:imageForImageNumber:</a></tt></dt>
<dd><p>Asks the data source for a image to show in a preview.
</dd>
<dt><tt><a href="index.html#//apple_ref/occ/intfm/JPImagePickerControllerDataSource/imagePicker:thumbnailForImageNumber:" target="_top">-imagePicker:thumbnailForImageNumber:</a></tt></dt>
<dd><p>Asks the data source for a thumbnail to insert in a particular location
the image picker.
</dd>
<dt><tt><a href="index.html#//apple_ref/occ/intfm/JPImagePickerControllerDataSource/numberOfImagesInImagePicker:" target="_top">-numberOfImagesInImagePicker:</a></tt></dt>
<dd><p>Should return the number of images.
</dd>
</dl>
<hr><!-- headerDoc=intfm; uid=//apple_ref/occ/intfm/JPImagePickerControllerDataSource/imagePicker:imageForImageNumber:; name=JPImagePickerControllerDataSource::imagePicker:imageForImageNumber: -->
<a name="//apple_ref/occ/intfm/JPImagePickerControllerDataSource/imagePicker:imageForImageNumber:"></a>
<table border="0" cellpadding="2" cellspacing="2" width="300"><tr><td valign="top" height="12" colspan="5"><h3><a name="imagePicker:imageForImageNumber:">imagePicker:imageForImageNumber:</a></h3>
</td></tr></table><hr><p><!-- begin abstract --><p>Asks the data source for a image to show in a preview.
<!-- end abstract --></p>
<p></p><div class='declaration_indent'>
<pre>- (<!-- a logicalPath="//apple_ref/occ/cl/UIImage //apple_ref/occ/tdef/UIImage //apple_ref/occ/tag/UIImage //apple_ref/occ/econst/UIImage //apple_ref/occ/struct/UIImage //apple_ref/occ/clconst/UIImage //apple_ref/occ/intf/UIImage" --><span class="type">UIImage</span><!-- /a --> <span class="type">*</span>)<!-- a logicalPath="//apple_ref/occ/instm/imagePicker //apple_ref/occ/clm/imagePicker //apple_ref/occ/intfcm/imagePicker //apple_ref/occ/intfm/imagePicker //apple_ref/occ/func/imagePicker //apple_ref/occ/ftmplt/imagePicker //apple_ref/occ/defn/imagePicker //apple_ref/occ/macro/imagePicker" --><span class="function">imagePicker</span><!-- /a -->:(<!-- a logicalPath="//apple_ref/occ/cl/JPImagePickerController //apple_ref/occ/tdef/JPImagePickerController //apple_ref/occ/tag/JPImagePickerController //apple_ref/occ/econst/JPImagePickerController //apple_ref/occ/struct/JPImagePickerController //apple_ref/occ/clconst/JPImagePickerController //apple_ref/occ/intf/JPImagePickerController" --><span class="type">JPImagePickerController</span><!-- /a --> <span class="type">*</span>)<span class="param">picker</span>
<!-- a logicalPath="//apple_ref/occ/instm/imageForImageNumber //apple_ref/occ/clm/imageForImageNumber //apple_ref/occ/intfcm/imageForImageNumber //apple_ref/occ/intfm/imageForImageNumber //apple_ref/occ/func/imageForImageNumber //apple_ref/occ/ftmplt/imageForImageNumber //apple_ref/occ/defn/imageForImageNumber //apple_ref/occ/macro/imageForImageNumber" --><span class="function">imageForImageNumber</span><!-- /a -->:(<!-- a logicalPath="//apple_ref/occ/cl/NSInteger //apple_ref/occ/tdef/NSInteger //apple_ref/occ/tag/NSInteger //apple_ref/occ/econst/NSInteger //apple_ref/occ/struct/NSInteger //apple_ref/occ/clconst/NSInteger //apple_ref/occ/intf/NSInteger" --><span class="type">NSInteger</span><!-- /a -->)<!-- a logicalPath="//apple_ref/occ/econst/imageNumber //apple_ref/occ/data/imageNumber" --><span class="var">imageNumber</span><!-- /a -->; </pre>
</div>
<h5 class="tight"><font face="Lucida Grande,Helvetica,Arial">Parameters</font></h5>
<div class='param_indent'>
<dl>
<dt><code>picker</code></dt><dd><p>A picker-object requesting the image.</dd>
<dt><code>imageNumber</code></dt><dd><p>A image number locating the image in the picker.</dd>
</dl>
</div>
<h5 class="tight"><font face="Lucida Grande,Helvetica,Arial">Discussion</font>
</h5><!-- begin discussion --><p>This method should return a UIImage image for the preview at
the image number position. The image should have the width of kJPImagePickerControllerPreviewImageWidth
and height of kJPImagePickerControllerPreviewImageWidth. If it is not that size the
image picker will resize it so it fits.
<!-- end discussion -->
<p></p><hr><!-- headerDoc=intfm; uid=//apple_ref/occ/intfm/JPImagePickerControllerDataSource/imagePicker:thumbnailForImageNumber:; name=JPImagePickerControllerDataSource::imagePicker:thumbnailForImageNumber: -->
<a name="//apple_ref/occ/intfm/JPImagePickerControllerDataSource/imagePicker:thumbnailForImageNumber:"></a>
<table border="0" cellpadding="2" cellspacing="2" width="300"><tr><td valign="top" height="12" colspan="5"><h3><a name="imagePicker:thumbnailForImageNumber:">imagePicker:thumbnailForImageNumber:</a></h3>
</td></tr></table><hr><p><!-- begin abstract --><p>Asks the data source for a thumbnail to insert in a particular location
the image picker.
<!-- end abstract --></p>
<p></p><div class='declaration_indent'>
<pre>- (<!-- a logicalPath="//apple_ref/occ/cl/UIImage //apple_ref/occ/tdef/UIImage //apple_ref/occ/tag/UIImage //apple_ref/occ/econst/UIImage //apple_ref/occ/struct/UIImage //apple_ref/occ/clconst/UIImage //apple_ref/occ/intf/UIImage" --><span class="type">UIImage</span><!-- /a --> <span class="type">*</span>)<!-- a logicalPath="//apple_ref/occ/instm/imagePicker //apple_ref/occ/clm/imagePicker //apple_ref/occ/intfcm/imagePicker //apple_ref/occ/intfm/imagePicker //apple_ref/occ/func/imagePicker //apple_ref/occ/ftmplt/imagePicker //apple_ref/occ/defn/imagePicker //apple_ref/occ/macro/imagePicker" --><span class="function">imagePicker</span><!-- /a -->:(<!-- a logicalPath="//apple_ref/occ/cl/JPImagePickerController //apple_ref/occ/tdef/JPImagePickerController //apple_ref/occ/tag/JPImagePickerController //apple_ref/occ/econst/JPImagePickerController //apple_ref/occ/struct/JPImagePickerController //apple_ref/occ/clconst/JPImagePickerController //apple_ref/occ/intf/JPImagePickerController" --><span class="type">JPImagePickerController</span><!-- /a --> <span class="type">*</span>)<span class="param">picker</span>
<!-- a logicalPath="//apple_ref/occ/instm/thumbnailForImageNumber //apple_ref/occ/clm/thumbnailForImageNumber //apple_ref/occ/intfcm/thumbnailForImageNumber //apple_ref/occ/intfm/thumbnailForImageNumber //apple_ref/occ/func/thumbnailForImageNumber //apple_ref/occ/ftmplt/thumbnailForImageNumber //apple_ref/occ/defn/thumbnailForImageNumber //apple_ref/occ/macro/thumbnailForImageNumber" --><span class="function">thumbnailForImageNumber</span><!-- /a -->:(<!-- a logicalPath="//apple_ref/occ/cl/NSInteger //apple_ref/occ/tdef/NSInteger //apple_ref/occ/tag/NSInteger //apple_ref/occ/econst/NSInteger //apple_ref/occ/struct/NSInteger //apple_ref/occ/clconst/NSInteger //apple_ref/occ/intf/NSInteger" --><span class="type">NSInteger</span><!-- /a -->)<!-- a logicalPath="//apple_ref/occ/econst/imageNumber //apple_ref/occ/data/imageNumber" --><span class="var">imageNumber</span><!-- /a -->; </pre>
</div>
<h5 class="tight"><font face="Lucida Grande,Helvetica,Arial">Parameters</font></h5>
<div class='param_indent'>
<dl>
<dt><code>picker</code></dt><dd><p>A picker-object requesting the thumbnail.</dd>
<dt><code>imageNumber</code></dt><dd><p>A image number locating the image in the picker.</dd>
</dl>
</div>
<h5 class="tight"><font face="Lucida Grande,Helvetica,Arial">Discussion</font>
</h5><!-- begin discussion --><p>This method should return a UIImage thumbnail for a image at the
image number position. The image should have the width of kJPImagePickerControllerThumbnailWidth
and height of kJPImagePickerControllerThumbnailWidth. If it is not that size the
image picker will resize it so it fits.
<!-- end discussion -->
<p></p><hr><!-- headerDoc=intfm; uid=//apple_ref/occ/intfm/JPImagePickerControllerDataSource/numberOfImagesInImagePicker:; name=JPImagePickerControllerDataSource::numberOfImagesInImagePicker: -->
<a name="//apple_ref/occ/intfm/JPImagePickerControllerDataSource/numberOfImagesInImagePicker:"></a>
<table border="0" cellpadding="2" cellspacing="2" width="300"><tr><td valign="top" height="12" colspan="5"><h3><a name="numberOfImagesInImagePicker:">numberOfImagesInImagePicker:</a></h3>
</td></tr></table><hr><p><!-- begin abstract --><p>Should return the number of images.
<!-- end abstract --></p>
<p></p><div class='declaration_indent'>
<pre>- (<!-- a logicalPath="//apple_ref/occ/cl/NSInteger //apple_ref/occ/tdef/NSInteger //apple_ref/occ/tag/NSInteger //apple_ref/occ/econst/NSInteger //apple_ref/occ/struct/NSInteger //apple_ref/occ/clconst/NSInteger //apple_ref/occ/intf/NSInteger" --><span class="type">NSInteger</span><!-- /a -->)<!-- a logicalPath="//apple_ref/occ/instm/numberOfImagesInImagePicker //apple_ref/occ/clm/numberOfImagesInImagePicker //apple_ref/occ/intfcm/numberOfImagesInImagePicker //apple_ref/occ/intfm/numberOfImagesInImagePicker //apple_ref/occ/func/numberOfImagesInImagePicker //apple_ref/occ/ftmplt/numberOfImagesInImagePicker //apple_ref/occ/defn/numberOfImagesInImagePicker //apple_ref/occ/macro/numberOfImagesInImagePicker" --><span class="function">numberOfImagesInImagePicker</span><!-- /a -->:(<!-- a logicalPath="//apple_ref/occ/cl/JPImagePickerController //apple_ref/occ/tdef/JPImagePickerController //apple_ref/occ/tag/JPImagePickerController //apple_ref/occ/econst/JPImagePickerController //apple_ref/occ/struct/JPImagePickerController //apple_ref/occ/clconst/JPImagePickerController //apple_ref/occ/intf/JPImagePickerController" --><span class="type">JPImagePickerController</span><!-- /a --> <span class="type">*</span>)<!-- a logicalPath="//apple_ref/occ/econst/picker //apple_ref/occ/data/picker" --><span class="var">picker</span><!-- /a -->; </pre>
</div>
<h5 class="tight"><font face="Lucida Grande,Helvetica,Arial">Parameters</font></h5>
<div class='param_indent'>
<dl>
<dt><code>picker</code></dt><dd><p>The picker which called this method.</dd>
</dl>
</div>
<h5 class="tight"><font face="Lucida Grande,Helvetica,Arial">Discussion</font>
</h5><!-- begin discussion --><p>This method should return the number of images which the
picker should display.
<!-- end discussion -->
<p></p><p>Last Updated: Saturday, November 14, 2009
</p></body></html>

View file

@ -0,0 +1,29 @@
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"
"http://www.w3.org/TR/1998/REC-html40-19980424/loose.dtd">
<html><head>
<meta name="ROBOTS" content="NOINDEX" />
<title>Documentation for JPImagePickerControllerDataSource (JPImagePickerController.h)</title>
<meta http-equiv="Content-Type" content="text/html; charset=ascii" />
<meta name="generator" content="HeaderDoc" />
<meta name="xcode-display" content="render" />
<style type="text/css"><!--.keyword {background:#ffffff; color:#761550;}.template {background:#ffffff; color:#761550;}.number {background: #ffffff; color:#0000ff;}.function {background:#ffffff; color:#000000;}.string {background: #ffffff; color:#891315;}.preprocessor {background:#ffffff; color:#236e25}.comment {background:#ffffff; color:#236e25}.char {background: #ffffff; color:#0000ff;}.var {background:#ffffff; color:#000000;}.type {background:#ffffff; color:#761550;}.param {background:#ffffff; color:#000000;}a:link {text-decoration: none; font-family: lucida grande, geneva, helvetica, arial, sans-serif; font-size: small; color: #0000ff;}a:visited {text-decoration: none; font-family: lucida grande, geneva, helvetica, arial, sans-serif; font-size: small; color: #0000ff;}a:visited:hover {text-decoration: underline; font-family: lucida grande, geneva, helvetica, arial, sans-serif; font-size: small; color: #ff6600;}a:active {text-decoration: none; font-family: lucida grande, geneva, helvetica, arial, sans-serif; font-size: small; color: #ff6600;}a:hover {text-decoration: underline; font-family: lucida grande, geneva, helvetica, arial, sans-serif; font-size: small; color: #ff6600;}h4 {text-decoration: none; font-family: lucida grande, geneva, helvetica, arial, sans-serif; font-size: tiny; font-weight: bold;}body {text-decoration: none; font-family: lucida grande, geneva, helvetica, arial, sans-serif; font-size: 10pt;}.list_indent { margin-left: 40px; }.declaration_indent { margin-left: 40px; }.param_indent { margin-left: 40px; }.group_indent { margin-left: 40px; }.group_desc_indent { margin-left: 20px; }.warning_indent { margin-left: 40px; }.important_indent { margin-left: 40px; }.hd_tocAccess { font-style: italic; font-size: 10px; font-weight: normal; color: #303030; }--></style></head>
<body bgcolor="#edf2f6" link="#000099" vlink="#660066"
leftmargin="0" topmargin="0" marginwidth="0"
marginheight="0">
<table width="100%" cellpadding=0 cellspacing=0 border=0><tr height=51 width="100%" bgcolor="#466C9B"><td width="100%">&nbsp;</td></tr><tr><td><br><table border="0" cellpadding="0" cellspacing="2" width="148">
<tr><td width="15">&nbsp;</td><td colspan="2"><font size="5" color="#330066"><b>Protocol:</b></font></td></tr>
<tr><td width="15">&nbsp;</td><td width="15">&nbsp;</td><td><b><font size="+1">JPImagePickerControllerDataSource</font></b></td></tr>
<tr><td></td><td colspan="2">
<h4><br><nobr><a href="index.html#top" target="doc">Introduction</a></nobr></h4>
<h4><a href="index.html#HeaderDoc_methods" target="doc">Methods</a></h4>
<h5 class='hd_tocAccess'>Instance Methods</h5>
<nobr>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font size="-1">-</font><a href="index.html#//apple_ref/occ/intfm/JPImagePickerControllerDataSource/imagePicker:imageForImageNumber:" target="doc">imagePicker:&zwj;imageForImageNumber:&zwj;</a></nobr><br>
<nobr>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font size="-1">-</font><a href="index.html#//apple_ref/occ/intfm/JPImagePickerControllerDataSource/imagePicker:thumbnailForImageNumber:" target="doc">imagePicker:&zwj;thumbnailForImageNumber:&zwj;</a></nobr><br>
<nobr>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font size="-1">-</font><a href="index.html#//apple_ref/occ/intfm/JPImagePickerControllerDataSource/numberOfImagesInImagePicker:" target="doc">numberOfImagesInImagePicker:</a></nobr><br>
<br><h4>Other Reference</h4><hr>
<nobr>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="../../index.html" target="_top">Header</a></nobr><br>
</td></tr>
</table><p>&nbsp;<p>
</td></tr></table>
</body></html>

View file

@ -0,0 +1,108 @@
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"
"http://www.w3.org/TR/1998/REC-html40-19980424/loose.dtd">
<html><head>
<title>JPImagePickerControllerDelegate</title>
<meta http-equiv="Content-Type" content="text/html; charset=ascii" />
<meta name="generator" content="HeaderDoc" />
<meta name="xcode-display" content="render" />
<style><!--
#tocMenu {
display: block;
position:fixed;
top:0px;
left:0px;
width:210px;
height:100%;
background:transparent;
}
#bodyText {
margin-left: 210px;
}
--></style>
<script language="JavaScript" type="text/javascript"><!--
function hidetoc() {
var origURL = parent.document.URL;
var contentURL = origURL.substring(origURL.indexOf('?')+1, origURL.length);
if (contentURL.length == origURL.length) {
jumpPos = origURL.substring(origURL.indexOf('#')+1, origURL.length);
}
if (contentURL == "hidetoc") {
var toc = document.getElementById('tocMenu');
var body = document.getElementById('bodyText');
if (toc && body) {
toc.style.display = 'none';
body.style.marginLeft = '0px';
}
}
}
--></script>
<style type="text/css"><!--.keyword {background:#ffffff; color:#761550;}.template {background:#ffffff; color:#761550;}.number {background: #ffffff; color:#0000ff;}.function {background:#ffffff; color:#000000;}.string {background: #ffffff; color:#891315;}.preprocessor {background:#ffffff; color:#236e25}.comment {background:#ffffff; color:#236e25}.char {background: #ffffff; color:#0000ff;}.var {background:#ffffff; color:#000000;}.type {background:#ffffff; color:#761550;}.param {background:#ffffff; color:#000000;}a:link {text-decoration: none; font-family: lucida grande, geneva, helvetica, arial, sans-serif; font-size: small; color: #0000ff;}a:visited {text-decoration: none; font-family: lucida grande, geneva, helvetica, arial, sans-serif; font-size: small; color: #0000ff;}a:visited:hover {text-decoration: underline; font-family: lucida grande, geneva, helvetica, arial, sans-serif; font-size: small; color: #ff6600;}a:active {text-decoration: none; font-family: lucida grande, geneva, helvetica, arial, sans-serif; font-size: small; color: #ff6600;}a:hover {text-decoration: underline; font-family: lucida grande, geneva, helvetica, arial, sans-serif; font-size: small; color: #ff6600;}h4 {text-decoration: none; font-family: lucida grande, geneva, helvetica, arial, sans-serif; font-size: tiny; font-weight: bold;}body {text-decoration: none; font-family: lucida grande, geneva, helvetica, arial, sans-serif; font-size: 10pt;}.list_indent { margin-left: 40px; }.declaration_indent { margin-left: 40px; }.param_indent { margin-left: 40px; }.group_indent { margin-left: 40px; }.group_desc_indent { margin-left: 20px; }.warning_indent { margin-left: 40px; }.important_indent { margin-left: 40px; }.hd_tocAccess { font-style: italic; font-size: 10px; font-weight: normal; color: #303030; }--></style></head><body bgcolor="#ffffff" onload="hidetoc();">
</div>
<!-- headerDoc=intf; uid=//apple_ref/occ/intf/JPImagePickerControllerDelegate; name=JPImagePickerControllerDelegate-->
<a name="//apple_ref/occ/intf/JPImagePickerControllerDelegate"></a><div id='tocMenu'>
<iframe id='toc_content' name='toc_content' SRC='toc.html' width='210' height='100%' align='left' frameborder='0'>This document set is best viewed in a browser that supports iFrames.</iframe>
</div>
<div id='bodyText'>
<a name="top"></a>
<hr><table border="0" cellpadding="2" cellspacing="2" width="300"><tr><td valign="top" height="12" colspan="5"><h1><a name="JPImagePickerControllerDelegate">JPImagePickerControllerDelegate</a></h1>
</td></tr></table><hr><p><!-- begin abstract --><p>Delegate protocol for the JPImagePickerController
<!-- end abstract --></p>
<p><b>Extends&nbsp;Protocol:</b> <!-- a logicalPath="//apple_ref/occ/intf/NSObject" -->NSObject<!-- /a --><br>
<b>Declared In:</b> <a href="../../index.html" target="_top">JPImagePickerController.h</a><br>
</p><div class='declaration_indent'>
</div>
<h5 class="tight"><font face="Lucida Grande,Helvetica,Arial">Discussion</font>
</h5><!-- begin discussion --><p>You have to implement this delegate in order to
use the JPImagePickerController. This delegate is responsible
for dismissing the picker on cancel or finished picking.
<!-- end discussion -->
<p></p><hr><br><a name="HeaderDoc_methods"></a>
<h2>Methods</h2>
<dl>
<dt><tt><a href="index.html#//apple_ref/occ/intfm/JPImagePickerControllerDelegate/imagePicker:didFinishPickingWithImageNumber:" target="_top">-imagePicker:didFinishPickingWithImageNumber:</a></tt></dt>
<dd><p>Called when the user picked a image.
</dd>
<dt><tt><a href="index.html#//apple_ref/occ/intfm/JPImagePickerControllerDelegate/imagePickerDidCancel:" target="_top">-imagePickerDidCancel:</a></tt></dt>
<dd><p>Called when picker did cancel
</dd>
</dl>
<hr><!-- headerDoc=intfm; uid=//apple_ref/occ/intfm/JPImagePickerControllerDelegate/imagePicker:didFinishPickingWithImageNumber:; name=JPImagePickerControllerDelegate::imagePicker:didFinishPickingWithImageNumber: -->
<a name="//apple_ref/occ/intfm/JPImagePickerControllerDelegate/imagePicker:didFinishPickingWithImageNumber:"></a>
<table border="0" cellpadding="2" cellspacing="2" width="300"><tr><td valign="top" height="12" colspan="5"><h3><a name="imagePicker:didFinishPickingWithImageNumber:">imagePicker:didFinishPickingWithImageNumber:</a></h3>
</td></tr></table><hr><p><!-- begin abstract --><p>Called when the user picked a image.
<!-- end abstract --></p>
<p></p><div class='declaration_indent'>
<pre>- (<!-- a logicalPath="//apple_ref/occ/cl/void //apple_ref/occ/tdef/void //apple_ref/occ/tag/void //apple_ref/occ/econst/void //apple_ref/occ/struct/void //apple_ref/occ/clconst/void //apple_ref/occ/intf/void" --><span class="type">void</span><!-- /a -->)<!-- a logicalPath="//apple_ref/occ/instm/imagePicker //apple_ref/occ/clm/imagePicker //apple_ref/occ/intfcm/imagePicker //apple_ref/occ/intfm/imagePicker //apple_ref/occ/func/imagePicker //apple_ref/occ/ftmplt/imagePicker //apple_ref/occ/defn/imagePicker //apple_ref/occ/macro/imagePicker" --><span class="function">imagePicker</span><!-- /a -->:(<!-- a logicalPath="//apple_ref/occ/cl/JPImagePickerController //apple_ref/occ/tdef/JPImagePickerController //apple_ref/occ/tag/JPImagePickerController //apple_ref/occ/econst/JPImagePickerController //apple_ref/occ/struct/JPImagePickerController //apple_ref/occ/clconst/JPImagePickerController //apple_ref/occ/intf/JPImagePickerController" --><span class="type">JPImagePickerController</span><!-- /a --> <span class="type">*</span>)<span class="param">picker</span>
<!-- a logicalPath="//apple_ref/occ/instm/didFinishPickingWithImageNumber //apple_ref/occ/clm/didFinishPickingWithImageNumber //apple_ref/occ/intfcm/didFinishPickingWithImageNumber //apple_ref/occ/intfm/didFinishPickingWithImageNumber //apple_ref/occ/func/didFinishPickingWithImageNumber //apple_ref/occ/ftmplt/didFinishPickingWithImageNumber //apple_ref/occ/defn/didFinishPickingWithImageNumber //apple_ref/occ/macro/didFinishPickingWithImageNumber" --><span class="function">didFinishPickingWithImageNumber</span><!-- /a -->:(<!-- a logicalPath="//apple_ref/occ/cl/NSInteger //apple_ref/occ/tdef/NSInteger //apple_ref/occ/tag/NSInteger //apple_ref/occ/econst/NSInteger //apple_ref/occ/struct/NSInteger //apple_ref/occ/clconst/NSInteger //apple_ref/occ/intf/NSInteger" --><span class="type">NSInteger</span><!-- /a -->)<!-- a logicalPath="//apple_ref/occ/econst/imageNumber //apple_ref/occ/data/imageNumber" --><span class="var">imageNumber</span><!-- /a -->; </pre>
</div>
<h5 class="tight"><font face="Lucida Grande,Helvetica,Arial">Parameters</font></h5>
<div class='param_indent'>
<dl>
<dt><code>picker</code></dt><dd><p>The picker which called this method.</dd>
<dt><code>imageNumber</code></dt><dd><p>The number which image the user picked.</dd>
</dl>
</div>
<h5 class="tight"><font face="Lucida Grande,Helvetica,Arial">Discussion</font>
</h5><!-- begin discussion --><p>This method is called when the user die finish picking.
The delegate is responsible to dismiss the picker here.
<!-- end discussion -->
<p></p><hr><!-- headerDoc=intfm; uid=//apple_ref/occ/intfm/JPImagePickerControllerDelegate/imagePickerDidCancel:; name=JPImagePickerControllerDelegate::imagePickerDidCancel: -->
<a name="//apple_ref/occ/intfm/JPImagePickerControllerDelegate/imagePickerDidCancel:"></a>
<table border="0" cellpadding="2" cellspacing="2" width="300"><tr><td valign="top" height="12" colspan="5"><h3><a name="imagePickerDidCancel:">imagePickerDidCancel:</a></h3>
</td></tr></table><hr><p><!-- begin abstract --><p>Called when picker did cancel
<!-- end abstract --></p>
<p></p><div class='declaration_indent'>
<pre>- (<!-- a logicalPath="//apple_ref/occ/cl/void //apple_ref/occ/tdef/void //apple_ref/occ/tag/void //apple_ref/occ/econst/void //apple_ref/occ/struct/void //apple_ref/occ/clconst/void //apple_ref/occ/intf/void" --><span class="type">void</span><!-- /a -->)<!-- a logicalPath="//apple_ref/occ/instm/imagePickerDidCancel //apple_ref/occ/clm/imagePickerDidCancel //apple_ref/occ/intfcm/imagePickerDidCancel //apple_ref/occ/intfm/imagePickerDidCancel //apple_ref/occ/func/imagePickerDidCancel //apple_ref/occ/ftmplt/imagePickerDidCancel //apple_ref/occ/defn/imagePickerDidCancel //apple_ref/occ/macro/imagePickerDidCancel" --><span class="function">imagePickerDidCancel</span><!-- /a -->:(<!-- a logicalPath="//apple_ref/occ/cl/JPImagePickerController //apple_ref/occ/tdef/JPImagePickerController //apple_ref/occ/tag/JPImagePickerController //apple_ref/occ/econst/JPImagePickerController //apple_ref/occ/struct/JPImagePickerController //apple_ref/occ/clconst/JPImagePickerController //apple_ref/occ/intf/JPImagePickerController" --><span class="type">JPImagePickerController</span><!-- /a --> <span class="type">*</span>)<!-- a logicalPath="//apple_ref/occ/econst/picker //apple_ref/occ/data/picker" --><span class="var">picker</span><!-- /a -->; </pre>
</div>
<h5 class="tight"><font face="Lucida Grande,Helvetica,Arial">Parameters</font></h5>
<div class='param_indent'>
<dl>
<dt><code>picker</code></dt><dd><p>The picker which called this method.</dd>
</dl>
</div>
<h5 class="tight"><font face="Lucida Grande,Helvetica,Arial">Discussion</font>
</h5><!-- begin discussion --><p>This method is called when the user canceled picking.
The delegate is responsible to dismiss the picker here.
<!-- end discussion -->
<p></p><p>Last Updated: Saturday, November 14, 2009
</p></body></html>

View file

@ -0,0 +1,28 @@
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"
"http://www.w3.org/TR/1998/REC-html40-19980424/loose.dtd">
<html><head>
<meta name="ROBOTS" content="NOINDEX" />
<title>Documentation for JPImagePickerControllerDelegate (JPImagePickerController.h)</title>
<meta http-equiv="Content-Type" content="text/html; charset=ascii" />
<meta name="generator" content="HeaderDoc" />
<meta name="xcode-display" content="render" />
<style type="text/css"><!--.keyword {background:#ffffff; color:#761550;}.template {background:#ffffff; color:#761550;}.number {background: #ffffff; color:#0000ff;}.function {background:#ffffff; color:#000000;}.string {background: #ffffff; color:#891315;}.preprocessor {background:#ffffff; color:#236e25}.comment {background:#ffffff; color:#236e25}.char {background: #ffffff; color:#0000ff;}.var {background:#ffffff; color:#000000;}.type {background:#ffffff; color:#761550;}.param {background:#ffffff; color:#000000;}a:link {text-decoration: none; font-family: lucida grande, geneva, helvetica, arial, sans-serif; font-size: small; color: #0000ff;}a:visited {text-decoration: none; font-family: lucida grande, geneva, helvetica, arial, sans-serif; font-size: small; color: #0000ff;}a:visited:hover {text-decoration: underline; font-family: lucida grande, geneva, helvetica, arial, sans-serif; font-size: small; color: #ff6600;}a:active {text-decoration: none; font-family: lucida grande, geneva, helvetica, arial, sans-serif; font-size: small; color: #ff6600;}a:hover {text-decoration: underline; font-family: lucida grande, geneva, helvetica, arial, sans-serif; font-size: small; color: #ff6600;}h4 {text-decoration: none; font-family: lucida grande, geneva, helvetica, arial, sans-serif; font-size: tiny; font-weight: bold;}body {text-decoration: none; font-family: lucida grande, geneva, helvetica, arial, sans-serif; font-size: 10pt;}.list_indent { margin-left: 40px; }.declaration_indent { margin-left: 40px; }.param_indent { margin-left: 40px; }.group_indent { margin-left: 40px; }.group_desc_indent { margin-left: 20px; }.warning_indent { margin-left: 40px; }.important_indent { margin-left: 40px; }.hd_tocAccess { font-style: italic; font-size: 10px; font-weight: normal; color: #303030; }--></style></head>
<body bgcolor="#edf2f6" link="#000099" vlink="#660066"
leftmargin="0" topmargin="0" marginwidth="0"
marginheight="0">
<table width="100%" cellpadding=0 cellspacing=0 border=0><tr height=51 width="100%" bgcolor="#466C9B"><td width="100%">&nbsp;</td></tr><tr><td><br><table border="0" cellpadding="0" cellspacing="2" width="148">
<tr><td width="15">&nbsp;</td><td colspan="2"><font size="5" color="#330066"><b>Protocol:</b></font></td></tr>
<tr><td width="15">&nbsp;</td><td width="15">&nbsp;</td><td><b><font size="+1">JPImagePickerControllerDelegate</font></b></td></tr>
<tr><td></td><td colspan="2">
<h4><br><nobr><a href="index.html#top" target="doc">Introduction</a></nobr></h4>
<h4><a href="index.html#HeaderDoc_methods" target="doc">Methods</a></h4>
<h5 class='hd_tocAccess'>Instance Methods</h5>
<nobr>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font size="-1">-</font><a href="index.html#//apple_ref/occ/intfm/JPImagePickerControllerDelegate/imagePicker:didFinishPickingWithImageNumber:" target="doc">imagePicker:&zwj;didFinishPickingWithImageNumber:&zwj;</a></nobr><br>
<nobr>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<font size="-1">-</font><a href="index.html#//apple_ref/occ/intfm/JPImagePickerControllerDelegate/imagePickerDidCancel:" target="doc">imagePickerDidCancel:</a></nobr><br>
<br><h4>Other Reference</h4><hr>
<nobr>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="../../index.html" target="_top">Header</a></nobr><br>
</td></tr>
</table><p>&nbsp;<p>
</td></tr></table>
</body></html>

117
Documentation/index.html Normal file
View file

@ -0,0 +1,117 @@
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"
"http://www.w3.org/TR/1998/REC-html40-19980424/loose.dtd">
<html><head>
<title>JPImagePickerController.h</title>
<meta http-equiv="Content-Type" content="text/html; charset=ascii" />
<meta name="generator" content="HeaderDoc" />
<meta name="xcode-display" content="render" />
<style><!--
#tocMenu {
display: block;
position:fixed;
top:0px;
left:0px;
width:210px;
height:100%;
background:transparent;
}
#bodyText {
margin-left: 210px;
}
--></style>
<script language="JavaScript" type="text/javascript"><!--
function hidetoc() {
var origURL = parent.document.URL;
var contentURL = origURL.substring(origURL.indexOf('?')+1, origURL.length);
if (contentURL.length == origURL.length) {
jumpPos = origURL.substring(origURL.indexOf('#')+1, origURL.length);
}
if (contentURL == "hidetoc") {
var toc = document.getElementById('tocMenu');
var body = document.getElementById('bodyText');
if (toc && body) {
toc.style.display = 'none';
body.style.marginLeft = '0px';
}
}
}
--></script>
<style type="text/css"><!--.keyword {background:#ffffff; color:#761550;}.template {background:#ffffff; color:#761550;}.number {background: #ffffff; color:#0000ff;}.function {background:#ffffff; color:#000000;}.string {background: #ffffff; color:#891315;}.preprocessor {background:#ffffff; color:#236e25}.comment {background:#ffffff; color:#236e25}.char {background: #ffffff; color:#0000ff;}.var {background:#ffffff; color:#000000;}.type {background:#ffffff; color:#761550;}.param {background:#ffffff; color:#000000;}a:link {text-decoration: none; font-family: lucida grande, geneva, helvetica, arial, sans-serif; font-size: small; color: #0000ff;}a:visited {text-decoration: none; font-family: lucida grande, geneva, helvetica, arial, sans-serif; font-size: small; color: #0000ff;}a:visited:hover {text-decoration: underline; font-family: lucida grande, geneva, helvetica, arial, sans-serif; font-size: small; color: #ff6600;}a:active {text-decoration: none; font-family: lucida grande, geneva, helvetica, arial, sans-serif; font-size: small; color: #ff6600;}a:hover {text-decoration: underline; font-family: lucida grande, geneva, helvetica, arial, sans-serif; font-size: small; color: #ff6600;}h4 {text-decoration: none; font-family: lucida grande, geneva, helvetica, arial, sans-serif; font-size: tiny; font-weight: bold;}body {text-decoration: none; font-family: lucida grande, geneva, helvetica, arial, sans-serif; font-size: 10pt;}.list_indent { margin-left: 40px; }.declaration_indent { margin-left: 40px; }.param_indent { margin-left: 40px; }.group_indent { margin-left: 40px; }.group_desc_indent { margin-left: 20px; }.warning_indent { margin-left: 40px; }.important_indent { margin-left: 40px; }.hd_tocAccess { font-style: italic; font-size: 10px; font-weight: normal; color: #303030; }--></style></head><body bgcolor="#ffffff" onload="hidetoc();">
</div>
<!-- headerDoc=Header; uid=//apple_ref/doc/header/JPImagePickerController.h; name=JPImagePickerController.h -->
<a name="//apple_ref/doc/header/JPImagePickerController.h"></a>
<div id='tocMenu'>
<iframe id='toc_content' name='toc_content' SRC='toc.html' width='210' height='100%' align='left' frameborder='0'>This document set is best viewed in a browser that supports iFrames.</iframe>
</div>
<div id='bodyText'>
<a name="top"></a>
<hr><table border="0" cellpadding="2" cellspacing="2" width="300"><tr><td valign="top" height="12" colspan="5"><h1><a name="JPImagePickerController.h">JPImagePickerController.h</a></h1>
</td></tr></table><hr><p><!-- begin abstract -->Use the links in the table of contents to the left to access the documentation.<br>
<!-- end abstract --></p>
<p></p><div class='declaration_indent'>
</div>
<p></p><hr><br><a name="HeaderDoc_classes"></a>
<h2>Classes</h2>
<dl>
<dt><tt><a href="Classes/JPImagePickerController/index.html#//apple_ref/occ/cl/JPImagePickerController" target="_top">JPImagePickerController</a></tt></dt>
<dd><p>A image picker view controller.
</dd>
</dl>
<a name="HeaderDoc_protocols"></a>
<h2>Protocols</h2>
<dl>
<dt><tt><a href="Protocols/JPImagePickerControllerDataSource/index.html#//apple_ref/occ/intf/JPImagePickerControllerDataSource" target="_top">JPImagePickerControllerDataSource</a></tt></dt>
<dd><p>The data source protocol for JPImagePickerController
</dd>
<dt><tt><a href="Protocols/JPImagePickerControllerDelegate/index.html#//apple_ref/occ/intf/JPImagePickerControllerDelegate" target="_top">JPImagePickerControllerDelegate</a></tt></dt>
<dd><p>Delegate protocol for the JPImagePickerController
</dd>
</dl>
<hr><br><a name="HeaderDoc_enums"></a>
<h2>Enumerated Types</h2>
<dl>
<dt><tt><a href="index.html#//apple_ref/c/tag/JPImagePickerControllerPreviewImageSize" target="_top">JPImagePickerControllerPreviewImageSize</a></tt></dt>
<dd><p>Specifies the preview image width and height.
</dd>
<dt><tt><a href="index.html#//apple_ref/c/tag/JPImagePickerControllerThumbnailSize" target="_top">JPImagePickerControllerThumbnailSize</a></tt></dt>
<dd><p>Specifies the thumbnail width and height.
</dd>
</dl>
<hr><!-- headerDoc=tag; uid=//apple_ref/c/tag/JPImagePickerControllerPreviewImageSize; name=JPImagePickerControllerPreviewImageSize -->
<a name="//apple_ref/c/tag/JPImagePickerControllerPreviewImageSize"></a>
<table border="0" cellpadding="2" cellspacing="2" width="300"><tr><td valign="top" height="12" colspan="5"><h3><a name="JPImagePickerControllerPreviewImageSize">JPImagePickerControllerPreviewImageSize</a></h3>
</td></tr></table><hr><p><!-- begin abstract --><p>Specifies the preview image width and height.
<!-- end abstract --></p>
<p></p><div class='declaration_indent'>
<pre><span class="keyword">enum</span> <!-- a logicalPath="//apple_ref/c/cl/JPImagePickerControllerPreviewImageSize //apple_ref/c/tdef/JPImagePickerControllerPreviewImageSize //apple_ref/c/tag/JPImagePickerControllerPreviewImageSize //apple_ref/c/econst/JPImagePickerControllerPreviewImageSize //apple_ref/c/struct/JPImagePickerControllerPreviewImageSize //apple_ref/c/clconst/JPImagePickerControllerPreviewImageSize //apple_ref/c/intf/JPImagePickerControllerPreviewImageSize" --><span class="type">JPImagePickerControllerPreviewImageSize</span><!-- /a --> {
<!-- a logicalPath="//apple_ref/c/econst/kJPImagePickerControllerPreviewImageSizeWidth //apple_ref/c/data/kJPImagePickerControllerPreviewImageSizeWidth" --><span class="var">kJPImagePickerControllerPreviewImageSizeWidth</span><!-- /a --> = <span class="number">320</span>,
<!-- a logicalPath="//apple_ref/c/econst/kJPImagePickerControllerPreviewImageSizeHeight //apple_ref/c/data/kJPImagePickerControllerPreviewImageSizeHeight" --><span class="var">kJPImagePickerControllerPreviewImageSizeHeight</span><!-- /a --> = <span class="number">420</span>
}; </pre>
</div>
<h5 class="tight"><font face="Lucida Grande,Helvetica,Arial">Constants</font></h5>
<div class='param_indent'>
<dl>
<dt><a name="//apple_ref/c/econst/JPImagePickerControllerPreviewImageSize/kJPImagePickerControllerPreviewImageSizeWidth"><code>kJPImagePickerControllerPreviewImageSizeWidth</code></a></dt><dd><p>Preview image width 320 px.</dd>
<dt><a name="//apple_ref/c/econst/JPImagePickerControllerPreviewImageSize/kJPImagePickerControllerPreviewImageSizeHeight"><code>kJPImagePickerControllerPreviewImageSizeHeight</code></a></dt><dd><p>Preview image height 420 px.</dd>
</dl>
</div>
<p></p><hr><!-- headerDoc=tag; uid=//apple_ref/c/tag/JPImagePickerControllerThumbnailSize; name=JPImagePickerControllerThumbnailSize -->
<a name="//apple_ref/c/tag/JPImagePickerControllerThumbnailSize"></a>
<table border="0" cellpadding="2" cellspacing="2" width="300"><tr><td valign="top" height="12" colspan="5"><h3><a name="JPImagePickerControllerThumbnailSize">JPImagePickerControllerThumbnailSize</a></h3>
</td></tr></table><hr><p><!-- begin abstract --><p>Specifies the thumbnail width and height.
<!-- end abstract --></p>
<p></p><div class='declaration_indent'>
<pre><span class="keyword">enum</span> <!-- a logicalPath="//apple_ref/c/cl/JPImagePickerControllerThumbnailSize //apple_ref/c/tdef/JPImagePickerControllerThumbnailSize //apple_ref/c/tag/JPImagePickerControllerThumbnailSize //apple_ref/c/econst/JPImagePickerControllerThumbnailSize //apple_ref/c/struct/JPImagePickerControllerThumbnailSize //apple_ref/c/clconst/JPImagePickerControllerThumbnailSize //apple_ref/c/intf/JPImagePickerControllerThumbnailSize" --><span class="type">JPImagePickerControllerThumbnailSize</span><!-- /a --> {
<!-- a logicalPath="//apple_ref/c/econst/kJPImagePickerControllerThumbnailSizeWidth //apple_ref/c/data/kJPImagePickerControllerThumbnailSizeWidth" --><span class="var">kJPImagePickerControllerThumbnailSizeWidth</span><!-- /a --> = <span class="number">75</span>,
<!-- a logicalPath="//apple_ref/c/econst/kJPImagePickerControllerThumbnailSizeHeight //apple_ref/c/data/kJPImagePickerControllerThumbnailSizeHeight" --><span class="var">kJPImagePickerControllerThumbnailSizeHeight</span><!-- /a --> = <span class="number">75</span>
}; </pre>
</div>
<h5 class="tight"><font face="Lucida Grande,Helvetica,Arial">Constants</font></h5>
<div class='param_indent'>
<dl>
<dt><a name="//apple_ref/c/econst/JPImagePickerControllerThumbnailSize/kJPImagePickerControllerThumbnailSizeWidth"><code>kJPImagePickerControllerThumbnailSizeWidth</code></a></dt><dd><p>Thumbnail width 75 px.</dd>
<dt><a name="//apple_ref/c/econst/JPImagePickerControllerThumbnailSize/kJPImagePickerControllerThumbnailSizeHeight"><code>kJPImagePickerControllerThumbnailSizeHeight</code></a></dt><dd><p>Thumbnail height 75 px.</dd>
</dl>
</div>
<p></p><p>Last Updated: Saturday, November 14, 2009
</p></body></html>

32
Documentation/toc.html Normal file
View file

@ -0,0 +1,32 @@
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"
"http://www.w3.org/TR/1998/REC-html40-19980424/loose.dtd">
<html><head>
<meta name="ROBOTS" content="NOINDEX" />
<title>Documentation for JPImagePickerController.h</title>
<meta http-equiv="Content-Type" content="text/html; charset=ascii" />
<meta name="generator" content="HeaderDoc" />
<meta name="xcode-display" content="render" />
<style type="text/css"><!--.keyword {background:#ffffff; color:#761550;}.template {background:#ffffff; color:#761550;}.number {background: #ffffff; color:#0000ff;}.function {background:#ffffff; color:#000000;}.string {background: #ffffff; color:#891315;}.preprocessor {background:#ffffff; color:#236e25}.comment {background:#ffffff; color:#236e25}.char {background: #ffffff; color:#0000ff;}.var {background:#ffffff; color:#000000;}.type {background:#ffffff; color:#761550;}.param {background:#ffffff; color:#000000;}a:link {text-decoration: none; font-family: lucida grande, geneva, helvetica, arial, sans-serif; font-size: small; color: #0000ff;}a:visited {text-decoration: none; font-family: lucida grande, geneva, helvetica, arial, sans-serif; font-size: small; color: #0000ff;}a:visited:hover {text-decoration: underline; font-family: lucida grande, geneva, helvetica, arial, sans-serif; font-size: small; color: #ff6600;}a:active {text-decoration: none; font-family: lucida grande, geneva, helvetica, arial, sans-serif; font-size: small; color: #ff6600;}a:hover {text-decoration: underline; font-family: lucida grande, geneva, helvetica, arial, sans-serif; font-size: small; color: #ff6600;}h4 {text-decoration: none; font-family: lucida grande, geneva, helvetica, arial, sans-serif; font-size: tiny; font-weight: bold;}body {text-decoration: none; font-family: lucida grande, geneva, helvetica, arial, sans-serif; font-size: 10pt;}.list_indent { margin-left: 40px; }.declaration_indent { margin-left: 40px; }.param_indent { margin-left: 40px; }.group_indent { margin-left: 40px; }.group_desc_indent { margin-left: 20px; }.warning_indent { margin-left: 40px; }.important_indent { margin-left: 40px; }.hd_tocAccess { font-style: italic; font-size: 10px; font-weight: normal; color: #303030; }--></style></head>
<body bgcolor="#edf2f6" link="#000099" vlink="#660066"
leftmargin="0" topmargin="0" marginwidth="0"
marginheight="0">
<table width="100%" cellpadding=0 cellspacing=0 border=0><tr height=51 width="100%" bgcolor="#466C9B"><td width="100%">&nbsp;</td></tr><tr><td><br><table border="0" cellpadding="0" cellspacing="2" width="148">
<tr><td width="15">&nbsp;</td><td colspan="2"><font size="5" color="#330066"><b>Header:</b></font></td></tr>
<tr><td width="15">&nbsp;</td><td width="15">&nbsp;</td><td><b><font size="+1">JPImagePickerController.h</font></b></td></tr>
<tr><td></td><td colspan="2">
<h4><br><nobr><a href="index.html#top" target="doc">Introduction</a></nobr></h4>
<h4><a href="index.html#HeaderDoc_enums" target="doc">Enumerations
</a></h4>
<nobr>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="index.html#//apple_ref/c/tag/JPImagePickerControllerPreviewImageSize" target="doc">JPImagePickerControllerPreviewImageSize</a></nobr><br>
<nobr>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="index.html#//apple_ref/c/tag/JPImagePickerControllerThumbnailSize" target="doc">JPImagePickerControllerThumbnailSize</a></nobr><br>
<h4><a href="index.html#HeaderDoc_classes" target="doc">Classes</a></h4>
<nobr>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="Classes/JPImagePickerController/index.html#" target="doc">JPImagePickerController</a></nobr><br>
<h4><a href="index.html#HeaderDoc_protocols" target="doc">Protocols</a></h4>
<nobr>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="Protocols/JPImagePickerControllerDataSource/index.html#" target="doc">JPImagePickerControllerDataSource</a></nobr><br>
<nobr>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="Protocols/JPImagePickerControllerDelegate/index.html#" target="doc">JPImagePickerControllerDelegate</a></nobr><br>
</td></tr>
</table><p>&nbsp;<p>
</td></tr></table>
</body></html>