Repository: nicklockwood/iCarousel
Branch: master
Commit: c9e043e1fa76
Files: 610
Total size: 3.0 MB
Directory structure:
gitextract_q8v4ewru/
├── .gitignore
├── Examples/
│ ├── Advanced iOS Demo/
│ │ ├── en.lproj/
│ │ │ ├── InfoPlist.strings
│ │ │ ├── MainWindow.xib
│ │ │ └── iCarouselExampleViewController.xib
│ │ ├── iCarouselExample-Info.plist
│ │ ├── iCarouselExample-Prefix.pch
│ │ ├── iCarouselExample.xcodeproj/
│ │ │ └── project.pbxproj
│ │ ├── iCarouselExampleAppDelegate.h
│ │ ├── iCarouselExampleAppDelegate.m
│ │ ├── iCarouselExampleViewController.h
│ │ ├── iCarouselExampleViewController.m
│ │ └── main.m
│ ├── Basic iOS Example/
│ │ ├── en.lproj/
│ │ │ ├── InfoPlist.strings
│ │ │ ├── MainWindow.xib
│ │ │ └── iCarouselExampleViewController.xib
│ │ ├── iCarouselExample-Info.plist
│ │ ├── iCarouselExample-Prefix.pch
│ │ ├── iCarouselExample.xcodeproj/
│ │ │ └── project.pbxproj
│ │ ├── iCarouselExampleAppDelegate.h
│ │ ├── iCarouselExampleAppDelegate.m
│ │ ├── iCarouselExampleViewController.h
│ │ ├── iCarouselExampleViewController.m
│ │ └── main.m
│ ├── Buttons Demo/
│ │ ├── en.lproj/
│ │ │ ├── InfoPlist.strings
│ │ │ ├── MainWindow.xib
│ │ │ └── iCarouselExampleViewController.xib
│ │ ├── iCarouselButtonsDemo-Info.plist
│ │ ├── iCarouselButtonsDemo-Prefix.pch
│ │ ├── iCarouselButtonsDemo.xcodeproj/
│ │ │ └── project.pbxproj
│ │ ├── iCarouselExampleAppDelegate.h
│ │ ├── iCarouselExampleAppDelegate.m
│ │ ├── iCarouselExampleViewController.h
│ │ ├── iCarouselExampleViewController.m
│ │ └── main.m
│ ├── Chameleon Demo/
│ │ ├── Chameleon/
│ │ │ ├── .gitignore
│ │ │ ├── AVFoundation/
│ │ │ │ ├── AVFoundation.xcodeproj/
│ │ │ │ │ ├── project.pbxproj
│ │ │ │ │ └── project.xcworkspace/
│ │ │ │ │ └── contents.xcworkspacedata
│ │ │ │ ├── AVFoundation_Prefix.pch
│ │ │ │ ├── Classes/
│ │ │ │ │ ├── AVAudioPlayer.h
│ │ │ │ │ ├── AVAudioPlayer.m
│ │ │ │ │ ├── AVAudioSession.h
│ │ │ │ │ ├── AVAudioSession.m
│ │ │ │ │ └── AVFoundation.h
│ │ │ │ └── Info.plist
│ │ │ ├── AddressBookUI/
│ │ │ │ ├── AddressBookUI.xcodeproj/
│ │ │ │ │ ├── project.pbxproj
│ │ │ │ │ └── project.xcworkspace/
│ │ │ │ │ └── contents.xcworkspacedata
│ │ │ │ ├── AddressBookUI_Prefix.pch
│ │ │ │ ├── Classes/
│ │ │ │ │ ├── ABUnknownPersonViewController.h
│ │ │ │ │ ├── ABUnknownPersonViewController.m
│ │ │ │ │ └── AddressBookUI.h
│ │ │ │ └── Info.plist
│ │ │ ├── AssetsLibrary/
│ │ │ │ ├── AssetsLibrary.xcodeproj/
│ │ │ │ │ └── project.pbxproj
│ │ │ │ ├── AssetsLibrary_Prefix.pch
│ │ │ │ ├── Classes/
│ │ │ │ │ ├── ALAsset.h
│ │ │ │ │ ├── ALAsset.m
│ │ │ │ │ ├── ALAssetRepresentation.h
│ │ │ │ │ ├── ALAssetRepresentation.m
│ │ │ │ │ ├── ALAssetsFilter.h
│ │ │ │ │ ├── ALAssetsFilter.m
│ │ │ │ │ ├── ALAssetsGroup.h
│ │ │ │ │ ├── ALAssetsGroup.m
│ │ │ │ │ ├── ALAssetsLibrary.h
│ │ │ │ │ ├── ALAssetsLibrary.m
│ │ │ │ │ └── AssetsLibrary.h
│ │ │ │ └── Info.plist
│ │ │ ├── LICENSE
│ │ │ ├── MediaPlayer/
│ │ │ │ ├── Classes/
│ │ │ │ │ ├── MPMediaPlayback.h
│ │ │ │ │ ├── MPMoviePlayerController.h
│ │ │ │ │ ├── MPMoviePlayerController.m
│ │ │ │ │ ├── MPMusicPlayerController.h
│ │ │ │ │ ├── MPMusicPlayerController.m
│ │ │ │ │ ├── MediaPlayer.h
│ │ │ │ │ ├── UIInternalMovieView.h
│ │ │ │ │ └── UIInternalMovieView.m
│ │ │ │ ├── Info.plist
│ │ │ │ ├── MediaPlayer.xcodeproj/
│ │ │ │ │ ├── project.pbxproj
│ │ │ │ │ └── project.xcworkspace/
│ │ │ │ │ └── contents.xcworkspacedata
│ │ │ │ └── MediaPlayer_Prefix.pch
│ │ │ ├── MessageUI/
│ │ │ │ ├── Classes/
│ │ │ │ │ ├── MFMailComposeViewController.h
│ │ │ │ │ ├── MFMailComposeViewController.m
│ │ │ │ │ └── MessageUI.h
│ │ │ │ ├── Info.plist
│ │ │ │ ├── MFMessageComposeViewController.h
│ │ │ │ ├── MFMessageComposeViewController.m
│ │ │ │ ├── MessageUI.xcodeproj/
│ │ │ │ │ ├── project.pbxproj
│ │ │ │ │ └── project.xcworkspace/
│ │ │ │ │ └── contents.xcworkspacedata
│ │ │ │ └── MessageUI_Prefix.pch
│ │ │ ├── README.md
│ │ │ ├── StoreKit/
│ │ │ │ ├── Classes/
│ │ │ │ │ ├── SKPayment.h
│ │ │ │ │ ├── SKPayment.m
│ │ │ │ │ ├── SKPaymentQueue.h
│ │ │ │ │ ├── SKPaymentQueue.m
│ │ │ │ │ ├── SKPaymentTransaction.h
│ │ │ │ │ ├── SKPaymentTransaction.m
│ │ │ │ │ ├── SKProduct.h
│ │ │ │ │ ├── SKProduct.m
│ │ │ │ │ ├── SKProductsRequest.h
│ │ │ │ │ ├── SKProductsRequest.m
│ │ │ │ │ ├── SKProductsResponse.h
│ │ │ │ │ ├── SKProductsResponse.m
│ │ │ │ │ ├── SKRequest.h
│ │ │ │ │ ├── SKRequest.m
│ │ │ │ │ └── StoreKit.h
│ │ │ │ ├── Info.plist
│ │ │ │ ├── StoreKit.xcodeproj/
│ │ │ │ │ ├── project.pbxproj
│ │ │ │ │ └── project.xcworkspace/
│ │ │ │ │ └── contents.xcworkspacedata
│ │ │ │ └── StoreKit_Prefix.pch
│ │ │ └── UIKit/
│ │ │ ├── .gitignore
│ │ │ ├── Classes/
│ │ │ │ ├── AppKitIntegration.h
│ │ │ │ ├── NSIndexPath+UITableView.h
│ │ │ │ ├── NSIndexPath+UITableView.m
│ │ │ │ ├── UIAcceleration.h
│ │ │ │ ├── UIAcceleration.m
│ │ │ │ ├── UIAccelerometer.h
│ │ │ │ ├── UIAccelerometer.m
│ │ │ │ ├── UIAccessibility.h
│ │ │ │ ├── UIAccessibility.m
│ │ │ │ ├── UIAccessibilityElement.h
│ │ │ │ ├── UIAccessibilityElement.m
│ │ │ │ ├── UIAction.h
│ │ │ │ ├── UIAction.m
│ │ │ │ ├── UIActionSheet.h
│ │ │ │ ├── UIActionSheet.m
│ │ │ │ ├── UIActionSheetAppKitIntegration.h
│ │ │ │ ├── UIActivityIndicatorView.h
│ │ │ │ ├── UIActivityIndicatorView.m
│ │ │ │ ├── UIAlertView.h
│ │ │ │ ├── UIAlertView.m
│ │ │ │ ├── UIAppearance.h
│ │ │ │ ├── UIAppearanceInstance.h
│ │ │ │ ├── UIAppearanceInstance.m
│ │ │ │ ├── UIAppearanceProperty.h
│ │ │ │ ├── UIAppearanceProperty.m
│ │ │ │ ├── UIAppearanceProxy.h
│ │ │ │ ├── UIAppearanceProxy.m
│ │ │ │ ├── UIApplication+UIPrivate.h
│ │ │ │ ├── UIApplication.h
│ │ │ │ ├── UIApplication.m
│ │ │ │ ├── UIApplicationAppKitIntegration.h
│ │ │ │ ├── UIApplicationDelegate.h
│ │ │ │ ├── UIBackgroundTask.h
│ │ │ │ ├── UIBackgroundTask.m
│ │ │ │ ├── UIBarButtonItem.h
│ │ │ │ ├── UIBarButtonItem.m
│ │ │ │ ├── UIBarItem.h
│ │ │ │ ├── UIBarItem.m
│ │ │ │ ├── UIBezierPath.h
│ │ │ │ ├── UIBezierPath.m
│ │ │ │ ├── UIBulletGlyphGenerator.h
│ │ │ │ ├── UIBulletGlyphGenerator.m
│ │ │ │ ├── UIButton.h
│ │ │ │ ├── UIButton.m
│ │ │ │ ├── UIColor+UIPrivate.h
│ │ │ │ ├── UIColor.h
│ │ │ │ ├── UIColor.m
│ │ │ │ ├── UIColorAppKitIntegration.h
│ │ │ │ ├── UIColorRep.h
│ │ │ │ ├── UIColorRep.m
│ │ │ │ ├── UIControl+UIPrivate.h
│ │ │ │ ├── UIControl.h
│ │ │ │ ├── UIControl.m
│ │ │ │ ├── UIControlAction.h
│ │ │ │ ├── UIControlAction.m
│ │ │ │ ├── UICustomNSClipView.h
│ │ │ │ ├── UICustomNSClipView.m
│ │ │ │ ├── UICustomNSTextView.h
│ │ │ │ ├── UICustomNSTextView.m
│ │ │ │ ├── UIDataDetectors.h
│ │ │ │ ├── UIDatePicker.h
│ │ │ │ ├── UIDatePicker.m
│ │ │ │ ├── UIDevice.h
│ │ │ │ ├── UIDevice.m
│ │ │ │ ├── UIEvent+UIPrivate.h
│ │ │ │ ├── UIEvent.h
│ │ │ │ ├── UIEvent.m
│ │ │ │ ├── UIFont+UIPrivate.h
│ │ │ │ ├── UIFont.h
│ │ │ │ ├── UIFont.m
│ │ │ │ ├── UIFontAppKitIntegration.h
│ │ │ │ ├── UIGeometry.h
│ │ │ │ ├── UIGeometry.m
│ │ │ │ ├── UIGestureRecognizer+UIPrivate.h
│ │ │ │ ├── UIGestureRecognizer.h
│ │ │ │ ├── UIGestureRecognizer.m
│ │ │ │ ├── UIGestureRecognizerSubclass.h
│ │ │ │ ├── UIGraphics.h
│ │ │ │ ├── UIGraphics.m
│ │ │ │ ├── UIImage+UIPrivate.h
│ │ │ │ ├── UIImage+UIPrivate.m
│ │ │ │ ├── UIImage.h
│ │ │ │ ├── UIImage.m
│ │ │ │ ├── UIImageAppKitIntegration.h
│ │ │ │ ├── UIImageAppKitIntegration.m
│ │ │ │ ├── UIImagePickerController.h
│ │ │ │ ├── UIImagePickerController.m
│ │ │ │ ├── UIImageRep.h
│ │ │ │ ├── UIImageRep.m
│ │ │ │ ├── UIImageView+UIPrivate.h
│ │ │ │ ├── UIImageView.h
│ │ │ │ ├── UIImageView.m
│ │ │ │ ├── UIInputController.h
│ │ │ │ ├── UIInputController.m
│ │ │ │ ├── UIInterface.h
│ │ │ │ ├── UIInterface.m
│ │ │ │ ├── UIKey+UIPrivate.h
│ │ │ │ ├── UIKey.h
│ │ │ │ ├── UIKey.m
│ │ │ │ ├── UIKit.h
│ │ │ │ ├── UIKitView.h
│ │ │ │ ├── UIKitView.m
│ │ │ │ ├── UILabel.h
│ │ │ │ ├── UILabel.m
│ │ │ │ ├── UILongPressGestureRecognizer.h
│ │ │ │ ├── UILongPressGestureRecognizer.m
│ │ │ │ ├── UIMenuController.h
│ │ │ │ ├── UIMenuController.m
│ │ │ │ ├── UIMenuItem.h
│ │ │ │ ├── UIMenuItem.m
│ │ │ │ ├── UINSClipView.h
│ │ │ │ ├── UINSClipView.m
│ │ │ │ ├── UINavigationBar+UIPrivate.h
│ │ │ │ ├── UINavigationBar.h
│ │ │ │ ├── UINavigationBar.m
│ │ │ │ ├── UINavigationController.h
│ │ │ │ ├── UINavigationController.m
│ │ │ │ ├── UINavigationItem+UIPrivate.h
│ │ │ │ ├── UINavigationItem.h
│ │ │ │ ├── UINavigationItem.m
│ │ │ │ ├── UINibLoading.h
│ │ │ │ ├── UINibLoading.m
│ │ │ │ ├── UINinePartImage.h
│ │ │ │ ├── UINinePartImage.m
│ │ │ │ ├── UIPageControl.h
│ │ │ │ ├── UIPageControl.m
│ │ │ │ ├── UIPanGestureRecognizer.h
│ │ │ │ ├── UIPanGestureRecognizer.m
│ │ │ │ ├── UIPasteboard.h
│ │ │ │ ├── UIPasteboard.m
│ │ │ │ ├── UIPhotosAlbum.h
│ │ │ │ ├── UIPhotosAlbum.m
│ │ │ │ ├── UIPickerView.h
│ │ │ │ ├── UIPickerView.m
│ │ │ │ ├── UIPinchGestureRecognizer.h
│ │ │ │ ├── UIPinchGestureRecognizer.m
│ │ │ │ ├── UIPopoverController+UIPrivate.h
│ │ │ │ ├── UIPopoverController.h
│ │ │ │ ├── UIPopoverController.m
│ │ │ │ ├── UIPopoverNSWindow.h
│ │ │ │ ├── UIPopoverNSWindow.m
│ │ │ │ ├── UIPopoverOverlayNSView.h
│ │ │ │ ├── UIPopoverOverlayNSView.m
│ │ │ │ ├── UIPopoverView.h
│ │ │ │ ├── UIPopoverView.m
│ │ │ │ ├── UIProgressView.h
│ │ │ │ ├── UIProgressView.m
│ │ │ │ ├── UIResponder.h
│ │ │ │ ├── UIResponder.m
│ │ │ │ ├── UIResponderAppKitIntegration.h
│ │ │ │ ├── UIResponderAppKitIntegration.m
│ │ │ │ ├── UIRotationGestureRecognizer.h
│ │ │ │ ├── UIRotationGestureRecognizer.m
│ │ │ │ ├── UIRoundedRectButton.h
│ │ │ │ ├── UIRoundedRectButton.m
│ │ │ │ ├── UIScreen+UIPrivate.h
│ │ │ │ ├── UIScreen.h
│ │ │ │ ├── UIScreen.m
│ │ │ │ ├── UIScreenAppKitIntegration.h
│ │ │ │ ├── UIScreenAppKitIntegration.m
│ │ │ │ ├── UIScreenMode+UIPrivate.h
│ │ │ │ ├── UIScreenMode.h
│ │ │ │ ├── UIScreenMode.m
│ │ │ │ ├── UIScrollView+UIPrivate.h
│ │ │ │ ├── UIScrollView.h
│ │ │ │ ├── UIScrollView.m
│ │ │ │ ├── UIScrollViewAnimation.h
│ │ │ │ ├── UIScrollViewAnimation.m
│ │ │ │ ├── UIScrollViewAnimationDeceleration.h
│ │ │ │ ├── UIScrollViewAnimationDeceleration.m
│ │ │ │ ├── UIScrollViewAnimationScroll.h
│ │ │ │ ├── UIScrollViewAnimationScroll.m
│ │ │ │ ├── UIScrollWheelGestureRecognizer.h
│ │ │ │ ├── UIScrollWheelGestureRecognizer.m
│ │ │ │ ├── UIScroller.h
│ │ │ │ ├── UIScroller.m
│ │ │ │ ├── UISearchBar.h
│ │ │ │ ├── UISearchBar.m
│ │ │ │ ├── UISearchDisplayController.h
│ │ │ │ ├── UISearchDisplayController.m
│ │ │ │ ├── UISegmentedControl.h
│ │ │ │ ├── UISegmentedControl.m
│ │ │ │ ├── UISlider.h
│ │ │ │ ├── UISlider.m
│ │ │ │ ├── UISplitViewController.h
│ │ │ │ ├── UISplitViewController.m
│ │ │ │ ├── UIStringDrawing.h
│ │ │ │ ├── UIStringDrawing.m
│ │ │ │ ├── UISwipeGestureRecognizer.h
│ │ │ │ ├── UISwipeGestureRecognizer.m
│ │ │ │ ├── UISwitch.h
│ │ │ │ ├── UISwitch.m
│ │ │ │ ├── UITabBar.h
│ │ │ │ ├── UITabBar.m
│ │ │ │ ├── UITabBarController.h
│ │ │ │ ├── UITabBarController.m
│ │ │ │ ├── UITabBarItem.h
│ │ │ │ ├── UITabBarItem.m
│ │ │ │ ├── UITableView.h
│ │ │ │ ├── UITableView.m
│ │ │ │ ├── UITableViewCell+UIPrivate.h
│ │ │ │ ├── UITableViewCell.h
│ │ │ │ ├── UITableViewCell.m
│ │ │ │ ├── UITableViewCellSeparator.h
│ │ │ │ ├── UITableViewCellSeparator.m
│ │ │ │ ├── UITableViewController.h
│ │ │ │ ├── UITableViewController.m
│ │ │ │ ├── UITableViewSection.h
│ │ │ │ ├── UITableViewSection.m
│ │ │ │ ├── UITableViewSectionLabel.h
│ │ │ │ ├── UITableViewSectionLabel.m
│ │ │ │ ├── UITapGestureRecognizer.h
│ │ │ │ ├── UITapGestureRecognizer.m
│ │ │ │ ├── UITextField.h
│ │ │ │ ├── UITextField.m
│ │ │ │ ├── UITextInputTraits.h
│ │ │ │ ├── UITextLayer.h
│ │ │ │ ├── UITextLayer.m
│ │ │ │ ├── UITextView.h
│ │ │ │ ├── UITextView.m
│ │ │ │ ├── UIThreePartImage.h
│ │ │ │ ├── UIThreePartImage.m
│ │ │ │ ├── UIToolbar.h
│ │ │ │ ├── UIToolbar.m
│ │ │ │ ├── UIToolbarButton.h
│ │ │ │ ├── UIToolbarButton.m
│ │ │ │ ├── UITouch+UIPrivate.h
│ │ │ │ ├── UITouch.h
│ │ │ │ ├── UITouch.m
│ │ │ │ ├── UITransitionView.h
│ │ │ │ ├── UITransitionView.m
│ │ │ │ ├── UIView+UIPrivate.h
│ │ │ │ ├── UIView.h
│ │ │ │ ├── UIView.m
│ │ │ │ ├── UIViewAdapter.h
│ │ │ │ ├── UIViewAdapter.m
│ │ │ │ ├── UIViewAnimationGroup.h
│ │ │ │ ├── UIViewAnimationGroup.m
│ │ │ │ ├── UIViewBlockAnimationDelegate.h
│ │ │ │ ├── UIViewBlockAnimationDelegate.m
│ │ │ │ ├── UIViewController+UIPrivate.h
│ │ │ │ ├── UIViewController.h
│ │ │ │ ├── UIViewController.m
│ │ │ │ ├── UIViewLayoutManager.h
│ │ │ │ ├── UIViewLayoutManager.m
│ │ │ │ ├── UIWebView.h
│ │ │ │ ├── UIWebView.m
│ │ │ │ ├── UIWindow+UIPrivate.h
│ │ │ │ ├── UIWindow.h
│ │ │ │ └── UIWindow.m
│ │ │ ├── Info.plist
│ │ │ ├── UIKit.xcodeproj/
│ │ │ │ ├── project.pbxproj
│ │ │ │ └── project.xcworkspace/
│ │ │ │ └── contents.xcworkspacedata
│ │ │ └── UIKit_Prefix.pch
│ │ ├── iCarouselChameleonDemo/
│ │ │ ├── MacAppDelegate.h
│ │ │ ├── MacAppDelegate.m
│ │ │ ├── en.lproj/
│ │ │ │ ├── Credits.rtf
│ │ │ │ ├── InfoPlist.strings
│ │ │ │ └── MainMenu.xib
│ │ │ ├── iCarouselChameleonDemo-Info.plist
│ │ │ ├── iCarouselChameleonDemo-Prefix.pch
│ │ │ ├── iCarouselExampleAppDelegate.h
│ │ │ ├── iCarouselExampleAppDelegate.m
│ │ │ ├── iCarouselExampleViewController.h
│ │ │ ├── iCarouselExampleViewController.m
│ │ │ └── main.m
│ │ └── iCarouselChameleonDemo.xcodeproj/
│ │ ├── project.pbxproj
│ │ └── project.xcworkspace/
│ │ └── contents.xcworkspacedata
│ ├── Controls Demo/
│ │ ├── ItemView.xib
│ │ ├── en.lproj/
│ │ │ ├── InfoPlist.strings
│ │ │ ├── MainWindow.xib
│ │ │ └── iCarouselExampleViewController.xib
│ │ ├── iCarouselControlsDemo.xcodeproj/
│ │ │ ├── project.pbxproj
│ │ │ └── project.xcworkspace/
│ │ │ ├── contents.xcworkspacedata
│ │ │ └── xcshareddata/
│ │ │ └── WorkspaceSettings.xcsettings
│ │ ├── iCarouselExampleAppDelegate.h
│ │ ├── iCarouselExampleAppDelegate.m
│ │ ├── iCarouselExampleViewController.h
│ │ ├── iCarouselExampleViewController.m
│ │ ├── iCarouselTest-Info.plist
│ │ ├── iCarouselTest-Prefix.pch
│ │ └── main.m
│ ├── Downloads & Effects/
│ │ ├── Images.plist
│ │ ├── en.lproj/
│ │ │ ├── InfoPlist.strings
│ │ │ ├── MainWindow.xib
│ │ │ └── iCarouselExampleViewController.xib
│ │ ├── iCarouselExample-Info.plist
│ │ ├── iCarouselExample-Prefix.pch
│ │ ├── iCarouselExample.xcodeproj/
│ │ │ ├── project.pbxproj
│ │ │ └── project.xcworkspace/
│ │ │ └── contents.xcworkspacedata
│ │ ├── iCarouselExampleAppDelegate.h
│ │ ├── iCarouselExampleAppDelegate.m
│ │ ├── iCarouselExampleViewController.h
│ │ ├── iCarouselExampleViewController.m
│ │ └── main.m
│ ├── Dynamic Downloads/
│ │ ├── Images.plist
│ │ ├── en.lproj/
│ │ │ ├── InfoPlist.strings
│ │ │ ├── MainWindow.xib
│ │ │ └── iCarouselExampleViewController.xib
│ │ ├── iCarouselExample-Info.plist
│ │ ├── iCarouselExample-Prefix.pch
│ │ ├── iCarouselExample.xcodeproj/
│ │ │ └── project.pbxproj
│ │ ├── iCarouselExampleAppDelegate.h
│ │ ├── iCarouselExampleAppDelegate.m
│ │ ├── iCarouselExampleViewController.h
│ │ ├── iCarouselExampleViewController.m
│ │ └── main.m
│ ├── Dynamic Image Effects/
│ │ ├── iCarouselExample/
│ │ │ ├── AppDelegate.h
│ │ │ ├── AppDelegate.m
│ │ │ ├── ViewController.h
│ │ │ ├── ViewController.m
│ │ │ ├── en.lproj/
│ │ │ │ ├── InfoPlist.strings
│ │ │ │ └── ViewController.xib
│ │ │ ├── iCarouselExample-Info.plist
│ │ │ ├── iCarouselExample-Prefix.pch
│ │ │ └── main.m
│ │ └── iCarouselExample.xcodeproj/
│ │ └── project.pbxproj
│ ├── Dynamic View Reflections/
│ │ ├── en.lproj/
│ │ │ ├── InfoPlist.strings
│ │ │ ├── MainWindow.xib
│ │ │ └── iCarouselExampleViewController.xib
│ │ ├── iCarouselExampleAppDelegate.h
│ │ ├── iCarouselExampleAppDelegate.m
│ │ ├── iCarouselExampleViewController.h
│ │ ├── iCarouselExampleViewController.m
│ │ ├── iCarouselReflectionsDemo-Info.plist
│ │ ├── iCarouselReflectionsDemo-Prefix.pch
│ │ ├── iCarouselReflectionsDemo.xcodeproj/
│ │ │ └── project.pbxproj
│ │ └── main.m
│ ├── Fading Demo/
│ │ ├── en.lproj/
│ │ │ ├── InfoPlist.strings
│ │ │ ├── MainWindow.xib
│ │ │ └── iCarouselExampleViewController.xib
│ │ ├── iCarouselExample-Info.plist
│ │ ├── iCarouselExample-Prefix.pch
│ │ ├── iCarouselExample.xcodeproj/
│ │ │ └── project.pbxproj
│ │ ├── iCarouselExampleAppDelegate.h
│ │ ├── iCarouselExampleAppDelegate.m
│ │ ├── iCarouselExampleViewController.h
│ │ ├── iCarouselExampleViewController.m
│ │ └── main.m
│ ├── Libraries/
│ │ ├── AsyncImageView/
│ │ │ ├── AsyncImageView.h
│ │ │ └── AsyncImageView.m
│ │ ├── FXImageView/
│ │ │ ├── FXImageView.h
│ │ │ ├── FXImageView.m
│ │ │ ├── UIImage+FX.h
│ │ │ └── UIImage+FX.m
│ │ └── ReflectionView/
│ │ ├── ReflectionView.h
│ │ └── ReflectionView.m
│ ├── Mac Demo/
│ │ ├── iCarouselMac/
│ │ │ ├── en.lproj/
│ │ │ │ ├── Credits.rtf
│ │ │ │ ├── InfoPlist.strings
│ │ │ │ └── MainMenu.xib
│ │ │ ├── iCarouselMac-Info.plist
│ │ │ ├── iCarouselMac-Prefix.pch
│ │ │ ├── iCarouselMacAppDelegate.h
│ │ │ ├── iCarouselMacAppDelegate.m
│ │ │ ├── iCarouselWindowController.h
│ │ │ ├── iCarouselWindowController.m
│ │ │ └── main.m
│ │ └── iCarouselMac.xcodeproj/
│ │ └── project.pbxproj
│ ├── Multiple Carousels/
│ │ ├── MultipleCarousels-Info.plist
│ │ ├── MultipleCarousels-Prefix.pch
│ │ ├── MultipleCarousels.xcodeproj/
│ │ │ └── project.pbxproj
│ │ ├── en.lproj/
│ │ │ ├── InfoPlist.strings
│ │ │ ├── MainWindow.xib
│ │ │ └── iCarouselExampleViewController.xib
│ │ ├── iCarouselExampleAppDelegate.h
│ │ ├── iCarouselExampleAppDelegate.m
│ │ ├── iCarouselExampleViewController.h
│ │ ├── iCarouselExampleViewController.m
│ │ └── main.m
│ ├── Nested Carousels/
│ │ ├── en.lproj/
│ │ │ ├── InfoPlist.strings
│ │ │ ├── MainWindow.xib
│ │ │ └── iCarouselExampleViewController.xib
│ │ ├── iCarouselExample-Info.plist
│ │ ├── iCarouselExample-Prefix.pch
│ │ ├── iCarouselExample.xcodeproj/
│ │ │ └── project.pbxproj
│ │ ├── iCarouselExampleAppDelegate.h
│ │ ├── iCarouselExampleAppDelegate.m
│ │ ├── iCarouselExampleViewController.h
│ │ ├── iCarouselExampleViewController.m
│ │ └── main.m
│ ├── No Nib Demo/
│ │ ├── en.lproj/
│ │ │ └── InfoPlist.strings
│ │ ├── iCarouselExampleAppDelegate.h
│ │ ├── iCarouselExampleAppDelegate.m
│ │ ├── iCarouselExampleViewController.h
│ │ ├── iCarouselExampleViewController.m
│ │ ├── iCarouselNoNibDemo-Info.plist
│ │ ├── iCarouselNoNibDemo-Prefix.pch
│ │ ├── iCarouselNoNibDemo.xcodeproj/
│ │ │ ├── project.pbxproj
│ │ │ └── project.xcworkspace/
│ │ │ ├── contents.xcworkspacedata
│ │ │ └── xcshareddata/
│ │ │ └── WorkspaceSettings.xcsettings
│ │ └── main.m
│ ├── Offsets Demo/
│ │ ├── en.lproj/
│ │ │ ├── InfoPlist.strings
│ │ │ ├── MainWindow.xib
│ │ │ └── iCarouselExampleViewController.xib
│ │ ├── iCarouselExample-Info.plist
│ │ ├── iCarouselExample-Prefix.pch
│ │ ├── iCarouselExample.xcodeproj/
│ │ │ └── project.pbxproj
│ │ ├── iCarouselExampleAppDelegate.h
│ │ ├── iCarouselExampleAppDelegate.m
│ │ ├── iCarouselExampleViewController.h
│ │ ├── iCarouselExampleViewController.m
│ │ └── main.m
│ ├── Options Demo/
│ │ ├── en.lproj/
│ │ │ ├── InfoPlist.strings
│ │ │ ├── MainWindow.xib
│ │ │ └── iCarouselExampleViewController.xib
│ │ ├── iCarouselExample-Info.plist
│ │ ├── iCarouselExample-Prefix.pch
│ │ ├── iCarouselExampleAppDelegate.h
│ │ ├── iCarouselExampleAppDelegate.m
│ │ ├── iCarouselExampleViewController.h
│ │ ├── iCarouselExampleViewController.m
│ │ ├── iCarouselOptionsDemo.xcodeproj/
│ │ │ ├── project.pbxproj
│ │ │ └── project.xcworkspace/
│ │ │ ├── contents.xcworkspacedata
│ │ │ └── xcshareddata/
│ │ │ └── WorkspaceSettings.xcsettings
│ │ └── main.m
│ ├── Paging Example/
│ │ ├── en.lproj/
│ │ │ ├── InfoPlist.strings
│ │ │ ├── MainWindow.xib
│ │ │ └── iCarouselExampleViewController.xib
│ │ ├── iCarouselExample-Info.plist
│ │ ├── iCarouselExample-Prefix.pch
│ │ ├── iCarouselExample.xcodeproj/
│ │ │ └── project.pbxproj
│ │ ├── iCarouselExampleAppDelegate.h
│ │ ├── iCarouselExampleAppDelegate.m
│ │ ├── iCarouselExampleViewController.h
│ │ ├── iCarouselExampleViewController.m
│ │ └── main.m
│ ├── Storyboard Demo/
│ │ ├── StoryboardExample/
│ │ │ ├── AppDelegate.h
│ │ │ ├── AppDelegate.m
│ │ │ ├── StoryboardExample-Info.plist
│ │ │ ├── StoryboardExample-Prefix.pch
│ │ │ ├── ViewController.h
│ │ │ ├── ViewController.m
│ │ │ ├── en.lproj/
│ │ │ │ ├── InfoPlist.strings
│ │ │ │ └── MainStoryboard.storyboard
│ │ │ └── main.m
│ │ └── StoryboardExample.xcodeproj/
│ │ └── project.pbxproj
│ ├── Swift Example/
│ │ ├── SwiftExample/
│ │ │ ├── AppDelegate.swift
│ │ │ ├── Base.lproj/
│ │ │ │ └── Main.storyboard
│ │ │ ├── Images.xcassets/
│ │ │ │ ├── AppIcon.appiconset/
│ │ │ │ │ └── Contents.json
│ │ │ │ ├── LaunchImage.launchimage/
│ │ │ │ │ └── Contents.json
│ │ │ │ ├── background.imageset/
│ │ │ │ │ └── Contents.json
│ │ │ │ └── page.imageset/
│ │ │ │ └── Contents.json
│ │ │ ├── Info.plist
│ │ │ ├── SwiftExample-Bridging-Header.h
│ │ │ └── ViewController.swift
│ │ └── SwiftExample.xcodeproj/
│ │ └── project.pbxproj
│ ├── Swift3 Example/
│ │ ├── SwiftExample/
│ │ │ ├── AppDelegate.swift
│ │ │ ├── Base.lproj/
│ │ │ │ └── Main.storyboard
│ │ │ ├── Images.xcassets/
│ │ │ │ ├── AppIcon.appiconset/
│ │ │ │ │ └── Contents.json
│ │ │ │ ├── LaunchImage.launchimage/
│ │ │ │ │ └── Contents.json
│ │ │ │ ├── background.imageset/
│ │ │ │ │ └── Contents.json
│ │ │ │ └── page.imageset/
│ │ │ │ └── Contents.json
│ │ │ ├── Info.plist
│ │ │ ├── SwiftExample-Bridging-Header.h
│ │ │ └── ViewController.swift
│ │ └── SwiftExample.xcodeproj/
│ │ └── project.pbxproj
│ └── Tables Demo/
│ ├── en.lproj/
│ │ ├── InfoPlist.strings
│ │ ├── MainWindow.xib
│ │ └── iCarouselExampleViewController.xib
│ ├── iCarouselExampleAppDelegate.h
│ ├── iCarouselExampleAppDelegate.m
│ ├── iCarouselExampleViewController.h
│ ├── iCarouselExampleViewController.m
│ ├── iCarouselTest-Info.plist
│ ├── iCarouselTest-Prefix.pch
│ ├── iCarouselTest.xcodeproj/
│ │ └── project.pbxproj
│ └── main.m
├── LICENCE.md
├── README.md
├── Tests/
│ ├── Events/
│ │ ├── en.lproj/
│ │ │ ├── InfoPlist.strings
│ │ │ ├── MainWindow.xib
│ │ │ └── iCarouselExampleViewController.xib
│ │ ├── iCarouselExampleAppDelegate.h
│ │ ├── iCarouselExampleAppDelegate.m
│ │ ├── iCarouselExampleViewController.h
│ │ ├── iCarouselExampleViewController.m
│ │ ├── iCarouselTest-Info.plist
│ │ ├── iCarouselTest-Prefix.pch
│ │ ├── iCarouselTest.xcodeproj/
│ │ │ ├── project.pbxproj
│ │ │ └── project.xcworkspace/
│ │ │ └── contents.xcworkspacedata
│ │ └── main.m
│ └── Scrolling/
│ ├── en.lproj/
│ │ ├── InfoPlist.strings
│ │ ├── MainWindow.xib
│ │ └── iCarouselExampleViewController.xib
│ ├── iCarouselExampleAppDelegate.h
│ ├── iCarouselExampleAppDelegate.m
│ ├── iCarouselExampleViewController.h
│ ├── iCarouselExampleViewController.m
│ ├── iCarouselTest-Info.plist
│ ├── iCarouselTest-Prefix.pch
│ ├── iCarouselTest.xcodeproj/
│ │ ├── project.pbxproj
│ │ └── project.xcworkspace/
│ │ └── contents.xcworkspacedata
│ └── main.m
├── iCarousel/
│ ├── Info.plist
│ ├── iCarousel.h
│ └── iCarousel.m
├── iCarousel.podspec.json
├── iCarousel.xcodeproj/
│ ├── project.pbxproj
│ ├── project.xcworkspace/
│ │ └── contents.xcworkspacedata
│ └── xcshareddata/
│ └── xcschemes/
│ ├── iCarousel iOS.xcscheme
│ └── iCarousel macOS.xcscheme
└── iCarousel.xcworkspace/
└── contents.xcworkspacedata
================================================
FILE CONTENTS
================================================
================================================
FILE: .gitignore
================================================
# Xcode
.DS_Store
build/
*.pbxuser
!default.pbxuser
*.mode1v3
!default.mode1v3
*.mode2v3
!default.mode2v3
*.perspectivev3
!default.perspectivev3
!default.xcworkspace
xcuserdata
profile
*.moved-aside
DerivedData
.idea/
Pods
Podfile.lock
================================================
FILE: Examples/Advanced iOS Demo/en.lproj/InfoPlist.strings
================================================
/* Localized versions of Info.plist keys */
================================================
FILE: Examples/Advanced iOS Demo/en.lproj/MainWindow.xib
================================================
155212E5530841187.39626.00YESdelegate4viewController11window14rootViewController16YES0YES-1File's Owner3iCarouselExample App Delegate-21012YESYES-1.CustomClassName-1.IBPluginDependency-2.CustomClassName-2.IBPluginDependency10.CustomClassName10.IBPluginDependency12.IBPluginDependency3.CustomClassName3.IBPluginDependencyYESUIApplicationcom.apple.InterfaceBuilder.IBCocoaTouchPluginUIRespondercom.apple.InterfaceBuilder.IBCocoaTouchPluginiCarouselExampleViewControllercom.apple.InterfaceBuilder.IBCocoaTouchPlugincom.apple.InterfaceBuilder.IBCocoaTouchPluginiCarouselExampleAppDelegatecom.apple.InterfaceBuilder.IBCocoaTouchPluginYESYES16YESiCarouselUIViewYESYESdataSourcedelegateYESididYESYESdataSourcedelegateYESdataSourceiddelegateidIBProjectSource./Classes/iCarousel.hiCarouselExampleAppDelegateNSObjectYESYESviewControllerwindowYESiCarouselExampleViewControllerUIWindowYESYESviewControllerwindowYESviewControlleriCarouselExampleViewControllerwindowUIWindowIBProjectSource./Classes/iCarouselExampleAppDelegate.hiCarouselExampleViewControllerUIViewControllerYESYESinsertItemremoveItemswitchCarouselTypetoggleOrientationtoggleWrapYESidididididYESYESinsertItemremoveItemswitchCarouselTypetoggleOrientationtoggleWrapYESinsertItemidremoveItemidswitchCarouselTypeidtoggleOrientationidtoggleWrapidYESYEScarouselnavItemorientationBarItemwrapBarItemYESiCarouselUINavigationItemUIBarItemUIBarItemYESYEScarouselnavItemorientationBarItemwrapBarItemYEScarouseliCarouselnavItemUINavigationItemorientationBarItemUIBarItemwrapBarItemUIBarItemIBProjectSource./Classes/iCarouselExampleViewController.h0IBCocoaTouchFrameworkcom.apple.InterfaceBuilder.CocoaTouchPlugin.iPhoneOScom.apple.InterfaceBuilder.CocoaTouchPlugin.InterfaceBuilder3YES32083
================================================
FILE: Examples/Advanced iOS Demo/en.lproj/iCarouselExampleViewController.xib
================================================
155212E5530841187.39626.00com.apple.InterfaceBuilder.IBCocoaTouchPlugin2083YESIBProxyObjectIBUIBarButtonItemIBUIImageViewIBUINavigationBarIBUINavigationItemIBUIToolbarIBUIViewYEScom.apple.InterfaceBuilder.IBCocoaTouchPluginPluginDependencyRecalculationVersionYESIBFilesOwnerIBCocoaTouchFrameworkIBFirstResponderIBCocoaTouchFramework274YES274{320, 468}NOYESYESIBCocoaTouchFrameworkNSImagebackground.png274{{0, 44}, {320, 372}}3MSAwAA2IBCocoaTouchFramework266{{0, 416}, {320, 44}}NONOIBCocoaTouchFrameworkYESSwitch TypeIBCocoaTouchFramework1IBCocoaTouchFramework5HorizontalIBCocoaTouchFramework801Wrap: ONIBCocoaTouchFramework801290{320, 44}IBCocoaTouchFrameworkYESInsert ItemIBCocoaTouchFramework1Delete ItemIBCocoaTouchFramework1IBCocoaTouchFramework{{0, 20}, {320, 460}}3MC43NQANOIBCocoaTouchFrameworkYESview7carousel9navItem20orientationBarItem36wrapBarItem37dataSource10delegate11switchCarouselType18toggleWrap23insertItem28removeItem30toggleOrientation34YES0YES-1File's Owner-26YES8YESiCarousel15YES16YES2124YES271725222631YESYES-1.CustomClassName-1.IBPluginDependency-2.CustomClassName-2.IBPluginDependency15.IBPluginDependency16.IBPluginDependency17.IBPluginDependency21.IBPluginDependency22.IBPluginDependency24.IBPluginDependency25.IBPluginDependency26.IBPluginDependency27.IBPluginDependency31.IBPluginDependency6.IBPluginDependency8.CustomClassName8.IBPluginDependencyYESiCarouselExampleViewControllercom.apple.InterfaceBuilder.IBCocoaTouchPluginUIRespondercom.apple.InterfaceBuilder.IBCocoaTouchPlugincom.apple.InterfaceBuilder.IBCocoaTouchPlugincom.apple.InterfaceBuilder.IBCocoaTouchPlugincom.apple.InterfaceBuilder.IBCocoaTouchPlugincom.apple.InterfaceBuilder.IBCocoaTouchPlugincom.apple.InterfaceBuilder.IBCocoaTouchPlugincom.apple.InterfaceBuilder.IBCocoaTouchPlugincom.apple.InterfaceBuilder.IBCocoaTouchPlugincom.apple.InterfaceBuilder.IBCocoaTouchPlugincom.apple.InterfaceBuilder.IBCocoaTouchPlugincom.apple.InterfaceBuilder.IBCocoaTouchPlugincom.apple.InterfaceBuilder.IBCocoaTouchPluginiCarouselcom.apple.InterfaceBuilder.IBCocoaTouchPluginYESYES37YESiCarouselUIViewYESYESdataSourcedelegateYESididYESYESdataSourcedelegateYESdataSourceiddelegateidIBProjectSource./Classes/iCarousel.hiCarouselExampleViewControllerUIViewControllerYESYESinsertItemremoveItemswitchCarouselTypetoggleOrientationtoggleWrapYESidididididYESYESinsertItemremoveItemswitchCarouselTypetoggleOrientationtoggleWrapYESinsertItemidremoveItemidswitchCarouselTypeidtoggleOrientationidtoggleWrapidYESYEScarouselnavItemorientationBarItemwrapBarItemYESiCarouselUINavigationItemUIBarItemUIBarItemYESYEScarouselnavItemorientationBarItemwrapBarItemYEScarouseliCarouselnavItemUINavigationItemorientationBarItemUIBarItemwrapBarItemUIBarItemIBProjectSource./Classes/iCarouselExampleViewController.h0IBCocoaTouchFrameworkcom.apple.InterfaceBuilder.CocoaTouchPlugin.InterfaceBuilder3YES3background.png{50, 468}2083
================================================
FILE: Examples/Advanced iOS Demo/iCarouselExample-Info.plist
================================================
CFBundleDevelopmentRegionenCFBundleDisplayName${PRODUCT_NAME}CFBundleExecutable${EXECUTABLE_NAME}CFBundleIconFileCFBundleIdentifier$(PRODUCT_BUNDLE_IDENTIFIER)CFBundleInfoDictionaryVersion6.0CFBundleName${PRODUCT_NAME}CFBundlePackageTypeAPPLCFBundleShortVersionString1.0CFBundleSignature????CFBundleVersion1.0LSRequiresIPhoneOSNSMainNibFileMainWindowUIStatusBarHiddenUISupportedInterfaceOrientationsUIInterfaceOrientationPortraitUIInterfaceOrientationLandscapeLeftUIInterfaceOrientationLandscapeRightUIViewControllerBasedStatusBarAppearance
================================================
FILE: Examples/Advanced iOS Demo/iCarouselExample-Prefix.pch
================================================
//
// Prefix header for all source files of the 'iCarouselExample' target in the 'iCarouselExample' project
//
#import
#ifndef __IPHONE_3_0
#warning "This project uses features only available in iPhone SDK 3.0 and later."
#endif
#ifdef __OBJC__
#import
#import
#endif
================================================
FILE: Examples/Advanced iOS Demo/iCarouselExample.xcodeproj/project.pbxproj
================================================
// !$*UTF8*$!
{
archiveVersion = 1;
classes = {
};
objectVersion = 46;
objects = {
/* Begin PBXBuildFile section */
01308D9313491C3500453707 /* UIKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 01308D9213491C3500453707 /* UIKit.framework */; };
01308D9513491C3500453707 /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 01308D9413491C3500453707 /* Foundation.framework */; };
01308D9713491C3500453707 /* CoreGraphics.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 01308D9613491C3500453707 /* CoreGraphics.framework */; };
01308DC013491F7200453707 /* QuartzCore.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 01308DBF13491F7200453707 /* QuartzCore.framework */; };
0148358813A36C2000E687AC /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 0148358313A36C2000E687AC /* main.m */; };
0148359313A36C3700E687AC /* iCarouselExampleViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 0148358B13A36C3700E687AC /* iCarouselExampleViewController.m */; };
0148359413A36C3700E687AC /* iCarouselExampleAppDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = 0148358D13A36C3700E687AC /* iCarouselExampleAppDelegate.m */; };
0148359513A36C3700E687AC /* MainWindow.xib in Resources */ = {isa = PBXBuildFile; fileRef = 0148358F13A36C3700E687AC /* MainWindow.xib */; };
0148359613A36C3700E687AC /* iCarouselExampleViewController.xib in Resources */ = {isa = PBXBuildFile; fileRef = 0148359113A36C3700E687AC /* iCarouselExampleViewController.xib */; };
018AE98A179D7EBA00FB7311 /* Default-568h@2x.png in Resources */ = {isa = PBXBuildFile; fileRef = 018AE989179D7EBA00FB7311 /* Default-568h@2x.png */; };
B2E5E6C1146145C900EADB7A /* iCarousel.m in Sources */ = {isa = PBXBuildFile; fileRef = B2E5E6C0146145C900EADB7A /* iCarousel.m */; };
B2E5E72D1461544B00EADB7A /* background.png in Resources */ = {isa = PBXBuildFile; fileRef = B2E5E72B1461544B00EADB7A /* background.png */; };
B2E5E72E1461544B00EADB7A /* page.png in Resources */ = {isa = PBXBuildFile; fileRef = B2E5E72C1461544B00EADB7A /* page.png */; };
/* End PBXBuildFile section */
/* Begin PBXFileReference section */
01308D9213491C3500453707 /* UIKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = UIKit.framework; path = System/Library/Frameworks/UIKit.framework; sourceTree = SDKROOT; };
01308D9413491C3500453707 /* Foundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Foundation.framework; path = System/Library/Frameworks/Foundation.framework; sourceTree = SDKROOT; };
01308D9613491C3500453707 /* CoreGraphics.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreGraphics.framework; path = System/Library/Frameworks/CoreGraphics.framework; sourceTree = SDKROOT; };
01308DBF13491F7200453707 /* QuartzCore.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = QuartzCore.framework; path = System/Library/Frameworks/QuartzCore.framework; sourceTree = SDKROOT; };
0148358313A36C2000E687AC /* main.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = main.m; sourceTree = SOURCE_ROOT; };
0148358413A36C2000E687AC /* iCarouselExample-Info.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; path = "iCarouselExample-Info.plist"; sourceTree = SOURCE_ROOT; };
0148358513A36C2000E687AC /* iCarouselExample-Prefix.pch */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "iCarouselExample-Prefix.pch"; sourceTree = SOURCE_ROOT; };
0148358713A36C2000E687AC /* en */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = en; path = en.lproj/InfoPlist.strings; sourceTree = SOURCE_ROOT; };
0148358B13A36C3700E687AC /* iCarouselExampleViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = iCarouselExampleViewController.m; sourceTree = SOURCE_ROOT; };
0148358C13A36C3700E687AC /* iCarouselExampleViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = iCarouselExampleViewController.h; sourceTree = SOURCE_ROOT; };
0148358D13A36C3700E687AC /* iCarouselExampleAppDelegate.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = iCarouselExampleAppDelegate.m; sourceTree = SOURCE_ROOT; };
0148358E13A36C3700E687AC /* iCarouselExampleAppDelegate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = iCarouselExampleAppDelegate.h; sourceTree = SOURCE_ROOT; };
0148359013A36C3700E687AC /* en */ = {isa = PBXFileReference; lastKnownFileType = file.xib; name = en; path = en.lproj/MainWindow.xib; sourceTree = SOURCE_ROOT; };
0148359213A36C3700E687AC /* en */ = {isa = PBXFileReference; lastKnownFileType = file.xib; name = en; path = en.lproj/iCarouselExampleViewController.xib; sourceTree = SOURCE_ROOT; };
018AE989179D7EBA00FB7311 /* Default-568h@2x.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "Default-568h@2x.png"; sourceTree = SOURCE_ROOT; };
018BBCB413A375AF005CA505 /* iCarouselExample.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = iCarouselExample.app; sourceTree = BUILT_PRODUCTS_DIR; };
B2E5E6BF146145C900EADB7A /* iCarousel.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = iCarousel.h; sourceTree = ""; };
B2E5E6C0146145C900EADB7A /* iCarousel.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = iCarousel.m; sourceTree = ""; };
B2E5E72B1461544B00EADB7A /* background.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = background.png; path = ../Resources/background.png; sourceTree = SOURCE_ROOT; };
B2E5E72C1461544B00EADB7A /* page.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = page.png; path = ../Resources/page.png; sourceTree = SOURCE_ROOT; };
/* End PBXFileReference section */
/* Begin PBXFrameworksBuildPhase section */
01308D8B13491C3500453707 /* Frameworks */ = {
isa = PBXFrameworksBuildPhase;
buildActionMask = 2147483647;
files = (
01308DC013491F7200453707 /* QuartzCore.framework in Frameworks */,
01308D9313491C3500453707 /* UIKit.framework in Frameworks */,
01308D9513491C3500453707 /* Foundation.framework in Frameworks */,
01308D9713491C3500453707 /* CoreGraphics.framework in Frameworks */,
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXFrameworksBuildPhase section */
/* Begin PBXGroup section */
01308D8313491C3500453707 = {
isa = PBXGroup;
children = (
B2E5E6BE146145C900EADB7A /* iCarousel */,
01308D9813491C3500453707 /* iCarouselExample */,
01308D9113491C3500453707 /* Frameworks */,
01308D8F13491C3500453707 /* Products */,
);
indentWidth = 4;
sourceTree = "";
tabWidth = 4;
};
01308D8F13491C3500453707 /* Products */ = {
isa = PBXGroup;
children = (
018BBCB413A375AF005CA505 /* iCarouselExample.app */,
);
name = Products;
sourceTree = "";
};
01308D9113491C3500453707 /* Frameworks */ = {
isa = PBXGroup;
children = (
01308DBF13491F7200453707 /* QuartzCore.framework */,
01308D9213491C3500453707 /* UIKit.framework */,
01308D9413491C3500453707 /* Foundation.framework */,
01308D9613491C3500453707 /* CoreGraphics.framework */,
);
name = Frameworks;
sourceTree = "";
};
01308D9813491C3500453707 /* iCarouselExample */ = {
isa = PBXGroup;
children = (
0148358B13A36C3700E687AC /* iCarouselExampleViewController.m */,
0148358C13A36C3700E687AC /* iCarouselExampleViewController.h */,
0148358D13A36C3700E687AC /* iCarouselExampleAppDelegate.m */,
0148358E13A36C3700E687AC /* iCarouselExampleAppDelegate.h */,
0148358F13A36C3700E687AC /* MainWindow.xib */,
0148359113A36C3700E687AC /* iCarouselExampleViewController.xib */,
B2E5E72A1461543E00EADB7A /* Resources */,
01308D9913491C3500453707 /* Supporting Files */,
);
path = iCarouselExample;
sourceTree = "";
};
01308D9913491C3500453707 /* Supporting Files */ = {
isa = PBXGroup;
children = (
018AE989179D7EBA00FB7311 /* Default-568h@2x.png */,
0148358313A36C2000E687AC /* main.m */,
0148358413A36C2000E687AC /* iCarouselExample-Info.plist */,
0148358513A36C2000E687AC /* iCarouselExample-Prefix.pch */,
0148358613A36C2000E687AC /* InfoPlist.strings */,
);
name = "Supporting Files";
sourceTree = "";
};
B2E5E6BE146145C900EADB7A /* iCarousel */ = {
isa = PBXGroup;
children = (
B2E5E6BF146145C900EADB7A /* iCarousel.h */,
B2E5E6C0146145C900EADB7A /* iCarousel.m */,
);
name = iCarousel;
path = ../../iCarousel;
sourceTree = "";
};
B2E5E72A1461543E00EADB7A /* Resources */ = {
isa = PBXGroup;
children = (
B2E5E72B1461544B00EADB7A /* background.png */,
B2E5E72C1461544B00EADB7A /* page.png */,
);
name = Resources;
sourceTree = "";
};
/* End PBXGroup section */
/* Begin PBXNativeTarget section */
01308D8D13491C3500453707 /* iCarouselExample */ = {
isa = PBXNativeTarget;
buildConfigurationList = 01308DAF13491C3500453707 /* Build configuration list for PBXNativeTarget "iCarouselExample" */;
buildPhases = (
01308D8A13491C3500453707 /* Sources */,
01308D8B13491C3500453707 /* Frameworks */,
01308D8C13491C3500453707 /* Resources */,
);
buildRules = (
);
dependencies = (
);
name = iCarouselExample;
productName = iCarouselExample;
productReference = 018BBCB413A375AF005CA505 /* iCarouselExample.app */;
productType = "com.apple.product-type.application";
};
/* End PBXNativeTarget section */
/* Begin PBXProject section */
01308D8513491C3500453707 /* Project object */ = {
isa = PBXProject;
attributes = {
LastUpgradeCheck = 0800;
};
buildConfigurationList = 01308D8813491C3500453707 /* Build configuration list for PBXProject "iCarouselExample" */;
compatibilityVersion = "Xcode 3.2";
developmentRegion = English;
hasScannedForEncodings = 0;
knownRegions = (
en,
);
mainGroup = 01308D8313491C3500453707;
productRefGroup = 01308D8F13491C3500453707 /* Products */;
projectDirPath = "";
projectRoot = "";
targets = (
01308D8D13491C3500453707 /* iCarouselExample */,
);
};
/* End PBXProject section */
/* Begin PBXResourcesBuildPhase section */
01308D8C13491C3500453707 /* Resources */ = {
isa = PBXResourcesBuildPhase;
buildActionMask = 2147483647;
files = (
0148359513A36C3700E687AC /* MainWindow.xib in Resources */,
0148359613A36C3700E687AC /* iCarouselExampleViewController.xib in Resources */,
B2E5E72D1461544B00EADB7A /* background.png in Resources */,
B2E5E72E1461544B00EADB7A /* page.png in Resources */,
018AE98A179D7EBA00FB7311 /* Default-568h@2x.png in Resources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXResourcesBuildPhase section */
/* Begin PBXSourcesBuildPhase section */
01308D8A13491C3500453707 /* Sources */ = {
isa = PBXSourcesBuildPhase;
buildActionMask = 2147483647;
files = (
0148358813A36C2000E687AC /* main.m in Sources */,
0148359313A36C3700E687AC /* iCarouselExampleViewController.m in Sources */,
0148359413A36C3700E687AC /* iCarouselExampleAppDelegate.m in Sources */,
B2E5E6C1146145C900EADB7A /* iCarousel.m in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXSourcesBuildPhase section */
/* Begin PBXVariantGroup section */
0148358613A36C2000E687AC /* InfoPlist.strings */ = {
isa = PBXVariantGroup;
children = (
0148358713A36C2000E687AC /* en */,
);
name = InfoPlist.strings;
sourceTree = "";
};
0148358F13A36C3700E687AC /* MainWindow.xib */ = {
isa = PBXVariantGroup;
children = (
0148359013A36C3700E687AC /* en */,
);
name = MainWindow.xib;
sourceTree = "";
};
0148359113A36C3700E687AC /* iCarouselExampleViewController.xib */ = {
isa = PBXVariantGroup;
children = (
0148359213A36C3700E687AC /* en */,
);
name = iCarouselExampleViewController.xib;
sourceTree = "";
};
/* End PBXVariantGroup section */
/* Begin XCBuildConfiguration section */
01308DAD13491C3500453707 /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
CLANG_ANALYZER_SECURITY_FLOATLOOPCOUNTER = YES;
CLANG_ANALYZER_SECURITY_INSECUREAPI_RAND = YES;
CLANG_ANALYZER_SECURITY_INSECUREAPI_STRCPY = YES;
CLANG_WARN_CXX0X_EXTENSIONS = YES;
CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES;
CLANG_WARN_DOCUMENTATION_COMMENTS = YES;
CLANG_WARN_EMPTY_BODY = YES;
CLANG_WARN_IMPLICIT_SIGN_CONVERSION = YES;
CLANG_WARN_OBJC_EXPLICIT_OWNERSHIP_TYPE = YES;
CLANG_WARN_OBJC_IMPLICIT_ATOMIC_PROPERTIES = YES;
CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
CLANG_WARN_OBJC_MISSING_PROPERTY_SYNTHESIS = YES;
CLANG_WARN_OBJC_RECEIVER_WEAK = YES;
CLANG_WARN_OBJC_REPEATED_USE_OF_WEAK = YES;
CLANG_WARN_SUSPICIOUS_IMPLICIT_CONVERSION = YES;
CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
CLANG_WARN__EXIT_TIME_DESTRUCTORS = YES;
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
ENABLE_TESTABILITY = YES;
GCC_C_LANGUAGE_STANDARD = gnu99;
GCC_OPTIMIZATION_LEVEL = 0;
GCC_PREPROCESSOR_DEFINITIONS = DEBUG;
GCC_SHORT_ENUMS = YES;
GCC_SYMBOLS_PRIVATE_EXTERN = NO;
GCC_TREAT_IMPLICIT_FUNCTION_DECLARATIONS_AS_ERRORS = YES;
GCC_TREAT_INCOMPATIBLE_POINTER_TYPE_WARNINGS_AS_ERRORS = YES;
GCC_TREAT_WARNINGS_AS_ERRORS = NO;
GCC_VERSION = com.apple.compilers.llvmgcc42;
GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
GCC_WARN_ABOUT_MISSING_FIELD_INITIALIZERS = YES;
GCC_WARN_ABOUT_MISSING_NEWLINE = YES;
GCC_WARN_ABOUT_MISSING_PROTOTYPES = YES;
GCC_WARN_ABOUT_RETURN_TYPE = YES;
GCC_WARN_FOUR_CHARACTER_CONSTANTS = YES;
GCC_WARN_HIDDEN_VIRTUAL_FUNCTIONS = YES;
GCC_WARN_INHIBIT_ALL_WARNINGS = YES;
GCC_WARN_INITIALIZER_NOT_FULLY_BRACKETED = YES;
GCC_WARN_MULTIPLE_DEFINITION_TYPES_FOR_SELECTOR = YES;
GCC_WARN_NON_VIRTUAL_DESTRUCTOR = YES;
GCC_WARN_PEDANTIC = YES;
GCC_WARN_SHADOW = YES;
GCC_WARN_SIGN_COMPARE = YES;
GCC_WARN_STRICT_SELECTOR_MATCH = YES;
GCC_WARN_UNDECLARED_SELECTOR = YES;
GCC_WARN_UNINITIALIZED_AUTOS = YES;
GCC_WARN_UNKNOWN_PRAGMAS = YES;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_LABEL = YES;
GCC_WARN_UNUSED_PARAMETER = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 8.0;
ONLY_ACTIVE_ARCH = YES;
RUN_CLANG_STATIC_ANALYZER = YES;
SDKROOT = iphoneos;
WARNING_CFLAGS = "-Weverything";
};
name = Debug;
};
01308DAE13491C3500453707 /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
CLANG_ANALYZER_SECURITY_FLOATLOOPCOUNTER = YES;
CLANG_ANALYZER_SECURITY_INSECUREAPI_RAND = YES;
CLANG_ANALYZER_SECURITY_INSECUREAPI_STRCPY = YES;
CLANG_WARN_CXX0X_EXTENSIONS = YES;
CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES;
CLANG_WARN_DOCUMENTATION_COMMENTS = YES;
CLANG_WARN_EMPTY_BODY = YES;
CLANG_WARN_IMPLICIT_SIGN_CONVERSION = YES;
CLANG_WARN_OBJC_EXPLICIT_OWNERSHIP_TYPE = YES;
CLANG_WARN_OBJC_IMPLICIT_ATOMIC_PROPERTIES = YES;
CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
CLANG_WARN_OBJC_MISSING_PROPERTY_SYNTHESIS = YES;
CLANG_WARN_OBJC_RECEIVER_WEAK = YES;
CLANG_WARN_OBJC_REPEATED_USE_OF_WEAK = YES;
CLANG_WARN_SUSPICIOUS_IMPLICIT_CONVERSION = YES;
CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
CLANG_WARN__EXIT_TIME_DESTRUCTORS = YES;
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
GCC_C_LANGUAGE_STANDARD = gnu99;
GCC_SHORT_ENUMS = YES;
GCC_TREAT_IMPLICIT_FUNCTION_DECLARATIONS_AS_ERRORS = YES;
GCC_TREAT_INCOMPATIBLE_POINTER_TYPE_WARNINGS_AS_ERRORS = YES;
GCC_TREAT_WARNINGS_AS_ERRORS = NO;
GCC_VERSION = com.apple.compilers.llvmgcc42;
GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
GCC_WARN_ABOUT_MISSING_FIELD_INITIALIZERS = YES;
GCC_WARN_ABOUT_MISSING_NEWLINE = YES;
GCC_WARN_ABOUT_MISSING_PROTOTYPES = YES;
GCC_WARN_ABOUT_RETURN_TYPE = YES;
GCC_WARN_FOUR_CHARACTER_CONSTANTS = YES;
GCC_WARN_HIDDEN_VIRTUAL_FUNCTIONS = YES;
GCC_WARN_INHIBIT_ALL_WARNINGS = YES;
GCC_WARN_INITIALIZER_NOT_FULLY_BRACKETED = YES;
GCC_WARN_MULTIPLE_DEFINITION_TYPES_FOR_SELECTOR = YES;
GCC_WARN_NON_VIRTUAL_DESTRUCTOR = YES;
GCC_WARN_PEDANTIC = YES;
GCC_WARN_SHADOW = YES;
GCC_WARN_SIGN_COMPARE = YES;
GCC_WARN_STRICT_SELECTOR_MATCH = YES;
GCC_WARN_UNDECLARED_SELECTOR = YES;
GCC_WARN_UNINITIALIZED_AUTOS = YES;
GCC_WARN_UNKNOWN_PRAGMAS = YES;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_LABEL = YES;
GCC_WARN_UNUSED_PARAMETER = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 8.0;
OTHER_CFLAGS = "-DNS_BLOCK_ASSERTIONS=1";
RUN_CLANG_STATIC_ANALYZER = YES;
SDKROOT = iphoneos;
WARNING_CFLAGS = "-Weverything";
};
name = Release;
};
01308DB013491C3500453707 /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
CLANG_ENABLE_OBJC_ARC = YES;
COPY_PHASE_STRIP = NO;
GCC_DYNAMIC_NO_PIC = NO;
GCC_PRECOMPILE_PREFIX_HEADER = YES;
GCC_PREFIX_HEADER = "iCarouselExample-Prefix.pch";
GCC_THUMB_SUPPORT = NO;
GCC_VERSION = com.apple.compilers.llvm.clang.1_0;
GCC_WARN_INHIBIT_ALL_WARNINGS = NO;
INFOPLIST_FILE = "iCarouselExample-Info.plist";
PRODUCT_BUNDLE_IDENTIFIER = "com.charcoaldesign.${PRODUCT_NAME:rfc1034identifier}";
PRODUCT_NAME = iCarouselExample;
TARGETED_DEVICE_FAMILY = "1,2";
WRAPPER_EXTENSION = app;
};
name = Debug;
};
01308DB113491C3500453707 /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
CLANG_ENABLE_OBJC_ARC = YES;
COPY_PHASE_STRIP = YES;
GCC_PRECOMPILE_PREFIX_HEADER = YES;
GCC_PREFIX_HEADER = "iCarouselExample-Prefix.pch";
GCC_THUMB_SUPPORT = NO;
GCC_VERSION = com.apple.compilers.llvm.clang.1_0;
GCC_WARN_INHIBIT_ALL_WARNINGS = NO;
INFOPLIST_FILE = "iCarouselExample-Info.plist";
PRODUCT_BUNDLE_IDENTIFIER = "com.charcoaldesign.${PRODUCT_NAME:rfc1034identifier}";
PRODUCT_NAME = iCarouselExample;
TARGETED_DEVICE_FAMILY = "1,2";
VALIDATE_PRODUCT = YES;
WRAPPER_EXTENSION = app;
};
name = Release;
};
/* End XCBuildConfiguration section */
/* Begin XCConfigurationList section */
01308D8813491C3500453707 /* Build configuration list for PBXProject "iCarouselExample" */ = {
isa = XCConfigurationList;
buildConfigurations = (
01308DAD13491C3500453707 /* Debug */,
01308DAE13491C3500453707 /* Release */,
);
defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release;
};
01308DAF13491C3500453707 /* Build configuration list for PBXNativeTarget "iCarouselExample" */ = {
isa = XCConfigurationList;
buildConfigurations = (
01308DB013491C3500453707 /* Debug */,
01308DB113491C3500453707 /* Release */,
);
defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release;
};
/* End XCConfigurationList section */
};
rootObject = 01308D8513491C3500453707 /* Project object */;
}
================================================
FILE: Examples/Advanced iOS Demo/iCarouselExampleAppDelegate.h
================================================
//
// iCarouselExampleAppDelegate.h
// iCarouselExample
//
// Created by Nick Lockwood on 03/04/2011.
// Copyright 2011 Charcoal Design. All rights reserved.
//
#import
@class iCarouselExampleViewController;
@interface iCarouselExampleAppDelegate : NSObject
@property (nonatomic, strong) IBOutlet UIWindow *window;
@property (nonatomic, strong) IBOutlet iCarouselExampleViewController *viewController;
@end
================================================
FILE: Examples/Advanced iOS Demo/iCarouselExampleAppDelegate.m
================================================
//
// iCarouselExampleAppDelegate.m
// iCarouselExample
//
// Created by Nick Lockwood on 03/04/2011.
// Copyright 2011 Charcoal Design. All rights reserved.
//
#import "iCarouselExampleAppDelegate.h"
#import "iCarouselExampleViewController.h"
@implementation iCarouselExampleAppDelegate
@synthesize window;
@synthesize viewController;
- (BOOL)application:(__unused UIApplication *)application didFinishLaunchingWithOptions:(__unused NSDictionary *)launchOptions
{
[self.window addSubview:self.viewController.view];
[self.window makeKeyAndVisible];
return YES;
}
@end
================================================
FILE: Examples/Advanced iOS Demo/iCarouselExampleViewController.h
================================================
//
// iCarouselExampleViewController.h
// iCarouselExample
//
// Created by Nick Lockwood on 03/04/2011.
// Copyright 2011 Charcoal Design. All rights reserved.
//
#import
#import "iCarousel.h"
@interface iCarouselExampleViewController : UIViewController
@property (nonatomic, strong) IBOutlet iCarousel *carousel;
@property (nonatomic, strong) IBOutlet UINavigationItem *navItem;
@property (nonatomic, strong) IBOutlet UIBarItem *orientationBarItem;
@property (nonatomic, strong) IBOutlet UIBarItem *wrapBarItem;
- (IBAction)switchCarouselType;
- (IBAction)toggleOrientation;
- (IBAction)toggleWrap;
- (IBAction)insertItem;
- (IBAction)removeItem;
@end
================================================
FILE: Examples/Advanced iOS Demo/iCarouselExampleViewController.m
================================================
//
// iCarouselExampleViewController.m
// iCarouselExample
//
// Created by Nick Lockwood on 03/04/2011.
// Copyright 2011 Charcoal Design. All rights reserved.
//
#import "iCarouselExampleViewController.h"
#pragma clang diagnostic ignored "-Wgnu"
#pragma clang diagnostic ignored "-Wconversion"
#pragma clang diagnostic ignored "-Wdouble-promotion"
@interface iCarouselExampleViewController ()
@property (nonatomic, assign) BOOL wrap;
@property (nonatomic, strong) NSMutableArray *items;
@end
@implementation iCarouselExampleViewController
@synthesize carousel;
@synthesize navItem;
@synthesize orientationBarItem;
@synthesize wrapBarItem;
@synthesize wrap;
@synthesize items;
- (void)setUp
{
//set up data
self.wrap = YES;
self.items = [NSMutableArray array];
for (int i = 0; i < 10; i++)
{
[self.items addObject:@(i)];
}
}
- (id)initWithNibName:(NSString *)nibNameOrNil bundle:(NSBundle *)nibBundleOrNil
{
if ((self = [super initWithNibName:nibNameOrNil bundle:nibBundleOrNil]))
{
[self setUp];
}
return self;
}
- (id)initWithCoder:(NSCoder *)aDecoder
{
if ((self = [super initWithCoder:aDecoder]))
{
[self setUp];
}
return self;
}
- (void)dealloc
{
//it's a good idea to set these to nil here to avoid
//sending messages to a deallocated viewcontroller
carousel.delegate = nil;
carousel.dataSource = nil;
}
#pragma mark -
#pragma mark View lifecycle
- (void)viewDidLoad
{
[super viewDidLoad];
//configure carousel
self.carousel.type = iCarouselTypeCoverFlow2;
self.navItem.title = @"CoverFlow2";
}
- (IBAction)switchCarouselType
{
UIActionSheet *sheet = [[UIActionSheet alloc] initWithTitle:@"Select Carousel Type"
delegate:self
cancelButtonTitle:nil
destructiveButtonTitle:nil
otherButtonTitles:@"Linear", @"Rotary", @"Inverted Rotary", @"Cylinder", @"Inverted Cylinder", @"Wheel", @"Inverted Wheel", @"CoverFlow", @"CoverFlow2", @"Time Machine", @"Inverted Time Machine", @"Custom", nil];
[sheet showInView:self.view];
}
- (IBAction)toggleOrientation
{
//carousel orientation can be animated
[UIView beginAnimations:nil context:nil];
self.carousel.vertical = !self.carousel.vertical;
[UIView commitAnimations];
//update button
self.orientationBarItem.title = self.carousel.vertical? @"Vertical": @"Horizontal";
}
- (IBAction)toggleWrap
{
self.wrap = !self.wrap;
self.wrapBarItem.title = self.wrap? @"Wrap: ON": @"Wrap: OFF";
[self.carousel reloadData];
}
- (IBAction)insertItem
{
NSInteger index = MAX(0, self.carousel.currentItemIndex);
[self.items insertObject:@(self.carousel.numberOfItems) atIndex:(NSUInteger)index];
[self.carousel insertItemAtIndex:index animated:YES];
}
- (IBAction)removeItem
{
if (self.carousel.numberOfItems > 0)
{
NSInteger index = self.carousel.currentItemIndex;
[self.items removeObjectAtIndex:(NSUInteger)index];
[self.carousel removeItemAtIndex:index animated:YES];
}
}
#pragma mark -
#pragma mark UIActionSheet methods
- (void)actionSheet:(UIActionSheet *)actionSheet didDismissWithButtonIndex:(NSInteger)buttonIndex
{
if (buttonIndex >= 0)
{
//map button index to carousel type
iCarouselType type = buttonIndex;
//carousel can smoothly animate between types
[UIView beginAnimations:nil context:nil];
self.carousel.type = type;
[UIView commitAnimations];
//update title
self.navItem.title = [actionSheet buttonTitleAtIndex:buttonIndex];
}
}
#pragma mark -
#pragma mark iCarousel methods
- (NSInteger)numberOfItemsInCarousel:(__unused iCarousel *)carousel
{
return (NSInteger)[self.items count];
}
- (UIView *)carousel:(__unused iCarousel *)carousel viewForItemAtIndex:(NSInteger)index reusingView:(UIView *)view
{
UILabel *label = nil;
//create new view if no view is available for recycling
if (view == nil)
{
view = [[UIImageView alloc] initWithFrame:CGRectMake(0, 0, 200.0, 200.0)];
((UIImageView *)view).image = [UIImage imageNamed:@"page.png"];
view.contentMode = UIViewContentModeCenter;
label = [[UILabel alloc] initWithFrame:view.bounds];
label.backgroundColor = [UIColor clearColor];
label.textAlignment = NSTextAlignmentCenter;
label.font = [label.font fontWithSize:50];
label.tag = 1;
[view addSubview:label];
}
else
{
//get a reference to the label in the recycled view
label = (UILabel *)[view viewWithTag:1];
}
//set item label
//remember to always set any properties of your carousel item
//views outside of the `if (view == nil) {...}` check otherwise
//you'll get weird issues with carousel item content appearing
//in the wrong place in the carousel
label.text = [self.items[(NSUInteger)index] stringValue];
return view;
}
- (NSInteger)numberOfPlaceholdersInCarousel:(__unused iCarousel *)carousel
{
//note: placeholder views are only displayed on some carousels if wrapping is disabled
return 2;
}
- (UIView *)carousel:(__unused iCarousel *)carousel placeholderViewAtIndex:(NSInteger)index reusingView:(UIView *)view
{
UILabel *label = nil;
//create new view if no view is available for recycling
if (view == nil)
{
//don't do anything specific to the index within
//this `if (view == nil) {...}` statement because the view will be
//recycled and used with other index values later
view = [[UIImageView alloc] initWithFrame:CGRectMake(0, 0, 200.0, 200.0)];
((UIImageView *)view).image = [UIImage imageNamed:@"page.png"];
view.contentMode = UIViewContentModeCenter;
label = [[UILabel alloc] initWithFrame:view.bounds];
label.backgroundColor = [UIColor clearColor];
label.textAlignment = NSTextAlignmentCenter;
label.font = [label.font fontWithSize:50.0];
label.tag = 1;
[view addSubview:label];
}
else
{
//get a reference to the label in the recycled view
label = (UILabel *)[view viewWithTag:1];
}
//set item label
//remember to always set any properties of your carousel item
//views outside of the `if (view == nil) {...}` check otherwise
//you'll get weird issues with carousel item content appearing
//in the wrong place in the carousel
label.text = (index == 0)? @"[": @"]";
return view;
}
- (CATransform3D)carousel:(__unused iCarousel *)carousel itemTransformForOffset:(CGFloat)offset baseTransform:(CATransform3D)transform
{
//implement 'flip3D' style carousel
transform = CATransform3DRotate(transform, M_PI / 8.0, 0.0, 1.0, 0.0);
return CATransform3DTranslate(transform, 0.0, 0.0, offset * self.carousel.itemWidth);
}
- (CGFloat)carousel:(__unused iCarousel *)carousel valueForOption:(iCarouselOption)option withDefault:(CGFloat)value
{
//customize carousel display
switch (option)
{
case iCarouselOptionWrap:
{
//normally you would hard-code this to YES or NO
return self.wrap;
}
case iCarouselOptionSpacing:
{
//add a bit of spacing between the item views
return value * 1.05;
}
case iCarouselOptionFadeMax:
{
if (self.carousel.type == iCarouselTypeCustom)
{
//set opacity based on distance from camera
return 0.0;
}
return value;
}
case iCarouselOptionShowBackfaces:
case iCarouselOptionRadius:
case iCarouselOptionAngle:
case iCarouselOptionArc:
case iCarouselOptionTilt:
case iCarouselOptionCount:
case iCarouselOptionFadeMin:
case iCarouselOptionFadeMinAlpha:
case iCarouselOptionFadeRange:
case iCarouselOptionOffsetMultiplier:
case iCarouselOptionVisibleItems:
{
return value;
}
}
}
#pragma mark -
#pragma mark iCarousel taps
- (void)carousel:(__unused iCarousel *)carousel didSelectItemAtIndex:(NSInteger)index
{
NSNumber *item = (self.items)[(NSUInteger)index];
NSLog(@"Tapped view number: %@", item);
}
- (void)carouselCurrentItemIndexDidChange:(__unused iCarousel *)carousel
{
NSLog(@"Index: %@", @(self.carousel.currentItemIndex));
}
@end
================================================
FILE: Examples/Advanced iOS Demo/main.m
================================================
//
// main.m
// iCarouselExample
//
// Created by Nick Lockwood on 03/04/2011.
// Copyright 2011 Charcoal Design. All rights reserved.
//
#import
int main(int argc, char *argv[])
{
@autoreleasepool
{
int retVal = UIApplicationMain(argc, argv, nil, nil);
return retVal;
}
}
================================================
FILE: Examples/Basic iOS Example/en.lproj/InfoPlist.strings
================================================
/* Localized versions of Info.plist keys */
================================================
FILE: Examples/Basic iOS Example/en.lproj/MainWindow.xib
================================================
155212C301230841187.34625.00com.apple.InterfaceBuilder.IBCocoaTouchPlugin2083YESIBProxyObjectIBUICustomObjectIBUIViewControllerYEScom.apple.InterfaceBuilder.IBCocoaTouchPluginPluginDependencyRecalculationVersionYESIBFilesOwnerIBCocoaTouchFrameworkIBFirstResponderIBCocoaTouchFrameworkIBCocoaTouchFrameworkiCarouselExampleViewController11IBCocoaTouchFrameworkNOYESdelegate4viewController11YES0YES-1File's Owner3iCarouselExample App Delegate-210YESYES-1.CustomClassName-1.IBPluginDependency-2.CustomClassName-2.IBPluginDependency10.CustomClassName10.IBPluginDependency3.CustomClassName3.IBPluginDependencyYESUIApplicationcom.apple.InterfaceBuilder.IBCocoaTouchPluginUIRespondercom.apple.InterfaceBuilder.IBCocoaTouchPluginiCarouselExampleViewControllercom.apple.InterfaceBuilder.IBCocoaTouchPluginiCarouselExampleAppDelegatecom.apple.InterfaceBuilder.IBCocoaTouchPluginYESYES16YESiCarouselUIViewYESYESdataSourcedelegateYESididYESYESdataSourcedelegateYESdataSourceiddelegateidIBProjectSource./Classes/iCarousel.hiCarouselExampleAppDelegateNSObjectYESYESviewControllerwindowYESiCarouselExampleViewControllerUIWindowYESYESviewControllerwindowYESviewControlleriCarouselExampleViewControllerwindowUIWindowIBProjectSource./Classes/iCarouselExampleAppDelegate.hiCarouselExampleViewControllerUIViewControllercarouseliCarouselcarouselcarouseliCarouselIBProjectSource./Classes/iCarouselExampleViewController.h0IBCocoaTouchFrameworkcom.apple.InterfaceBuilder.CocoaTouchPlugin.iPhoneOScom.apple.InterfaceBuilder.CocoaTouchPlugin.InterfaceBuilder3YES32083
================================================
FILE: Examples/Basic iOS Example/en.lproj/iCarouselExampleViewController.xib
================================================
155212E5530841187.39626.00com.apple.InterfaceBuilder.IBCocoaTouchPlugin2083YESIBProxyObjectIBUIImageViewIBUIViewYEScom.apple.InterfaceBuilder.IBCocoaTouchPluginPluginDependencyRecalculationVersionYESIBFilesOwnerIBCocoaTouchFrameworkIBFirstResponderIBCocoaTouchFramework274YES274{320, 468}NOYESYESIBCocoaTouchFrameworkNSImagebackground.png274{320, 460}3MSAwAA2IBCocoaTouchFramework{{0, 20}, {320, 460}}3MC43NQANOIBCocoaTouchFrameworkYESview7carousel9dataSource10delegate11YES0YES-1File's Owner-26YES8YESiCarousel21YESYES-1.CustomClassName-1.IBPluginDependency-2.CustomClassName-2.IBPluginDependency21.IBPluginDependency6.IBPluginDependency8.CustomClassName8.IBPluginDependencyYESiCarouselExampleViewControllercom.apple.InterfaceBuilder.IBCocoaTouchPluginUIRespondercom.apple.InterfaceBuilder.IBCocoaTouchPlugincom.apple.InterfaceBuilder.IBCocoaTouchPlugincom.apple.InterfaceBuilder.IBCocoaTouchPluginiCarouselcom.apple.InterfaceBuilder.IBCocoaTouchPluginYESYES370IBCocoaTouchFrameworkcom.apple.InterfaceBuilder.CocoaTouchPlugin.InterfaceBuilder3YES3background.png{50, 468}2083
================================================
FILE: Examples/Basic iOS Example/iCarouselExample-Info.plist
================================================
CFBundleDevelopmentRegionenCFBundleDisplayName${PRODUCT_NAME}CFBundleExecutable${EXECUTABLE_NAME}CFBundleIconFileCFBundleIdentifier$(PRODUCT_BUNDLE_IDENTIFIER)CFBundleInfoDictionaryVersion6.0CFBundleName${PRODUCT_NAME}CFBundlePackageTypeAPPLCFBundleShortVersionString1.0CFBundleSignature????CFBundleVersion1.0LSRequiresIPhoneOSNSMainNibFileMainWindowUIStatusBarHiddenUISupportedInterfaceOrientationsUIInterfaceOrientationPortraitUpsideDownUIInterfaceOrientationPortraitUIInterfaceOrientationLandscapeLeftUIInterfaceOrientationLandscapeRight
================================================
FILE: Examples/Basic iOS Example/iCarouselExample-Prefix.pch
================================================
//
// Prefix header for all source files of the 'iCarouselExample' target in the 'iCarouselExample' project
//
#import
#ifndef __IPHONE_3_0
#warning "This project uses features only available in iPhone SDK 3.0 and later."
#endif
#ifdef __OBJC__
#import
#import
#endif
================================================
FILE: Examples/Basic iOS Example/iCarouselExample.xcodeproj/project.pbxproj
================================================
// !$*UTF8*$!
{
archiveVersion = 1;
classes = {
};
objectVersion = 46;
objects = {
/* Begin PBXBuildFile section */
01308D9313491C3500453707 /* UIKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 01308D9213491C3500453707 /* UIKit.framework */; };
01308D9513491C3500453707 /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 01308D9413491C3500453707 /* Foundation.framework */; };
01308D9713491C3500453707 /* CoreGraphics.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 01308D9613491C3500453707 /* CoreGraphics.framework */; };
01308DC013491F7200453707 /* QuartzCore.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 01308DBF13491F7200453707 /* QuartzCore.framework */; };
013F5C60168A59F500355CAD /* Default-568h@2x.png in Resources */ = {isa = PBXBuildFile; fileRef = 013F5C5F168A59F500355CAD /* Default-568h@2x.png */; };
0148358813A36C2000E687AC /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 0148358313A36C2000E687AC /* main.m */; };
0148359313A36C3700E687AC /* iCarouselExampleViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 0148358B13A36C3700E687AC /* iCarouselExampleViewController.m */; };
0148359413A36C3700E687AC /* iCarouselExampleAppDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = 0148358D13A36C3700E687AC /* iCarouselExampleAppDelegate.m */; };
0148359513A36C3700E687AC /* MainWindow.xib in Resources */ = {isa = PBXBuildFile; fileRef = 0148358F13A36C3700E687AC /* MainWindow.xib */; };
0148359613A36C3700E687AC /* iCarouselExampleViewController.xib in Resources */ = {isa = PBXBuildFile; fileRef = 0148359113A36C3700E687AC /* iCarouselExampleViewController.xib */; };
B2E5E6C1146145C900EADB7A /* iCarousel.m in Sources */ = {isa = PBXBuildFile; fileRef = B2E5E6C0146145C900EADB7A /* iCarousel.m */; };
B2E5E72D1461544B00EADB7A /* background.png in Resources */ = {isa = PBXBuildFile; fileRef = B2E5E72B1461544B00EADB7A /* background.png */; };
B2E5E72E1461544B00EADB7A /* page.png in Resources */ = {isa = PBXBuildFile; fileRef = B2E5E72C1461544B00EADB7A /* page.png */; };
/* End PBXBuildFile section */
/* Begin PBXFileReference section */
01308D9213491C3500453707 /* UIKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = UIKit.framework; path = System/Library/Frameworks/UIKit.framework; sourceTree = SDKROOT; };
01308D9413491C3500453707 /* Foundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Foundation.framework; path = System/Library/Frameworks/Foundation.framework; sourceTree = SDKROOT; };
01308D9613491C3500453707 /* CoreGraphics.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreGraphics.framework; path = System/Library/Frameworks/CoreGraphics.framework; sourceTree = SDKROOT; };
01308DBF13491F7200453707 /* QuartzCore.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = QuartzCore.framework; path = System/Library/Frameworks/QuartzCore.framework; sourceTree = SDKROOT; };
013F5C5F168A59F500355CAD /* Default-568h@2x.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "Default-568h@2x.png"; sourceTree = SOURCE_ROOT; };
0148358313A36C2000E687AC /* main.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = main.m; sourceTree = SOURCE_ROOT; };
0148358413A36C2000E687AC /* iCarouselExample-Info.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; path = "iCarouselExample-Info.plist"; sourceTree = SOURCE_ROOT; };
0148358513A36C2000E687AC /* iCarouselExample-Prefix.pch */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "iCarouselExample-Prefix.pch"; sourceTree = SOURCE_ROOT; };
0148358713A36C2000E687AC /* en */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = en; path = en.lproj/InfoPlist.strings; sourceTree = SOURCE_ROOT; };
0148358B13A36C3700E687AC /* iCarouselExampleViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = iCarouselExampleViewController.m; sourceTree = SOURCE_ROOT; };
0148358C13A36C3700E687AC /* iCarouselExampleViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = iCarouselExampleViewController.h; sourceTree = SOURCE_ROOT; };
0148358D13A36C3700E687AC /* iCarouselExampleAppDelegate.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = iCarouselExampleAppDelegate.m; sourceTree = SOURCE_ROOT; };
0148358E13A36C3700E687AC /* iCarouselExampleAppDelegate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = iCarouselExampleAppDelegate.h; sourceTree = SOURCE_ROOT; };
0148359013A36C3700E687AC /* en */ = {isa = PBXFileReference; lastKnownFileType = file.xib; name = en; path = en.lproj/MainWindow.xib; sourceTree = SOURCE_ROOT; };
0148359213A36C3700E687AC /* en */ = {isa = PBXFileReference; lastKnownFileType = file.xib; name = en; path = en.lproj/iCarouselExampleViewController.xib; sourceTree = SOURCE_ROOT; };
018BBCB413A375AF005CA505 /* iCarouselExample.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = iCarouselExample.app; sourceTree = BUILT_PRODUCTS_DIR; };
B2E5E6BF146145C900EADB7A /* iCarousel.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = iCarousel.h; sourceTree = ""; };
B2E5E6C0146145C900EADB7A /* iCarousel.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = iCarousel.m; sourceTree = ""; };
B2E5E72B1461544B00EADB7A /* background.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = background.png; path = ../Resources/background.png; sourceTree = SOURCE_ROOT; };
B2E5E72C1461544B00EADB7A /* page.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = page.png; path = ../Resources/page.png; sourceTree = SOURCE_ROOT; };
/* End PBXFileReference section */
/* Begin PBXFrameworksBuildPhase section */
01308D8B13491C3500453707 /* Frameworks */ = {
isa = PBXFrameworksBuildPhase;
buildActionMask = 2147483647;
files = (
01308DC013491F7200453707 /* QuartzCore.framework in Frameworks */,
01308D9313491C3500453707 /* UIKit.framework in Frameworks */,
01308D9513491C3500453707 /* Foundation.framework in Frameworks */,
01308D9713491C3500453707 /* CoreGraphics.framework in Frameworks */,
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXFrameworksBuildPhase section */
/* Begin PBXGroup section */
01308D8313491C3500453707 = {
isa = PBXGroup;
children = (
B2E5E6BE146145C900EADB7A /* iCarousel */,
01308D9813491C3500453707 /* iCarouselExample */,
01308D9113491C3500453707 /* Frameworks */,
01308D8F13491C3500453707 /* Products */,
);
sourceTree = "";
};
01308D8F13491C3500453707 /* Products */ = {
isa = PBXGroup;
children = (
018BBCB413A375AF005CA505 /* iCarouselExample.app */,
);
name = Products;
sourceTree = "";
};
01308D9113491C3500453707 /* Frameworks */ = {
isa = PBXGroup;
children = (
01308DBF13491F7200453707 /* QuartzCore.framework */,
01308D9213491C3500453707 /* UIKit.framework */,
01308D9413491C3500453707 /* Foundation.framework */,
01308D9613491C3500453707 /* CoreGraphics.framework */,
);
name = Frameworks;
sourceTree = "";
};
01308D9813491C3500453707 /* iCarouselExample */ = {
isa = PBXGroup;
children = (
0148358B13A36C3700E687AC /* iCarouselExampleViewController.m */,
0148358C13A36C3700E687AC /* iCarouselExampleViewController.h */,
0148358D13A36C3700E687AC /* iCarouselExampleAppDelegate.m */,
0148358E13A36C3700E687AC /* iCarouselExampleAppDelegate.h */,
0148358F13A36C3700E687AC /* MainWindow.xib */,
0148359113A36C3700E687AC /* iCarouselExampleViewController.xib */,
B2E5E72A1461543E00EADB7A /* Resources */,
01308D9913491C3500453707 /* Supporting Files */,
);
path = iCarouselExample;
sourceTree = "";
};
01308D9913491C3500453707 /* Supporting Files */ = {
isa = PBXGroup;
children = (
013F5C5F168A59F500355CAD /* Default-568h@2x.png */,
0148358313A36C2000E687AC /* main.m */,
0148358413A36C2000E687AC /* iCarouselExample-Info.plist */,
0148358513A36C2000E687AC /* iCarouselExample-Prefix.pch */,
0148358613A36C2000E687AC /* InfoPlist.strings */,
);
name = "Supporting Files";
sourceTree = "";
};
B2E5E6BE146145C900EADB7A /* iCarousel */ = {
isa = PBXGroup;
children = (
B2E5E6BF146145C900EADB7A /* iCarousel.h */,
B2E5E6C0146145C900EADB7A /* iCarousel.m */,
);
name = iCarousel;
path = ../../iCarousel;
sourceTree = "";
};
B2E5E72A1461543E00EADB7A /* Resources */ = {
isa = PBXGroup;
children = (
B2E5E72B1461544B00EADB7A /* background.png */,
B2E5E72C1461544B00EADB7A /* page.png */,
);
name = Resources;
sourceTree = "";
};
/* End PBXGroup section */
/* Begin PBXNativeTarget section */
01308D8D13491C3500453707 /* iCarouselExample */ = {
isa = PBXNativeTarget;
buildConfigurationList = 01308DAF13491C3500453707 /* Build configuration list for PBXNativeTarget "iCarouselExample" */;
buildPhases = (
01308D8A13491C3500453707 /* Sources */,
01308D8B13491C3500453707 /* Frameworks */,
01308D8C13491C3500453707 /* Resources */,
);
buildRules = (
);
dependencies = (
);
name = iCarouselExample;
productName = iCarouselExample;
productReference = 018BBCB413A375AF005CA505 /* iCarouselExample.app */;
productType = "com.apple.product-type.application";
};
/* End PBXNativeTarget section */
/* Begin PBXProject section */
01308D8513491C3500453707 /* Project object */ = {
isa = PBXProject;
attributes = {
LastUpgradeCheck = 0800;
};
buildConfigurationList = 01308D8813491C3500453707 /* Build configuration list for PBXProject "iCarouselExample" */;
compatibilityVersion = "Xcode 3.2";
developmentRegion = English;
hasScannedForEncodings = 0;
knownRegions = (
en,
);
mainGroup = 01308D8313491C3500453707;
productRefGroup = 01308D8F13491C3500453707 /* Products */;
projectDirPath = "";
projectRoot = "";
targets = (
01308D8D13491C3500453707 /* iCarouselExample */,
);
};
/* End PBXProject section */
/* Begin PBXResourcesBuildPhase section */
01308D8C13491C3500453707 /* Resources */ = {
isa = PBXResourcesBuildPhase;
buildActionMask = 2147483647;
files = (
0148359513A36C3700E687AC /* MainWindow.xib in Resources */,
0148359613A36C3700E687AC /* iCarouselExampleViewController.xib in Resources */,
B2E5E72D1461544B00EADB7A /* background.png in Resources */,
B2E5E72E1461544B00EADB7A /* page.png in Resources */,
013F5C60168A59F500355CAD /* Default-568h@2x.png in Resources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXResourcesBuildPhase section */
/* Begin PBXSourcesBuildPhase section */
01308D8A13491C3500453707 /* Sources */ = {
isa = PBXSourcesBuildPhase;
buildActionMask = 2147483647;
files = (
0148358813A36C2000E687AC /* main.m in Sources */,
0148359313A36C3700E687AC /* iCarouselExampleViewController.m in Sources */,
0148359413A36C3700E687AC /* iCarouselExampleAppDelegate.m in Sources */,
B2E5E6C1146145C900EADB7A /* iCarousel.m in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXSourcesBuildPhase section */
/* Begin PBXVariantGroup section */
0148358613A36C2000E687AC /* InfoPlist.strings */ = {
isa = PBXVariantGroup;
children = (
0148358713A36C2000E687AC /* en */,
);
name = InfoPlist.strings;
sourceTree = "";
};
0148358F13A36C3700E687AC /* MainWindow.xib */ = {
isa = PBXVariantGroup;
children = (
0148359013A36C3700E687AC /* en */,
);
name = MainWindow.xib;
sourceTree = "";
};
0148359113A36C3700E687AC /* iCarouselExampleViewController.xib */ = {
isa = PBXVariantGroup;
children = (
0148359213A36C3700E687AC /* en */,
);
name = iCarouselExampleViewController.xib;
sourceTree = "";
};
/* End PBXVariantGroup section */
/* Begin XCBuildConfiguration section */
01308DAD13491C3500453707 /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
ENABLE_TESTABILITY = YES;
GCC_C_LANGUAGE_STANDARD = gnu99;
GCC_OPTIMIZATION_LEVEL = 0;
GCC_PREPROCESSOR_DEFINITIONS = DEBUG;
GCC_SYMBOLS_PRIVATE_EXTERN = NO;
GCC_TREAT_WARNINGS_AS_ERRORS = YES;
GCC_VERSION = com.apple.compilers.llvmgcc42;
GCC_WARN_ABOUT_RETURN_TYPE = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 8.0;
ONLY_ACTIVE_ARCH = YES;
RUN_CLANG_STATIC_ANALYZER = YES;
SDKROOT = iphoneos;
};
name = Debug;
};
01308DAE13491C3500453707 /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
GCC_C_LANGUAGE_STANDARD = gnu99;
GCC_TREAT_WARNINGS_AS_ERRORS = YES;
GCC_VERSION = com.apple.compilers.llvmgcc42;
GCC_WARN_ABOUT_RETURN_TYPE = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 8.0;
OTHER_CFLAGS = "-DNS_BLOCK_ASSERTIONS=1";
RUN_CLANG_STATIC_ANALYZER = YES;
SDKROOT = iphoneos;
};
name = Release;
};
01308DB013491C3500453707 /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
CLANG_ENABLE_OBJC_ARC = YES;
COPY_PHASE_STRIP = NO;
GCC_DYNAMIC_NO_PIC = NO;
GCC_PRECOMPILE_PREFIX_HEADER = YES;
GCC_PREFIX_HEADER = "iCarouselExample-Prefix.pch";
GCC_THUMB_SUPPORT = NO;
GCC_VERSION = "";
INFOPLIST_FILE = "iCarouselExample-Info.plist";
PRODUCT_BUNDLE_IDENTIFIER = "com.charcoaldesign.${PRODUCT_NAME:rfc1034identifier}";
PRODUCT_NAME = iCarouselExample;
TARGETED_DEVICE_FAMILY = "1,2";
WRAPPER_EXTENSION = app;
};
name = Debug;
};
01308DB113491C3500453707 /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
CLANG_ENABLE_OBJC_ARC = YES;
COPY_PHASE_STRIP = YES;
GCC_PRECOMPILE_PREFIX_HEADER = YES;
GCC_PREFIX_HEADER = "iCarouselExample-Prefix.pch";
GCC_THUMB_SUPPORT = NO;
GCC_VERSION = "";
INFOPLIST_FILE = "iCarouselExample-Info.plist";
PRODUCT_BUNDLE_IDENTIFIER = "com.charcoaldesign.${PRODUCT_NAME:rfc1034identifier}";
PRODUCT_NAME = iCarouselExample;
TARGETED_DEVICE_FAMILY = "1,2";
VALIDATE_PRODUCT = YES;
WRAPPER_EXTENSION = app;
};
name = Release;
};
/* End XCBuildConfiguration section */
/* Begin XCConfigurationList section */
01308D8813491C3500453707 /* Build configuration list for PBXProject "iCarouselExample" */ = {
isa = XCConfigurationList;
buildConfigurations = (
01308DAD13491C3500453707 /* Debug */,
01308DAE13491C3500453707 /* Release */,
);
defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release;
};
01308DAF13491C3500453707 /* Build configuration list for PBXNativeTarget "iCarouselExample" */ = {
isa = XCConfigurationList;
buildConfigurations = (
01308DB013491C3500453707 /* Debug */,
01308DB113491C3500453707 /* Release */,
);
defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release;
};
/* End XCConfigurationList section */
};
rootObject = 01308D8513491C3500453707 /* Project object */;
}
================================================
FILE: Examples/Basic iOS Example/iCarouselExampleAppDelegate.h
================================================
//
// iCarouselExampleAppDelegate.h
// iCarouselExample
//
// Created by Nick Lockwood on 03/04/2011.
// Copyright 2011 Charcoal Design. All rights reserved.
//
#import
@class iCarouselExampleViewController;
@interface iCarouselExampleAppDelegate : NSObject
@property (nonatomic, strong) IBOutlet UIWindow *window;
@property (nonatomic, strong) IBOutlet iCarouselExampleViewController *viewController;
@end
================================================
FILE: Examples/Basic iOS Example/iCarouselExampleAppDelegate.m
================================================
//
// iCarouselExampleAppDelegate.m
// iCarouselExample
//
// Created by Nick Lockwood on 03/04/2011.
// Copyright 2011 Charcoal Design. All rights reserved.
//
#import "iCarouselExampleAppDelegate.h"
#import "iCarouselExampleViewController.h"
@implementation iCarouselExampleAppDelegate
@synthesize window;
@synthesize viewController;
- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions
{
window = [[UIWindow alloc] initWithFrame:[UIScreen mainScreen].bounds];
window.rootViewController = viewController;
[window makeKeyAndVisible];
return YES;
}
@end
================================================
FILE: Examples/Basic iOS Example/iCarouselExampleViewController.h
================================================
//
// iCarouselExampleViewController.h
// iCarouselExample
//
// Created by Nick Lockwood on 03/04/2011.
// Copyright 2011 Charcoal Design. All rights reserved.
//
#import
#import "iCarousel.h"
@interface iCarouselExampleViewController : UIViewController
@property (nonatomic, strong) IBOutlet iCarousel *carousel;
@end
================================================
FILE: Examples/Basic iOS Example/iCarouselExampleViewController.m
================================================
//
// iCarouselExampleViewController.m
// iCarouselExample
//
// Created by Nick Lockwood on 03/04/2011.
// Copyright 2011 Charcoal Design. All rights reserved.
//
#import "iCarouselExampleViewController.h"
@interface iCarouselExampleViewController ()
@property (nonatomic, strong) NSMutableArray *items;
@end
@implementation iCarouselExampleViewController
- (void)awakeFromNib
{
[super awakeFromNib];
//set up data
//your carousel should always be driven by an array of
//data of some kind - don't store data in your item views
//or the recycling mechanism will destroy your data once
//your item views move off-screen
self.items = [NSMutableArray array];
for (int i = 0; i < 100; i++)
{
[_items addObject:@(i)];
}
}
- (void)dealloc
{
//it's a good idea to set these to nil here to avoid
//sending messages to a deallocated viewcontroller
//this is true even if your project is using ARC, unless
//you are targeting iOS 5 as a minimum deployment target
_carousel.delegate = nil;
_carousel.dataSource = nil;
}
#pragma mark -
#pragma mark View lifecycle
- (void)viewDidLoad
{
[super viewDidLoad];
//configure carousel
_carousel.type = iCarouselTypeCoverFlow2;
}
- (void)viewDidUnload
{
[super viewDidUnload];
//free up memory by releasing subviews
self.carousel = nil;
}
- (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation
{
return YES;
}
#pragma mark -
#pragma mark iCarousel methods
- (NSInteger)numberOfItemsInCarousel:(iCarousel *)carousel
{
//return the total number of items in the carousel
return [_items count];
}
- (UIView *)carousel:(iCarousel *)carousel viewForItemAtIndex:(NSInteger)index reusingView:(UIView *)view
{
UILabel *label = nil;
//create new view if no view is available for recycling
if (view == nil)
{
//don't do anything specific to the index within
//this `if (view == nil) {...}` statement because the view will be
//recycled and used with other index values later
view = [[UIImageView alloc] initWithFrame:CGRectMake(0, 0, 200.0f, 200.0f)];
((UIImageView *)view).image = [UIImage imageNamed:@"page.png"];
view.contentMode = UIViewContentModeCenter;
label = [[UILabel alloc] initWithFrame:view.bounds];
label.backgroundColor = [UIColor clearColor];
label.textAlignment = NSTextAlignmentCenter;
label.font = [label.font fontWithSize:50];
label.tag = 1;
[view addSubview:label];
}
else
{
//get a reference to the label in the recycled view
label = (UILabel *)[view viewWithTag:1];
}
//set item label
//remember to always set any properties of your carousel item
//views outside of the `if (view == nil) {...}` check otherwise
//you'll get weird issues with carousel item content appearing
//in the wrong place in the carousel
label.text = [_items[index] stringValue];
return view;
}
- (CGFloat)carousel:(iCarousel *)carousel valueForOption:(iCarouselOption)option withDefault:(CGFloat)value
{
if (option == iCarouselOptionSpacing)
{
return value * 1.1;
}
return value;
}
@end
================================================
FILE: Examples/Basic iOS Example/main.m
================================================
//
// main.m
// iCarouselExample
//
// Created by Nick Lockwood on 03/04/2011.
// Copyright 2011 Charcoal Design. All rights reserved.
//
#import
int main(int argc, char *argv[])
{
@autoreleasepool
{
int retVal = UIApplicationMain(argc, argv, nil, nil);
return retVal;
}
}
================================================
FILE: Examples/Buttons Demo/en.lproj/InfoPlist.strings
================================================
/* Localized versions of Info.plist keys */
================================================
FILE: Examples/Buttons Demo/en.lproj/MainWindow.xib
================================================
155212E5530841187.39626.00com.apple.InterfaceBuilder.IBCocoaTouchPlugin2083YESIBProxyObjectIBUICustomObjectIBUIViewControllerIBUIWindowYEScom.apple.InterfaceBuilder.IBCocoaTouchPluginPluginDependencyRecalculationVersionYESIBFilesOwnerIBCocoaTouchFrameworkIBFirstResponderIBCocoaTouchFrameworkIBCocoaTouchFrameworkiCarouselExampleViewController11IBCocoaTouchFrameworkNO292{320, 480}1MSAxIDEAANONOIBCocoaTouchFrameworkYESYESdelegate4viewController11window14rootViewController16YES0YES-1File's Owner3iCarouselExample App Delegate-21012YESYES-1.CustomClassName-1.IBPluginDependency-2.CustomClassName-2.IBPluginDependency10.CustomClassName10.IBPluginDependency12.IBPluginDependency3.CustomClassName3.IBPluginDependencyYESUIApplicationcom.apple.InterfaceBuilder.IBCocoaTouchPluginUIRespondercom.apple.InterfaceBuilder.IBCocoaTouchPluginiCarouselExampleViewControllercom.apple.InterfaceBuilder.IBCocoaTouchPlugincom.apple.InterfaceBuilder.IBCocoaTouchPluginiCarouselExampleAppDelegatecom.apple.InterfaceBuilder.IBCocoaTouchPluginYESYES16YESiCarouselUIViewYESYESdataSourcedelegateYESididYESYESdataSourcedelegateYESdataSourceiddelegateidIBProjectSource./Classes/iCarousel.hiCarouselExampleAppDelegateNSObjectYESYESviewControllerwindowYESiCarouselExampleViewControllerUIWindowYESYESviewControllerwindowYESviewControlleriCarouselExampleViewControllerwindowUIWindowIBProjectSource./Classes/iCarouselExampleAppDelegate.hiCarouselExampleViewControllerUIViewControllercarouseliCarouselcarouselcarouseliCarouselIBProjectSource./Classes/iCarouselExampleViewController.h0IBCocoaTouchFrameworkcom.apple.InterfaceBuilder.CocoaTouchPlugin.iPhoneOScom.apple.InterfaceBuilder.CocoaTouchPlugin.InterfaceBuilder3YES32083
================================================
FILE: Examples/Buttons Demo/en.lproj/iCarouselExampleViewController.xib
================================================
128010K54919381038.36461.00com.apple.InterfaceBuilder.IBCocoaTouchPlugin933YESIBProxyObjectIBUIViewIBUIImageViewYEScom.apple.InterfaceBuilder.IBCocoaTouchPluginPluginDependencyRecalculationVersionYESIBFilesOwnerIBCocoaTouchFrameworkIBFirstResponderIBCocoaTouchFramework274YES274{320, 480}NOYESYESIBCocoaTouchFrameworkNSImagebackground.png274{320, 480}3MSAwAA2IBCocoaTouchFramework{320, 480}3MQANOIBCocoaTouchFrameworkYESview7carousel9dataSource10delegate11YES0YES-1File's Owner-26YES8YESiCarousel35YESYES-1.CustomClassName-1.IBPluginDependency-2.CustomClassName-2.IBPluginDependency35.IBPluginDependency6.IBPluginDependency8.CustomClassName8.IBPluginDependencyYESiCarouselExampleViewControllercom.apple.InterfaceBuilder.IBCocoaTouchPluginUIRespondercom.apple.InterfaceBuilder.IBCocoaTouchPlugincom.apple.InterfaceBuilder.IBCocoaTouchPlugincom.apple.InterfaceBuilder.IBCocoaTouchPluginiCarouselcom.apple.InterfaceBuilder.IBCocoaTouchPluginYESYES35YESiCarouselUIViewYESYESdataSourcedelegateYESididYESYESdataSourcedelegateYESdataSourceiddelegateidIBProjectSource./Classes/iCarousel.hiCarouselExampleViewControllerUIViewControllercarouseliCarouselcarouselcarouseliCarouselIBProjectSource./Classes/iCarouselExampleViewController.h0IBCocoaTouchFrameworkcom.apple.InterfaceBuilder.CocoaTouchPlugin.InterfaceBuilder3YES3background.png{50, 468}933
================================================
FILE: Examples/Buttons Demo/iCarouselButtonsDemo-Info.plist
================================================
CFBundleDevelopmentRegionenCFBundleDisplayName${PRODUCT_NAME}CFBundleExecutable${EXECUTABLE_NAME}CFBundleIconFileCFBundleIdentifier$(PRODUCT_BUNDLE_IDENTIFIER)CFBundleInfoDictionaryVersion6.0CFBundleName${PRODUCT_NAME}CFBundlePackageTypeAPPLCFBundleShortVersionString1.0CFBundleSignature????CFBundleVersion1.0LSRequiresIPhoneOSNSMainNibFileMainWindowUIStatusBarHiddenUISupportedInterfaceOrientationsUIInterfaceOrientationPortraitUIInterfaceOrientationLandscapeLeftUIInterfaceOrientationLandscapeRight
================================================
FILE: Examples/Buttons Demo/iCarouselButtonsDemo-Prefix.pch
================================================
//
// Prefix header for all source files of the 'iCarouselExample' target in the 'iCarouselExample' project
//
#import
#ifndef __IPHONE_3_0
#warning "This project uses features only available in iPhone SDK 3.0 and later."
#endif
#ifdef __OBJC__
#import
#import
#endif
================================================
FILE: Examples/Buttons Demo/iCarouselButtonsDemo.xcodeproj/project.pbxproj
================================================
// !$*UTF8*$!
{
archiveVersion = 1;
classes = {
};
objectVersion = 46;
objects = {
/* Begin PBXBuildFile section */
01308D9313491C3500453707 /* UIKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 01308D9213491C3500453707 /* UIKit.framework */; };
01308D9513491C3500453707 /* Foundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 01308D9413491C3500453707 /* Foundation.framework */; };
01308D9713491C3500453707 /* CoreGraphics.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 01308D9613491C3500453707 /* CoreGraphics.framework */; };
01308DC013491F7200453707 /* QuartzCore.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 01308DBF13491F7200453707 /* QuartzCore.framework */; };
0148358813A36C2000E687AC /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 0148358313A36C2000E687AC /* main.m */; };
0148359313A36C3700E687AC /* iCarouselExampleViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 0148358B13A36C3700E687AC /* iCarouselExampleViewController.m */; };
0148359413A36C3700E687AC /* iCarouselExampleAppDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = 0148358D13A36C3700E687AC /* iCarouselExampleAppDelegate.m */; };
0148359513A36C3700E687AC /* MainWindow.xib in Resources */ = {isa = PBXBuildFile; fileRef = 0148358F13A36C3700E687AC /* MainWindow.xib */; };
0148359613A36C3700E687AC /* iCarouselExampleViewController.xib in Resources */ = {isa = PBXBuildFile; fileRef = 0148359113A36C3700E687AC /* iCarouselExampleViewController.xib */; };
018AE98C179D7F6A00FB7311 /* Default-568h@2x.png in Resources */ = {isa = PBXBuildFile; fileRef = 018AE98B179D7F6A00FB7311 /* Default-568h@2x.png */; };
B29BD7B814A3476C00BB4E68 /* background.png in Resources */ = {isa = PBXBuildFile; fileRef = B29BD7B614A3476C00BB4E68 /* background.png */; };
B29BD7B914A3476C00BB4E68 /* page.png in Resources */ = {isa = PBXBuildFile; fileRef = B29BD7B714A3476C00BB4E68 /* page.png */; };
B2E5E749146155E300EADB7A /* iCarousel.m in Sources */ = {isa = PBXBuildFile; fileRef = B2E5E748146155E300EADB7A /* iCarousel.m */; };
/* End PBXBuildFile section */
/* Begin PBXFileReference section */
01308D9213491C3500453707 /* UIKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = UIKit.framework; path = System/Library/Frameworks/UIKit.framework; sourceTree = SDKROOT; };
01308D9413491C3500453707 /* Foundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Foundation.framework; path = System/Library/Frameworks/Foundation.framework; sourceTree = SDKROOT; };
01308D9613491C3500453707 /* CoreGraphics.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreGraphics.framework; path = System/Library/Frameworks/CoreGraphics.framework; sourceTree = SDKROOT; };
01308DBF13491F7200453707 /* QuartzCore.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = QuartzCore.framework; path = System/Library/Frameworks/QuartzCore.framework; sourceTree = SDKROOT; };
0148358313A36C2000E687AC /* main.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = main.m; sourceTree = SOURCE_ROOT; };
0148358413A36C2000E687AC /* iCarouselButtonsDemo-Prefix.pch */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "iCarouselButtonsDemo-Prefix.pch"; sourceTree = SOURCE_ROOT; };
0148358513A36C2000E687AC /* iCarouselButtonsDemo-Info.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; path = "iCarouselButtonsDemo-Info.plist"; sourceTree = SOURCE_ROOT; };
0148358713A36C2000E687AC /* en */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = en; path = en.lproj/InfoPlist.strings; sourceTree = SOURCE_ROOT; };
0148358B13A36C3700E687AC /* iCarouselExampleViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = iCarouselExampleViewController.m; sourceTree = SOURCE_ROOT; };
0148358C13A36C3700E687AC /* iCarouselExampleViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = iCarouselExampleViewController.h; sourceTree = SOURCE_ROOT; };
0148358D13A36C3700E687AC /* iCarouselExampleAppDelegate.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = iCarouselExampleAppDelegate.m; sourceTree = SOURCE_ROOT; };
0148358E13A36C3700E687AC /* iCarouselExampleAppDelegate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = iCarouselExampleAppDelegate.h; sourceTree = SOURCE_ROOT; };
0148359013A36C3700E687AC /* en */ = {isa = PBXFileReference; lastKnownFileType = file.xib; name = en; path = en.lproj/MainWindow.xib; sourceTree = SOURCE_ROOT; };
0148359213A36C3700E687AC /* en */ = {isa = PBXFileReference; lastKnownFileType = file.xib; name = en; path = en.lproj/iCarouselExampleViewController.xib; sourceTree = SOURCE_ROOT; };
018AE98B179D7F6A00FB7311 /* Default-568h@2x.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = "Default-568h@2x.png"; sourceTree = SOURCE_ROOT; };
018BBCB413A375AF005CA505 /* iCarouselButtonsDemo.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = iCarouselButtonsDemo.app; sourceTree = BUILT_PRODUCTS_DIR; };
B29BD7B614A3476C00BB4E68 /* background.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = background.png; sourceTree = ""; };
B29BD7B714A3476C00BB4E68 /* page.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = page.png; sourceTree = ""; };
B2E5E747146155E300EADB7A /* iCarousel.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = iCarousel.h; sourceTree = ""; };
B2E5E748146155E300EADB7A /* iCarousel.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = iCarousel.m; sourceTree = ""; };
/* End PBXFileReference section */
/* Begin PBXFrameworksBuildPhase section */
01308D8B13491C3500453707 /* Frameworks */ = {
isa = PBXFrameworksBuildPhase;
buildActionMask = 2147483647;
files = (
01308DC013491F7200453707 /* QuartzCore.framework in Frameworks */,
01308D9313491C3500453707 /* UIKit.framework in Frameworks */,
01308D9513491C3500453707 /* Foundation.framework in Frameworks */,
01308D9713491C3500453707 /* CoreGraphics.framework in Frameworks */,
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXFrameworksBuildPhase section */
/* Begin PBXGroup section */
01308D8313491C3500453707 = {
isa = PBXGroup;
children = (
B2E5E746146155E300EADB7A /* iCarousel */,
01308D9813491C3500453707 /* iCarouselExample */,
B29BD7B514A3476C00BB4E68 /* Resources */,
01308D9113491C3500453707 /* Frameworks */,
01308D8F13491C3500453707 /* Products */,
);
sourceTree = "";
};
01308D8F13491C3500453707 /* Products */ = {
isa = PBXGroup;
children = (
018BBCB413A375AF005CA505 /* iCarouselButtonsDemo.app */,
);
name = Products;
sourceTree = "";
};
01308D9113491C3500453707 /* Frameworks */ = {
isa = PBXGroup;
children = (
01308DBF13491F7200453707 /* QuartzCore.framework */,
01308D9213491C3500453707 /* UIKit.framework */,
01308D9413491C3500453707 /* Foundation.framework */,
01308D9613491C3500453707 /* CoreGraphics.framework */,
);
name = Frameworks;
sourceTree = "";
};
01308D9813491C3500453707 /* iCarouselExample */ = {
isa = PBXGroup;
children = (
0148358B13A36C3700E687AC /* iCarouselExampleViewController.m */,
0148358C13A36C3700E687AC /* iCarouselExampleViewController.h */,
0148358D13A36C3700E687AC /* iCarouselExampleAppDelegate.m */,
0148358E13A36C3700E687AC /* iCarouselExampleAppDelegate.h */,
0148358F13A36C3700E687AC /* MainWindow.xib */,
0148359113A36C3700E687AC /* iCarouselExampleViewController.xib */,
01308D9913491C3500453707 /* Supporting Files */,
);
path = iCarouselExample;
sourceTree = "";
};
01308D9913491C3500453707 /* Supporting Files */ = {
isa = PBXGroup;
children = (
018AE98B179D7F6A00FB7311 /* Default-568h@2x.png */,
0148358313A36C2000E687AC /* main.m */,
0148358413A36C2000E687AC /* iCarouselButtonsDemo-Prefix.pch */,
0148358513A36C2000E687AC /* iCarouselButtonsDemo-Info.plist */,
0148358613A36C2000E687AC /* InfoPlist.strings */,
);
name = "Supporting Files";
sourceTree = "";
};
B29BD7B514A3476C00BB4E68 /* Resources */ = {
isa = PBXGroup;
children = (
B29BD7B614A3476C00BB4E68 /* background.png */,
B29BD7B714A3476C00BB4E68 /* page.png */,
);
name = Resources;
path = ../Resources;
sourceTree = "";
};
B2E5E746146155E300EADB7A /* iCarousel */ = {
isa = PBXGroup;
children = (
B2E5E747146155E300EADB7A /* iCarousel.h */,
B2E5E748146155E300EADB7A /* iCarousel.m */,
);
name = iCarousel;
path = ../../iCarousel;
sourceTree = "";
};
/* End PBXGroup section */
/* Begin PBXNativeTarget section */
01308D8D13491C3500453707 /* iCarouselButtonsDemo */ = {
isa = PBXNativeTarget;
buildConfigurationList = 01308DAF13491C3500453707 /* Build configuration list for PBXNativeTarget "iCarouselButtonsDemo" */;
buildPhases = (
01308D8A13491C3500453707 /* Sources */,
01308D8B13491C3500453707 /* Frameworks */,
01308D8C13491C3500453707 /* Resources */,
);
buildRules = (
);
dependencies = (
);
name = iCarouselButtonsDemo;
productName = iCarouselExample;
productReference = 018BBCB413A375AF005CA505 /* iCarouselButtonsDemo.app */;
productType = "com.apple.product-type.application";
};
/* End PBXNativeTarget section */
/* Begin PBXProject section */
01308D8513491C3500453707 /* Project object */ = {
isa = PBXProject;
attributes = {
LastUpgradeCheck = 0800;
};
buildConfigurationList = 01308D8813491C3500453707 /* Build configuration list for PBXProject "iCarouselButtonsDemo" */;
compatibilityVersion = "Xcode 3.2";
developmentRegion = English;
hasScannedForEncodings = 0;
knownRegions = (
en,
);
mainGroup = 01308D8313491C3500453707;
productRefGroup = 01308D8F13491C3500453707 /* Products */;
projectDirPath = "";
projectRoot = "";
targets = (
01308D8D13491C3500453707 /* iCarouselButtonsDemo */,
);
};
/* End PBXProject section */
/* Begin PBXResourcesBuildPhase section */
01308D8C13491C3500453707 /* Resources */ = {
isa = PBXResourcesBuildPhase;
buildActionMask = 2147483647;
files = (
0148359513A36C3700E687AC /* MainWindow.xib in Resources */,
0148359613A36C3700E687AC /* iCarouselExampleViewController.xib in Resources */,
B29BD7B814A3476C00BB4E68 /* background.png in Resources */,
B29BD7B914A3476C00BB4E68 /* page.png in Resources */,
018AE98C179D7F6A00FB7311 /* Default-568h@2x.png in Resources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXResourcesBuildPhase section */
/* Begin PBXSourcesBuildPhase section */
01308D8A13491C3500453707 /* Sources */ = {
isa = PBXSourcesBuildPhase;
buildActionMask = 2147483647;
files = (
0148358813A36C2000E687AC /* main.m in Sources */,
0148359313A36C3700E687AC /* iCarouselExampleViewController.m in Sources */,
0148359413A36C3700E687AC /* iCarouselExampleAppDelegate.m in Sources */,
B2E5E749146155E300EADB7A /* iCarousel.m in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXSourcesBuildPhase section */
/* Begin PBXVariantGroup section */
0148358613A36C2000E687AC /* InfoPlist.strings */ = {
isa = PBXVariantGroup;
children = (
0148358713A36C2000E687AC /* en */,
);
name = InfoPlist.strings;
sourceTree = "";
};
0148358F13A36C3700E687AC /* MainWindow.xib */ = {
isa = PBXVariantGroup;
children = (
0148359013A36C3700E687AC /* en */,
);
name = MainWindow.xib;
sourceTree = "";
};
0148359113A36C3700E687AC /* iCarouselExampleViewController.xib */ = {
isa = PBXVariantGroup;
children = (
0148359213A36C3700E687AC /* en */,
);
name = iCarouselExampleViewController.xib;
sourceTree = "";
};
/* End PBXVariantGroup section */
/* Begin XCBuildConfiguration section */
01308DAD13491C3500453707 /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
ENABLE_TESTABILITY = YES;
GCC_C_LANGUAGE_STANDARD = gnu99;
GCC_OPTIMIZATION_LEVEL = 0;
GCC_PREPROCESSOR_DEFINITIONS = DEBUG;
GCC_SYMBOLS_PRIVATE_EXTERN = NO;
GCC_VERSION = com.apple.compilers.llvmgcc42;
GCC_WARN_ABOUT_RETURN_TYPE = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 8.0;
ONLY_ACTIVE_ARCH = YES;
SDKROOT = iphoneos;
};
name = Debug;
};
01308DAE13491C3500453707 /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
GCC_C_LANGUAGE_STANDARD = gnu99;
GCC_VERSION = com.apple.compilers.llvmgcc42;
GCC_WARN_ABOUT_RETURN_TYPE = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 8.0;
OTHER_CFLAGS = "-DNS_BLOCK_ASSERTIONS=1";
SDKROOT = iphoneos;
};
name = Release;
};
01308DB013491C3500453707 /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
CLANG_ENABLE_OBJC_ARC = YES;
COPY_PHASE_STRIP = NO;
GCC_DYNAMIC_NO_PIC = NO;
GCC_PRECOMPILE_PREFIX_HEADER = YES;
GCC_PREFIX_HEADER = "iCarouselButtonsDemo-Prefix.pch";
GCC_THUMB_SUPPORT = NO;
GCC_VERSION = com.apple.compilers.llvm.clang.1_0;
INFOPLIST_FILE = "iCarouselButtonsDemo-Info.plist";
PRODUCT_BUNDLE_IDENTIFIER = "com.charcoaldesign.${PRODUCT_NAME:rfc1034identifier}";
PRODUCT_NAME = iCarouselButtonsDemo;
TARGETED_DEVICE_FAMILY = "1,2";
WRAPPER_EXTENSION = app;
};
name = Debug;
};
01308DB113491C3500453707 /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
CLANG_ENABLE_OBJC_ARC = YES;
COPY_PHASE_STRIP = YES;
GCC_PRECOMPILE_PREFIX_HEADER = YES;
GCC_PREFIX_HEADER = "iCarouselButtonsDemo-Prefix.pch";
GCC_THUMB_SUPPORT = NO;
GCC_VERSION = com.apple.compilers.llvm.clang.1_0;
INFOPLIST_FILE = "iCarouselButtonsDemo-Info.plist";
PRODUCT_BUNDLE_IDENTIFIER = "com.charcoaldesign.${PRODUCT_NAME:rfc1034identifier}";
PRODUCT_NAME = iCarouselButtonsDemo;
TARGETED_DEVICE_FAMILY = "1,2";
VALIDATE_PRODUCT = YES;
WRAPPER_EXTENSION = app;
};
name = Release;
};
/* End XCBuildConfiguration section */
/* Begin XCConfigurationList section */
01308D8813491C3500453707 /* Build configuration list for PBXProject "iCarouselButtonsDemo" */ = {
isa = XCConfigurationList;
buildConfigurations = (
01308DAD13491C3500453707 /* Debug */,
01308DAE13491C3500453707 /* Release */,
);
defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release;
};
01308DAF13491C3500453707 /* Build configuration list for PBXNativeTarget "iCarouselButtonsDemo" */ = {
isa = XCConfigurationList;
buildConfigurations = (
01308DB013491C3500453707 /* Debug */,
01308DB113491C3500453707 /* Release */,
);
defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release;
};
/* End XCConfigurationList section */
};
rootObject = 01308D8513491C3500453707 /* Project object */;
}
================================================
FILE: Examples/Buttons Demo/iCarouselExampleAppDelegate.h
================================================
//
// iCarouselExampleAppDelegate.h
// iCarouselExample
//
// Created by Nick Lockwood on 03/04/2011.
// Copyright 2011 Charcoal Design. All rights reserved.
//
#import
@class iCarouselExampleViewController;
@interface iCarouselExampleAppDelegate : NSObject
@property (nonatomic, strong) IBOutlet UIWindow *window;
@property (nonatomic, strong) IBOutlet iCarouselExampleViewController *viewController;
@end
================================================
FILE: Examples/Buttons Demo/iCarouselExampleAppDelegate.m
================================================
//
// iCarouselExampleAppDelegate.m
// iCarouselExample
//
// Created by Nick Lockwood on 03/04/2011.
// Copyright 2011 Charcoal Design. All rights reserved.
//
#import "iCarouselExampleAppDelegate.h"
#import "iCarouselExampleViewController.h"
@implementation iCarouselExampleAppDelegate
@synthesize window;
@synthesize viewController;
- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions
{
[window addSubview:viewController.view];
[window makeKeyAndVisible];
return YES;
}
@end
================================================
FILE: Examples/Buttons Demo/iCarouselExampleViewController.h
================================================
//
// iCarouselExampleViewController.h
// iCarouselExample
//
// Created by Nick Lockwood on 03/04/2011.
// Copyright 2011 Charcoal Design. All rights reserved.
//
#import
#import "iCarousel.h"
@interface iCarouselExampleViewController : UIViewController
@property (nonatomic, strong) IBOutlet iCarousel *carousel;
@end
================================================
FILE: Examples/Buttons Demo/iCarouselExampleViewController.m
================================================
//
// iCarouselExampleViewController.m
// iCarouselExample
//
// Created by Nick Lockwood on 03/04/2011.
// Copyright 2011 Charcoal Design. All rights reserved.
//
#import "iCarouselExampleViewController.h"
@implementation iCarouselExampleViewController
@synthesize carousel;
- (void)dealloc
{
carousel.delegate = nil;
carousel.dataSource = nil;
}
#pragma mark -
#pragma mark View lifecycle
- (void)viewDidLoad
{
[super viewDidLoad];
//configure carousel
carousel.type = iCarouselTypeCoverFlow2;
}
- (void)viewDidUnload
{
[super viewDidUnload];
self.carousel = nil;
}
- (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation
{
return YES;
}
#pragma mark -
#pragma mark iCarousel methods
- (NSInteger)numberOfItemsInCarousel:(iCarousel *)carousel
{
//generate 100 buttons
//normally we'd use a backing array
//as shown in the basic iOS example
//but for this example we haven't bothered
return 100;
}
- (UIView *)carousel:(iCarousel *)carousel viewForItemAtIndex:(NSInteger)index reusingView:(UIView *)view
{
UIButton *button = (UIButton *)view;
if (button == nil)
{
//no button available to recycle, so create new one
UIImage *image = [UIImage imageNamed:@"page.png"];
button = [UIButton buttonWithType:UIButtonTypeCustom];
button.frame = CGRectMake(0.0f, 0.0f, image.size.width, image.size.height);
[button setTitleColor:[UIColor blackColor] forState:UIControlStateNormal];
[button setBackgroundImage:image forState:UIControlStateNormal];
button.titleLabel.font = [button.titleLabel.font fontWithSize:50];
[button addTarget:self action:@selector(buttonTapped:) forControlEvents:UIControlEventTouchUpInside];
}
//set button label
[button setTitle:[NSString stringWithFormat:@"%zd", index] forState:UIControlStateNormal];
return button;
}
#pragma mark -
#pragma mark Button tap event
- (void)buttonTapped:(UIButton *)sender
{
//get item index for button
NSInteger index = [carousel indexOfItemViewOrSubview:sender];
[[[UIAlertView alloc] initWithTitle:@"Button Tapped"
message:[NSString stringWithFormat:@"You tapped button number %zd", index]
delegate:nil
cancelButtonTitle:@"OK"
otherButtonTitles:nil] show];
}
@end
================================================
FILE: Examples/Buttons Demo/main.m
================================================
//
// main.m
// iCarouselExample
//
// Created by Nick Lockwood on 03/04/2011.
// Copyright 2011 Charcoal Design. All rights reserved.
//
#import
int main(int argc, char *argv[])
{
@autoreleasepool {
int retVal = UIApplicationMain(argc, argv, nil, nil);
return retVal;
}
}
================================================
FILE: Examples/Chameleon Demo/Chameleon/.gitignore
================================================
build
xcuserdata
*.perspectivev3
*.pbxuser
*.DS_Store
.svn
*.xcuserstate
*.xcsettings
================================================
FILE: Examples/Chameleon Demo/Chameleon/AVFoundation/AVFoundation.xcodeproj/project.pbxproj
================================================
// !$*UTF8*$!
{
archiveVersion = 1;
classes = {
};
objectVersion = 46;
objects = {
/* Begin PBXBuildFile section */
14C25EC21211EBC600622309 /* AVAudioSession.h in Headers */ = {isa = PBXBuildFile; fileRef = 14C25EC01211EBC600622309 /* AVAudioSession.h */; settings = {ATTRIBUTES = (Public, ); }; };
14C25EC31211EBC600622309 /* AVAudioSession.m in Sources */ = {isa = PBXBuildFile; fileRef = 14C25EC11211EBC600622309 /* AVAudioSession.m */; };
14EFB1A11211DADE00D19B0C /* AVAudioPlayer.h in Headers */ = {isa = PBXBuildFile; fileRef = 14EFB19F1211DADE00D19B0C /* AVAudioPlayer.h */; settings = {ATTRIBUTES = (Public, ); }; };
14EFB1A21211DADE00D19B0C /* AVAudioPlayer.m in Sources */ = {isa = PBXBuildFile; fileRef = 14EFB1A01211DADE00D19B0C /* AVAudioPlayer.m */; };
14EFB1A81211DB0B00D19B0C /* AVFoundation.h in Headers */ = {isa = PBXBuildFile; fileRef = 14EFB1A71211DB0B00D19B0C /* AVFoundation.h */; settings = {ATTRIBUTES = (Public, ); }; };
14EFB1BB1211DB5300D19B0C /* Cocoa.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 14EFB1BA1211DB5300D19B0C /* Cocoa.framework */; };
/* End PBXBuildFile section */
/* Begin PBXFileReference section */
0867D69BFE84028FC02AAC07 /* Foundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Foundation.framework; path = /System/Library/Frameworks/Foundation.framework; sourceTree = ""; };
0867D6A5FE840307C02AAC07 /* AppKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = AppKit.framework; path = /System/Library/Frameworks/AppKit.framework; sourceTree = ""; };
146B1C8C1211D9DA002D85C3 /* AVFoundation_Prefix.pch */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AVFoundation_Prefix.pch; sourceTree = ""; };
14C25EC01211EBC600622309 /* AVAudioSession.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = AVAudioSession.h; path = Classes/AVAudioSession.h; sourceTree = ""; };
14C25EC11211EBC600622309 /* AVAudioSession.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = AVAudioSession.m; path = Classes/AVAudioSession.m; sourceTree = ""; };
14EFB19F1211DADE00D19B0C /* AVAudioPlayer.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = AVAudioPlayer.h; path = Classes/AVAudioPlayer.h; sourceTree = ""; };
14EFB1A01211DADE00D19B0C /* AVAudioPlayer.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = AVAudioPlayer.m; path = Classes/AVAudioPlayer.m; sourceTree = ""; };
14EFB1A71211DB0B00D19B0C /* AVFoundation.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = AVFoundation.h; path = Classes/AVFoundation.h; sourceTree = ""; };
14EFB1BA1211DB5300D19B0C /* Cocoa.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Cocoa.framework; path = System/Library/Frameworks/Cocoa.framework; sourceTree = SDKROOT; };
8DC2EF5A0486A6940098B216 /* Info.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; };
8DC2EF5B0486A6940098B216 /* AVFoundation.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = AVFoundation.framework; sourceTree = BUILT_PRODUCTS_DIR; };
/* End PBXFileReference section */
/* Begin PBXFrameworksBuildPhase section */
8DC2EF560486A6940098B216 /* Frameworks */ = {
isa = PBXFrameworksBuildPhase;
buildActionMask = 2147483647;
files = (
14EFB1BB1211DB5300D19B0C /* Cocoa.framework in Frameworks */,
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXFrameworksBuildPhase section */
/* Begin PBXGroup section */
034768DFFF38A50411DB9C8B /* Products */ = {
isa = PBXGroup;
children = (
8DC2EF5B0486A6940098B216 /* AVFoundation.framework */,
);
name = Products;
sourceTree = "";
};
0867D691FE84028FC02AAC07 /* UIKit */ = {
isa = PBXGroup;
children = (
08FB77AEFE84172EC02AAC07 /* Classes */,
089C1665FE841158C02AAC07 /* Resources */,
32C88DFF0371C24200C91783 /* Other Sources */,
0867D69AFE84028FC02AAC07 /* External Frameworks and Libraries */,
034768DFFF38A50411DB9C8B /* Products */,
);
name = UIKit;
sourceTree = "";
};
0867D69AFE84028FC02AAC07 /* External Frameworks and Libraries */ = {
isa = PBXGroup;
children = (
0867D6A5FE840307C02AAC07 /* AppKit.framework */,
0867D69BFE84028FC02AAC07 /* Foundation.framework */,
14EFB1BA1211DB5300D19B0C /* Cocoa.framework */,
);
name = "External Frameworks and Libraries";
sourceTree = "";
};
089C1665FE841158C02AAC07 /* Resources */ = {
isa = PBXGroup;
children = (
8DC2EF5A0486A6940098B216 /* Info.plist */,
);
name = Resources;
sourceTree = "";
};
08FB77AEFE84172EC02AAC07 /* Classes */ = {
isa = PBXGroup;
children = (
14EFB19F1211DADE00D19B0C /* AVAudioPlayer.h */,
14EFB1A01211DADE00D19B0C /* AVAudioPlayer.m */,
14EFB1A71211DB0B00D19B0C /* AVFoundation.h */,
14C25EC01211EBC600622309 /* AVAudioSession.h */,
14C25EC11211EBC600622309 /* AVAudioSession.m */,
);
name = Classes;
sourceTree = "";
};
32C88DFF0371C24200C91783 /* Other Sources */ = {
isa = PBXGroup;
children = (
146B1C8C1211D9DA002D85C3 /* AVFoundation_Prefix.pch */,
);
name = "Other Sources";
sourceTree = "";
};
/* End PBXGroup section */
/* Begin PBXHeadersBuildPhase section */
8DC2EF500486A6940098B216 /* Headers */ = {
isa = PBXHeadersBuildPhase;
buildActionMask = 2147483647;
files = (
14EFB1A11211DADE00D19B0C /* AVAudioPlayer.h in Headers */,
14EFB1A81211DB0B00D19B0C /* AVFoundation.h in Headers */,
14C25EC21211EBC600622309 /* AVAudioSession.h in Headers */,
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXHeadersBuildPhase section */
/* Begin PBXNativeTarget section */
8DC2EF4F0486A6940098B216 /* AVFoundation */ = {
isa = PBXNativeTarget;
buildConfigurationList = 1DEB91AD08733DA50010E9CD /* Build configuration list for PBXNativeTarget "AVFoundation" */;
buildPhases = (
8DC2EF500486A6940098B216 /* Headers */,
8DC2EF520486A6940098B216 /* Resources */,
8DC2EF540486A6940098B216 /* Sources */,
8DC2EF560486A6940098B216 /* Frameworks */,
);
buildRules = (
);
dependencies = (
);
name = AVFoundation;
productInstallPath = "$(HOME)/Library/Frameworks";
productName = UIKit;
productReference = 8DC2EF5B0486A6940098B216 /* AVFoundation.framework */;
productType = "com.apple.product-type.framework";
};
/* End PBXNativeTarget section */
/* Begin PBXProject section */
0867D690FE84028FC02AAC07 /* Project object */ = {
isa = PBXProject;
attributes = {
LastUpgradeCheck = 0510;
};
buildConfigurationList = 1DEB91B108733DA50010E9CD /* Build configuration list for PBXProject "AVFoundation" */;
compatibilityVersion = "Xcode 3.2";
developmentRegion = English;
hasScannedForEncodings = 1;
knownRegions = (
English,
Japanese,
French,
German,
);
mainGroup = 0867D691FE84028FC02AAC07 /* UIKit */;
productRefGroup = 034768DFFF38A50411DB9C8B /* Products */;
projectDirPath = "";
projectRoot = "";
targets = (
8DC2EF4F0486A6940098B216 /* AVFoundation */,
);
};
/* End PBXProject section */
/* Begin PBXResourcesBuildPhase section */
8DC2EF520486A6940098B216 /* Resources */ = {
isa = PBXResourcesBuildPhase;
buildActionMask = 2147483647;
files = (
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXResourcesBuildPhase section */
/* Begin PBXSourcesBuildPhase section */
8DC2EF540486A6940098B216 /* Sources */ = {
isa = PBXSourcesBuildPhase;
buildActionMask = 2147483647;
files = (
14EFB1A21211DADE00D19B0C /* AVAudioPlayer.m in Sources */,
14C25EC31211EBC600622309 /* AVAudioSession.m in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXSourcesBuildPhase section */
/* Begin XCBuildConfiguration section */
1DEB91AE08733DA50010E9CD /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
COPY_PHASE_STRIP = NO;
DYLIB_COMPATIBILITY_VERSION = 1;
DYLIB_CURRENT_VERSION = 1;
FRAMEWORK_VERSION = A;
GCC_DYNAMIC_NO_PIC = NO;
GCC_MODEL_TUNING = G5;
GCC_OPTIMIZATION_LEVEL = 0;
GCC_PRECOMPILE_PREFIX_HEADER = YES;
GCC_PREFIX_HEADER = AVFoundation_Prefix.pch;
INFOPLIST_FILE = Info.plist;
INSTALL_PATH = "@executable_path/../Frameworks";
PRODUCT_NAME = AVFoundation;
SYMROOT = ../build;
WRAPPER_EXTENSION = framework;
};
name = Debug;
};
1DEB91AF08733DA50010E9CD /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
DYLIB_COMPATIBILITY_VERSION = 1;
DYLIB_CURRENT_VERSION = 1;
FRAMEWORK_VERSION = A;
GCC_MODEL_TUNING = G5;
GCC_PRECOMPILE_PREFIX_HEADER = YES;
GCC_PREFIX_HEADER = AVFoundation_Prefix.pch;
INFOPLIST_FILE = Info.plist;
INSTALL_PATH = "@executable_path/../Frameworks";
PRODUCT_NAME = AVFoundation;
SYMROOT = ../build;
WRAPPER_EXTENSION = framework;
};
name = Release;
};
1DEB91B208733DA50010E9CD /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
GCC_C_LANGUAGE_STANDARD = gnu99;
GCC_OPTIMIZATION_LEVEL = 0;
GCC_WARN_ABOUT_MISSING_PROTOTYPES = YES;
GCC_WARN_ABOUT_RETURN_TYPE = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
MACOSX_DEPLOYMENT_TARGET = 10.7;
ONLY_ACTIVE_ARCH = YES;
SDKROOT = macosx;
};
name = Debug;
};
1DEB91B308733DA50010E9CD /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
CODE_SIGN_IDENTITY = "3rd Party Mac Developer Application";
GCC_C_LANGUAGE_STANDARD = gnu99;
GCC_WARN_ABOUT_MISSING_PROTOTYPES = YES;
GCC_WARN_ABOUT_RETURN_TYPE = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
MACOSX_DEPLOYMENT_TARGET = 10.7;
PROVISIONING_PROFILE = "";
SDKROOT = macosx;
};
name = Release;
};
/* End XCBuildConfiguration section */
/* Begin XCConfigurationList section */
1DEB91AD08733DA50010E9CD /* Build configuration list for PBXNativeTarget "AVFoundation" */ = {
isa = XCConfigurationList;
buildConfigurations = (
1DEB91AE08733DA50010E9CD /* Debug */,
1DEB91AF08733DA50010E9CD /* Release */,
);
defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release;
};
1DEB91B108733DA50010E9CD /* Build configuration list for PBXProject "AVFoundation" */ = {
isa = XCConfigurationList;
buildConfigurations = (
1DEB91B208733DA50010E9CD /* Debug */,
1DEB91B308733DA50010E9CD /* Release */,
);
defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release;
};
/* End XCConfigurationList section */
};
rootObject = 0867D690FE84028FC02AAC07 /* Project object */;
}
================================================
FILE: Examples/Chameleon Demo/Chameleon/AVFoundation/AVFoundation.xcodeproj/project.xcworkspace/contents.xcworkspacedata
================================================
================================================
FILE: Examples/Chameleon Demo/Chameleon/AVFoundation/AVFoundation_Prefix.pch
================================================
/*
* Copyright (c) 2011, The Iconfactory. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of The Iconfactory nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE ICONFACTORY BE LIABLE FOR ANY DIRECT,
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
* OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#ifdef __OBJC__
#import
#endif
================================================
FILE: Examples/Chameleon Demo/Chameleon/AVFoundation/Classes/AVAudioPlayer.h
================================================
/*
* Copyright (c) 2011, The Iconfactory. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of The Iconfactory nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE ICONFACTORY BE LIABLE FOR ANY DIRECT,
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
* OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#import
@class AVAudioPlayer;
@protocol AVAudioPlayerDelegate
@optional
- (void)audioPlayerDidFinishPlaying:(AVAudioPlayer *)player successfully:(BOOL)flag;
- (void)audioPlayerDecodeErrorDidOccur:(AVAudioPlayer *)player error:(NSError *)error;
- (void)audioPlayerBeginInterruption:(AVAudioPlayer *)player;
- (void)audioPlayerEndInterruption:(AVAudioPlayer *)player;
@end
@interface AVAudioPlayer : NSObject {
@private
id _player;
id _delegate;
NSInteger _numberOfLoops;
NSInteger _currentLoop;
NSURL *_url;
NSData *_data;
BOOL _isPaused;
}
- (id)initWithContentsOfURL:(NSURL *)url error:(NSError **)outError;
- (id)initWithData:(NSData *)data error:(NSError **)outError;
- (BOOL)prepareToPlay; // always returns YES (lies!)
- (BOOL)play;
- (void)pause;
- (void)stop;
@property (readonly, getter=isPlaying) BOOL playing;
@property float volume;
@property NSInteger numberOfLoops;
@property (assign) id delegate;
@property (readonly) NSTimeInterval duration;
@property NSTimeInterval currentTime;
@property (readonly) NSURL *url;
@property (readonly) NSData *data;
@end
================================================
FILE: Examples/Chameleon Demo/Chameleon/AVFoundation/Classes/AVAudioPlayer.m
================================================
/*
* Copyright (c) 2011, The Iconfactory. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of The Iconfactory nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE ICONFACTORY BE LIABLE FOR ANY DIRECT,
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
* OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#import "AVAudioPlayer.h"
#import
@implementation AVAudioPlayer
@synthesize delegate=_delegate, url=_url, data=_data;
- (id)init
{
if ((self=[super init])) {
_numberOfLoops = 0;
}
return self;
}
- (id)initWithContentsOfURL:(NSURL *)url error:(NSError **)outError
{
if ((self=[self init])) {
_url = [url retain];
_player = [[NSSound alloc] initWithContentsOfURL:_url byReference:YES];
[_player setDelegate:self];
}
return self;
}
- (id)initWithData:(NSData *)data error:(NSError **)outError
{
if ((self=[self init])) {
_data = [data retain];
_player = [[NSSound alloc] initWithData:_data];
[_player setDelegate:self];
}
return self;
}
- (void)dealloc
{
[(NSSound *)_player stop]; // I swear the docs say that NSSound should stop itself when released, but I don't think it's doing that. Or else something else bad is going on. This helps for now.
[_player release];
[_data release];
[_url release];
[super dealloc];
}
- (BOOL)prepareToPlay
{
return YES;
}
- (BOOL)play
{
BOOL r = NO;
@synchronized (self) {
r = _isPaused? [(NSSound *)_player resume] : [(NSSound *)_player play];
_isPaused = NO;
}
return r;
}
- (void)pause
{
@synchronized (self) {
if (!_isPaused) {
_isPaused = YES;
[(NSSound *)_player pause];
}
}
}
- (void)stop
{
@synchronized (self) {
[(NSSound *)_player stop];
_currentLoop = 0;
_isPaused = NO;
}
}
- (BOOL)isPlaying
{
@synchronized (self) {
return [_player isPlaying];
}
}
- (float)volume
{
@synchronized (self) {
return [_player volume];
}
}
- (void)setVolume:(float)v
{
@synchronized (self) {
[_player setVolume:v];
}
}
- (NSInteger)numberOfLoops
{
@synchronized (self) {
return _numberOfLoops;
}
}
- (void)setNumberOfLoops:(NSInteger)loops
{
@synchronized (self) {
_numberOfLoops = loops;
_currentLoop = 0;
}
}
- (NSTimeInterval)duration
{
@synchronized (self) {
return [_player duration];
}
}
- (void)setCurrentTime:(NSTimeInterval)newTime
{
@synchronized (self) {
[_player setCurrentTime:newTime];
}
}
- (NSTimeInterval)currentTime
{
@synchronized (self) {
return [_player currentTime];
}
}
- (void)sound:(NSSound *)sound didFinishPlaying:(BOOL)finishedPlaying
{
@synchronized (self) {
if (sound == _player) {
const BOOL notifyDelegate = [_delegate respondsToSelector:@selector(audioPlayerDidFinishPlaying:successfully:)];
_isPaused = NO;
if (finishedPlaying) {
_currentLoop++;
if (_currentLoop <= _numberOfLoops || _numberOfLoops < 0) {
[_player play];
} else if (notifyDelegate) {
[_delegate audioPlayerDidFinishPlaying:self successfully:YES];
}
// According to the docs audioPlayerDidFinishPlaying should only be called if the audio finished playing
// See: http://developer.apple.com/library/mac/#documentation/AVFoundation/Reference/AVAudioPlayerDelegateProtocolReference/Reference/Reference.html#//apple_ref/doc/uid/TP40008068
// } else {
// [_delegate audioPlayerDidFinishPlaying:self successfully:NO];
}
}
}
}
@end
================================================
FILE: Examples/Chameleon Demo/Chameleon/AVFoundation/Classes/AVAudioSession.h
================================================
/*
* Copyright (c) 2011, The Iconfactory. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of The Iconfactory nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE ICONFACTORY BE LIABLE FOR ANY DIRECT,
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
* OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#import
extern NSString *const AVAudioSessionCategoryAmbient;
extern NSString *const AVAudioSessionCategorySoloAmbient;
extern NSString *const AVAudioSessionCategoryPlayback;
extern NSString *const AVAudioSessionCategoryRecord;
extern NSString *const AVAudioSessionCategoryPlayAndRecord;
extern NSString *const AVAudioSessionCategoryAudioProcessing;
@interface AVAudioSession : NSObject {
}
+ (id)sharedInstance;
- (BOOL)setActive:(BOOL)beActive error:(NSError**)outError;
- (BOOL)setCategory:(NSString*)theCategory error:(NSError**)outError;
@end
================================================
FILE: Examples/Chameleon Demo/Chameleon/AVFoundation/Classes/AVAudioSession.m
================================================
/*
* Copyright (c) 2011, The Iconfactory. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of The Iconfactory nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE ICONFACTORY BE LIABLE FOR ANY DIRECT,
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
* OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#import "AVAudioSession.h"
NSString *const AVAudioSessionCategoryAmbient = @"AVAudioSessionCategoryAmbient";
NSString *const AVAudioSessionCategorySoloAmbient = @"AVAudioSessionCategorySoloAmbient";
NSString *const AVAudioSessionCategoryPlayback = @"AVAudioSessionCategoryPlayback";
NSString *const AVAudioSessionCategoryRecord = @"AVAudioSessionCategoryRecord";
NSString *const AVAudioSessionCategoryPlayAndRecord = @"AVAudioSessionCategoryPlayAndRecord";
NSString *const AVAudioSessionCategoryAudioProcessing = @"AVAudioSessionCategoryAudioProcessing";
@implementation AVAudioSession
+ (id)sharedInstance
{
return nil;
}
- (BOOL)setActive:(BOOL)beActive error:(NSError**)outError
{
return NO;
}
- (BOOL)setCategory:(NSString*)theCategory error:(NSError**)outError
{
return NO;
}
@end
================================================
FILE: Examples/Chameleon Demo/Chameleon/AVFoundation/Classes/AVFoundation.h
================================================
/*
* Copyright (c) 2011, The Iconfactory. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of The Iconfactory nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE ICONFACTORY BE LIABLE FOR ANY DIRECT,
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
* OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
// This probably doesn't belong here, but it's good enough for now
enum {
kSystemSoundID_Vibrate = 0x0
};
#import "AVAudioPlayer.h"
#import "AVAudioSession.h"
================================================
FILE: Examples/Chameleon Demo/Chameleon/AVFoundation/Info.plist
================================================
CFBundleDevelopmentRegionEnglishCFBundleExecutable${EXECUTABLE_NAME}CFBundleName${PRODUCT_NAME}CFBundleIconFileCFBundleIdentifierorg.chameleonproject.AVFoundationCFBundleInfoDictionaryVersion6.0CFBundlePackageTypeFMWKCFBundleSignature????CFBundleVersion1CFBundleShortVersionString1.0NSPrincipalClass
================================================
FILE: Examples/Chameleon Demo/Chameleon/AddressBookUI/AddressBookUI.xcodeproj/project.pbxproj
================================================
// !$*UTF8*$!
{
archiveVersion = 1;
classes = {
};
objectVersion = 46;
objects = {
/* Begin PBXBuildFile section */
143B578F1230357600F43562 /* ABUnknownPersonViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 14FB132C12302FD900B615ED /* ABUnknownPersonViewController.m */; };
143B57941230357C00F43562 /* UIKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 14FB133A1230307C00B615ED /* UIKit.framework */; };
14C25EF31211ED0400622309 /* AddressBookUI.h in Headers */ = {isa = PBXBuildFile; fileRef = 14C25EF21211ED0400622309 /* AddressBookUI.h */; settings = {ATTRIBUTES = (Public, ); }; };
14EFB1BB1211DB5300D19B0C /* Cocoa.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 14EFB1BA1211DB5300D19B0C /* Cocoa.framework */; };
14FB132D12302FD900B615ED /* ABUnknownPersonViewController.h in Headers */ = {isa = PBXBuildFile; fileRef = 14FB132B12302FD900B615ED /* ABUnknownPersonViewController.h */; settings = {ATTRIBUTES = (Public, ); }; };
78CB48EA133ABCEB008636DA /* AddressBook.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 78CB48E9133ABCEB008636DA /* AddressBook.framework */; };
/* End PBXBuildFile section */
/* Begin PBXContainerItemProxy section */
14FB13391230307C00B615ED /* PBXContainerItemProxy */ = {
isa = PBXContainerItemProxy;
containerPortal = 14FB13351230307C00B615ED /* UIKit.xcodeproj */;
proxyType = 2;
remoteGlobalIDString = 8DC2EF5B0486A6940098B216;
remoteInfo = UIKit;
};
14FB133C1230308E00B615ED /* PBXContainerItemProxy */ = {
isa = PBXContainerItemProxy;
containerPortal = 14FB13351230307C00B615ED /* UIKit.xcodeproj */;
proxyType = 1;
remoteGlobalIDString = 8DC2EF4F0486A6940098B216;
remoteInfo = UIKit;
};
/* End PBXContainerItemProxy section */
/* Begin PBXFileReference section */
0867D69BFE84028FC02AAC07 /* Foundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Foundation.framework; path = /System/Library/Frameworks/Foundation.framework; sourceTree = ""; };
0867D6A5FE840307C02AAC07 /* AppKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = AppKit.framework; path = /System/Library/Frameworks/AppKit.framework; sourceTree = ""; };
14C25EF21211ED0400622309 /* AddressBookUI.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = AddressBookUI.h; path = Classes/AddressBookUI.h; sourceTree = ""; };
14EFB1BA1211DB5300D19B0C /* Cocoa.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Cocoa.framework; path = System/Library/Frameworks/Cocoa.framework; sourceTree = SDKROOT; };
14FB132512302F8700B615ED /* AddressBookUI_Prefix.pch */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AddressBookUI_Prefix.pch; sourceTree = ""; };
14FB132B12302FD900B615ED /* ABUnknownPersonViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = ABUnknownPersonViewController.h; path = Classes/ABUnknownPersonViewController.h; sourceTree = ""; };
14FB132C12302FD900B615ED /* ABUnknownPersonViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = ABUnknownPersonViewController.m; path = Classes/ABUnknownPersonViewController.m; sourceTree = ""; };
14FB13351230307C00B615ED /* UIKit.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = UIKit.xcodeproj; path = ../UIKit/UIKit.xcodeproj; sourceTree = SOURCE_ROOT; };
78CB48E9133ABCEB008636DA /* AddressBook.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = AddressBook.framework; path = System/Library/Frameworks/AddressBook.framework; sourceTree = SDKROOT; };
8DC2EF5A0486A6940098B216 /* Info.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; };
8DC2EF5B0486A6940098B216 /* AddressBookUI.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = AddressBookUI.framework; sourceTree = BUILT_PRODUCTS_DIR; };
/* End PBXFileReference section */
/* Begin PBXFrameworksBuildPhase section */
8DC2EF560486A6940098B216 /* Frameworks */ = {
isa = PBXFrameworksBuildPhase;
buildActionMask = 2147483647;
files = (
78CB48EA133ABCEB008636DA /* AddressBook.framework in Frameworks */,
143B57941230357C00F43562 /* UIKit.framework in Frameworks */,
14EFB1BB1211DB5300D19B0C /* Cocoa.framework in Frameworks */,
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXFrameworksBuildPhase section */
/* Begin PBXGroup section */
034768DFFF38A50411DB9C8B /* Products */ = {
isa = PBXGroup;
children = (
8DC2EF5B0486A6940098B216 /* AddressBookUI.framework */,
);
name = Products;
sourceTree = "";
};
0867D691FE84028FC02AAC07 /* UIKit */ = {
isa = PBXGroup;
children = (
14FB13351230307C00B615ED /* UIKit.xcodeproj */,
08FB77AEFE84172EC02AAC07 /* Classes */,
089C1665FE841158C02AAC07 /* Resources */,
32C88DFF0371C24200C91783 /* Other Sources */,
0867D69AFE84028FC02AAC07 /* External Frameworks and Libraries */,
034768DFFF38A50411DB9C8B /* Products */,
);
name = UIKit;
sourceTree = "";
};
0867D69AFE84028FC02AAC07 /* External Frameworks and Libraries */ = {
isa = PBXGroup;
children = (
78CB48E9133ABCEB008636DA /* AddressBook.framework */,
0867D6A5FE840307C02AAC07 /* AppKit.framework */,
0867D69BFE84028FC02AAC07 /* Foundation.framework */,
14EFB1BA1211DB5300D19B0C /* Cocoa.framework */,
);
name = "External Frameworks and Libraries";
sourceTree = "";
};
089C1665FE841158C02AAC07 /* Resources */ = {
isa = PBXGroup;
children = (
8DC2EF5A0486A6940098B216 /* Info.plist */,
);
name = Resources;
sourceTree = "";
};
08FB77AEFE84172EC02AAC07 /* Classes */ = {
isa = PBXGroup;
children = (
14C25EF21211ED0400622309 /* AddressBookUI.h */,
14FB132B12302FD900B615ED /* ABUnknownPersonViewController.h */,
14FB132C12302FD900B615ED /* ABUnknownPersonViewController.m */,
);
name = Classes;
sourceTree = "";
};
14FB13361230307C00B615ED /* Products */ = {
isa = PBXGroup;
children = (
14FB133A1230307C00B615ED /* UIKit.framework */,
);
name = Products;
sourceTree = "";
};
32C88DFF0371C24200C91783 /* Other Sources */ = {
isa = PBXGroup;
children = (
14FB132512302F8700B615ED /* AddressBookUI_Prefix.pch */,
);
name = "Other Sources";
sourceTree = "";
};
/* End PBXGroup section */
/* Begin PBXHeadersBuildPhase section */
8DC2EF500486A6940098B216 /* Headers */ = {
isa = PBXHeadersBuildPhase;
buildActionMask = 2147483647;
files = (
14C25EF31211ED0400622309 /* AddressBookUI.h in Headers */,
14FB132D12302FD900B615ED /* ABUnknownPersonViewController.h in Headers */,
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXHeadersBuildPhase section */
/* Begin PBXNativeTarget section */
8DC2EF4F0486A6940098B216 /* AddressBookUI */ = {
isa = PBXNativeTarget;
buildConfigurationList = 1DEB91AD08733DA50010E9CD /* Build configuration list for PBXNativeTarget "AddressBookUI" */;
buildPhases = (
8DC2EF500486A6940098B216 /* Headers */,
8DC2EF520486A6940098B216 /* Resources */,
8DC2EF540486A6940098B216 /* Sources */,
8DC2EF560486A6940098B216 /* Frameworks */,
);
buildRules = (
);
dependencies = (
14FB133D1230308E00B615ED /* PBXTargetDependency */,
);
name = AddressBookUI;
productInstallPath = "$(HOME)/Library/Frameworks";
productName = UIKit;
productReference = 8DC2EF5B0486A6940098B216 /* AddressBookUI.framework */;
productType = "com.apple.product-type.framework";
};
/* End PBXNativeTarget section */
/* Begin PBXProject section */
0867D690FE84028FC02AAC07 /* Project object */ = {
isa = PBXProject;
attributes = {
LastUpgradeCheck = 0510;
};
buildConfigurationList = 1DEB91B108733DA50010E9CD /* Build configuration list for PBXProject "AddressBookUI" */;
compatibilityVersion = "Xcode 3.2";
developmentRegion = English;
hasScannedForEncodings = 1;
knownRegions = (
English,
Japanese,
French,
German,
);
mainGroup = 0867D691FE84028FC02AAC07 /* UIKit */;
productRefGroup = 034768DFFF38A50411DB9C8B /* Products */;
projectDirPath = "";
projectReferences = (
{
ProductGroup = 14FB13361230307C00B615ED /* Products */;
ProjectRef = 14FB13351230307C00B615ED /* UIKit.xcodeproj */;
},
);
projectRoot = "";
targets = (
8DC2EF4F0486A6940098B216 /* AddressBookUI */,
);
};
/* End PBXProject section */
/* Begin PBXReferenceProxy section */
14FB133A1230307C00B615ED /* UIKit.framework */ = {
isa = PBXReferenceProxy;
fileType = wrapper.framework;
path = UIKit.framework;
remoteRef = 14FB13391230307C00B615ED /* PBXContainerItemProxy */;
sourceTree = BUILT_PRODUCTS_DIR;
};
/* End PBXReferenceProxy section */
/* Begin PBXResourcesBuildPhase section */
8DC2EF520486A6940098B216 /* Resources */ = {
isa = PBXResourcesBuildPhase;
buildActionMask = 2147483647;
files = (
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXResourcesBuildPhase section */
/* Begin PBXSourcesBuildPhase section */
8DC2EF540486A6940098B216 /* Sources */ = {
isa = PBXSourcesBuildPhase;
buildActionMask = 2147483647;
files = (
143B578F1230357600F43562 /* ABUnknownPersonViewController.m in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXSourcesBuildPhase section */
/* Begin PBXTargetDependency section */
14FB133D1230308E00B615ED /* PBXTargetDependency */ = {
isa = PBXTargetDependency;
name = UIKit;
targetProxy = 14FB133C1230308E00B615ED /* PBXContainerItemProxy */;
};
/* End PBXTargetDependency section */
/* Begin XCBuildConfiguration section */
1DEB91AE08733DA50010E9CD /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
COPY_PHASE_STRIP = NO;
DYLIB_COMPATIBILITY_VERSION = 1;
DYLIB_CURRENT_VERSION = 1;
FRAMEWORK_VERSION = A;
GCC_DYNAMIC_NO_PIC = NO;
GCC_ENABLE_FIX_AND_CONTINUE = YES;
GCC_MODEL_TUNING = G5;
GCC_OPTIMIZATION_LEVEL = 0;
GCC_PRECOMPILE_PREFIX_HEADER = YES;
GCC_PREFIX_HEADER = AddressBookUI_Prefix.pch;
INFOPLIST_FILE = Info.plist;
INSTALL_PATH = "@executable_path/../Frameworks";
PRODUCT_NAME = AddressBookUI;
SYMROOT = ../build;
VALID_ARCHS = "i386 x86_64";
WRAPPER_EXTENSION = framework;
};
name = Debug;
};
1DEB91AF08733DA50010E9CD /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
DYLIB_COMPATIBILITY_VERSION = 1;
DYLIB_CURRENT_VERSION = 1;
FRAMEWORK_VERSION = A;
GCC_MODEL_TUNING = G5;
GCC_PRECOMPILE_PREFIX_HEADER = YES;
GCC_PREFIX_HEADER = AddressBookUI_Prefix.pch;
INFOPLIST_FILE = Info.plist;
INSTALL_PATH = "@executable_path/../Frameworks";
PRODUCT_NAME = AddressBookUI;
SYMROOT = ../build;
VALID_ARCHS = "i386 x86_64";
WRAPPER_EXTENSION = framework;
};
name = Release;
};
1DEB91B208733DA50010E9CD /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
GCC_C_LANGUAGE_STANDARD = gnu99;
GCC_OPTIMIZATION_LEVEL = 0;
GCC_WARN_ABOUT_RETURN_TYPE = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
ONLY_ACTIVE_ARCH = YES;
PREBINDING = NO;
SDKROOT = macosx;
};
name = Debug;
};
1DEB91B308733DA50010E9CD /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
GCC_C_LANGUAGE_STANDARD = gnu99;
GCC_WARN_ABOUT_RETURN_TYPE = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
PREBINDING = NO;
SDKROOT = macosx;
};
name = Release;
};
/* End XCBuildConfiguration section */
/* Begin XCConfigurationList section */
1DEB91AD08733DA50010E9CD /* Build configuration list for PBXNativeTarget "AddressBookUI" */ = {
isa = XCConfigurationList;
buildConfigurations = (
1DEB91AE08733DA50010E9CD /* Debug */,
1DEB91AF08733DA50010E9CD /* Release */,
);
defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release;
};
1DEB91B108733DA50010E9CD /* Build configuration list for PBXProject "AddressBookUI" */ = {
isa = XCConfigurationList;
buildConfigurations = (
1DEB91B208733DA50010E9CD /* Debug */,
1DEB91B308733DA50010E9CD /* Release */,
);
defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release;
};
/* End XCConfigurationList section */
};
rootObject = 0867D690FE84028FC02AAC07 /* Project object */;
}
================================================
FILE: Examples/Chameleon Demo/Chameleon/AddressBookUI/AddressBookUI.xcodeproj/project.xcworkspace/contents.xcworkspacedata
================================================
================================================
FILE: Examples/Chameleon Demo/Chameleon/AddressBookUI/AddressBookUI_Prefix.pch
================================================
/*
* Copyright (c) 2011, The Iconfactory. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of The Iconfactory nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE ICONFACTORY BE LIABLE FOR ANY DIRECT,
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
* OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#ifdef __OBJC__
#import
#endif
================================================
FILE: Examples/Chameleon Demo/Chameleon/AddressBookUI/Classes/ABUnknownPersonViewController.h
================================================
/*
* Copyright (c) 2011, The Iconfactory. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of The Iconfactory nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE ICONFACTORY BE LIABLE FOR ANY DIRECT,
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
* OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#import
typedef id ABRecordRef; // is iOS-only
@interface ABUnknownPersonViewController : NSObject {
ABRecordRef _displayedPerson;
}
@property (nonatomic, retain) ABRecordRef displayedPerson;
@end
================================================
FILE: Examples/Chameleon Demo/Chameleon/AddressBookUI/Classes/ABUnknownPersonViewController.m
================================================
/*
* Copyright (c) 2011, The Iconfactory. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of The Iconfactory nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE ICONFACTORY BE LIABLE FOR ANY DIRECT,
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
* OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#import "ABUnknownPersonViewController.h"
@implementation ABUnknownPersonViewController
@synthesize displayedPerson = _displayedPerson;
@end
================================================
FILE: Examples/Chameleon Demo/Chameleon/AddressBookUI/Classes/AddressBookUI.h
================================================
/*
* Copyright (c) 2011, The Iconfactory. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of The Iconfactory nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE ICONFACTORY BE LIABLE FOR ANY DIRECT,
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
* OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#import "ABUnknownPersonViewController.h"
================================================
FILE: Examples/Chameleon Demo/Chameleon/AddressBookUI/Info.plist
================================================
CFBundleDevelopmentRegionEnglishCFBundleExecutable${EXECUTABLE_NAME}CFBundleIconFileCFBundleIdentifierorg.chameleonproject.AddressBookUICFBundleInfoDictionaryVersion6.0CFBundleName${PRODUCT_NAME}CFBundlePackageTypeFMWKCFBundleShortVersionString1.0CFBundleSignature????CFBundleVersion1NSPrincipalClass
================================================
FILE: Examples/Chameleon Demo/Chameleon/AssetsLibrary/AssetsLibrary.xcodeproj/project.pbxproj
================================================
// !$*UTF8*$!
{
archiveVersion = 1;
classes = {
};
objectVersion = 46;
objects = {
/* Begin PBXBuildFile section */
144E375F14D7559600A640AE /* ALAsset.h in Headers */ = {isa = PBXBuildFile; fileRef = 144E375D14D7559600A640AE /* ALAsset.h */; settings = {ATTRIBUTES = (Public, ); }; };
144E376014D7559600A640AE /* ALAsset.m in Sources */ = {isa = PBXBuildFile; fileRef = 144E375E14D7559600A640AE /* ALAsset.m */; };
144E376314D755E300A640AE /* ALAssetRepresentation.h in Headers */ = {isa = PBXBuildFile; fileRef = 144E376114D755E300A640AE /* ALAssetRepresentation.h */; settings = {ATTRIBUTES = (Public, ); }; };
144E376414D755E300A640AE /* ALAssetRepresentation.m in Sources */ = {isa = PBXBuildFile; fileRef = 144E376214D755E300A640AE /* ALAssetRepresentation.m */; };
144E376714D755FE00A640AE /* ALAssetsFilter.h in Headers */ = {isa = PBXBuildFile; fileRef = 144E376514D755FE00A640AE /* ALAssetsFilter.h */; settings = {ATTRIBUTES = (Public, ); }; };
144E376814D755FE00A640AE /* ALAssetsFilter.m in Sources */ = {isa = PBXBuildFile; fileRef = 144E376614D755FE00A640AE /* ALAssetsFilter.m */; };
144E376B14D7561600A640AE /* ALAssetsGroup.h in Headers */ = {isa = PBXBuildFile; fileRef = 144E376914D7561600A640AE /* ALAssetsGroup.h */; settings = {ATTRIBUTES = (Public, ); }; };
144E376C14D7561600A640AE /* ALAssetsGroup.m in Sources */ = {isa = PBXBuildFile; fileRef = 144E376A14D7561600A640AE /* ALAssetsGroup.m */; };
14EFB1A11211DADE00D19B0C /* ALAssetsLibrary.h in Headers */ = {isa = PBXBuildFile; fileRef = 14EFB19F1211DADE00D19B0C /* ALAssetsLibrary.h */; settings = {ATTRIBUTES = (Public, ); }; };
14EFB1A21211DADE00D19B0C /* ALAssetsLibrary.m in Sources */ = {isa = PBXBuildFile; fileRef = 14EFB1A01211DADE00D19B0C /* ALAssetsLibrary.m */; };
14EFB1A81211DB0B00D19B0C /* AssetsLibrary.h in Headers */ = {isa = PBXBuildFile; fileRef = 14EFB1A71211DB0B00D19B0C /* AssetsLibrary.h */; settings = {ATTRIBUTES = (Public, ); }; };
14EFB1BB1211DB5300D19B0C /* Cocoa.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 14EFB1BA1211DB5300D19B0C /* Cocoa.framework */; };
/* End PBXBuildFile section */
/* Begin PBXFileReference section */
0867D69BFE84028FC02AAC07 /* Foundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Foundation.framework; path = /System/Library/Frameworks/Foundation.framework; sourceTree = ""; };
0867D6A5FE840307C02AAC07 /* AppKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = AppKit.framework; path = /System/Library/Frameworks/AppKit.framework; sourceTree = ""; };
144E375D14D7559600A640AE /* ALAsset.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = ALAsset.h; path = Classes/ALAsset.h; sourceTree = ""; };
144E375E14D7559600A640AE /* ALAsset.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = ALAsset.m; path = Classes/ALAsset.m; sourceTree = ""; };
144E376114D755E300A640AE /* ALAssetRepresentation.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = ALAssetRepresentation.h; path = Classes/ALAssetRepresentation.h; sourceTree = ""; };
144E376214D755E300A640AE /* ALAssetRepresentation.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = ALAssetRepresentation.m; path = Classes/ALAssetRepresentation.m; sourceTree = ""; };
144E376514D755FE00A640AE /* ALAssetsFilter.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = ALAssetsFilter.h; path = Classes/ALAssetsFilter.h; sourceTree = ""; };
144E376614D755FE00A640AE /* ALAssetsFilter.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = ALAssetsFilter.m; path = Classes/ALAssetsFilter.m; sourceTree = ""; };
144E376914D7561600A640AE /* ALAssetsGroup.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = ALAssetsGroup.h; path = Classes/ALAssetsGroup.h; sourceTree = ""; };
144E376A14D7561600A640AE /* ALAssetsGroup.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = ALAssetsGroup.m; path = Classes/ALAssetsGroup.m; sourceTree = ""; };
146B1C8C1211D9DA002D85C3 /* AssetsLibrary_Prefix.pch */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AssetsLibrary_Prefix.pch; sourceTree = ""; };
14EFB19F1211DADE00D19B0C /* ALAssetsLibrary.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = ALAssetsLibrary.h; path = Classes/ALAssetsLibrary.h; sourceTree = ""; };
14EFB1A01211DADE00D19B0C /* ALAssetsLibrary.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = ALAssetsLibrary.m; path = Classes/ALAssetsLibrary.m; sourceTree = ""; };
14EFB1A71211DB0B00D19B0C /* AssetsLibrary.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = AssetsLibrary.h; path = Classes/AssetsLibrary.h; sourceTree = ""; };
14EFB1BA1211DB5300D19B0C /* Cocoa.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Cocoa.framework; path = System/Library/Frameworks/Cocoa.framework; sourceTree = SDKROOT; };
8DC2EF5A0486A6940098B216 /* Info.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; };
8DC2EF5B0486A6940098B216 /* AssetsLibrary.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = AssetsLibrary.framework; sourceTree = BUILT_PRODUCTS_DIR; };
/* End PBXFileReference section */
/* Begin PBXFrameworksBuildPhase section */
8DC2EF560486A6940098B216 /* Frameworks */ = {
isa = PBXFrameworksBuildPhase;
buildActionMask = 2147483647;
files = (
14EFB1BB1211DB5300D19B0C /* Cocoa.framework in Frameworks */,
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXFrameworksBuildPhase section */
/* Begin PBXGroup section */
034768DFFF38A50411DB9C8B /* Products */ = {
isa = PBXGroup;
children = (
8DC2EF5B0486A6940098B216 /* AssetsLibrary.framework */,
);
name = Products;
sourceTree = "";
};
0867D691FE84028FC02AAC07 /* UIKit */ = {
isa = PBXGroup;
children = (
08FB77AEFE84172EC02AAC07 /* Classes */,
089C1665FE841158C02AAC07 /* Resources */,
32C88DFF0371C24200C91783 /* Other Sources */,
0867D69AFE84028FC02AAC07 /* External Frameworks and Libraries */,
034768DFFF38A50411DB9C8B /* Products */,
);
name = UIKit;
sourceTree = "";
};
0867D69AFE84028FC02AAC07 /* External Frameworks and Libraries */ = {
isa = PBXGroup;
children = (
0867D6A5FE840307C02AAC07 /* AppKit.framework */,
0867D69BFE84028FC02AAC07 /* Foundation.framework */,
14EFB1BA1211DB5300D19B0C /* Cocoa.framework */,
);
name = "External Frameworks and Libraries";
sourceTree = "";
};
089C1665FE841158C02AAC07 /* Resources */ = {
isa = PBXGroup;
children = (
8DC2EF5A0486A6940098B216 /* Info.plist */,
);
name = Resources;
sourceTree = "";
};
08FB77AEFE84172EC02AAC07 /* Classes */ = {
isa = PBXGroup;
children = (
144E375D14D7559600A640AE /* ALAsset.h */,
144E375E14D7559600A640AE /* ALAsset.m */,
144E376114D755E300A640AE /* ALAssetRepresentation.h */,
144E376214D755E300A640AE /* ALAssetRepresentation.m */,
144E376514D755FE00A640AE /* ALAssetsFilter.h */,
144E376614D755FE00A640AE /* ALAssetsFilter.m */,
144E376914D7561600A640AE /* ALAssetsGroup.h */,
144E376A14D7561600A640AE /* ALAssetsGroup.m */,
14EFB19F1211DADE00D19B0C /* ALAssetsLibrary.h */,
14EFB1A01211DADE00D19B0C /* ALAssetsLibrary.m */,
14EFB1A71211DB0B00D19B0C /* AssetsLibrary.h */,
);
name = Classes;
sourceTree = "";
};
32C88DFF0371C24200C91783 /* Other Sources */ = {
isa = PBXGroup;
children = (
146B1C8C1211D9DA002D85C3 /* AssetsLibrary_Prefix.pch */,
);
name = "Other Sources";
sourceTree = "";
};
/* End PBXGroup section */
/* Begin PBXHeadersBuildPhase section */
8DC2EF500486A6940098B216 /* Headers */ = {
isa = PBXHeadersBuildPhase;
buildActionMask = 2147483647;
files = (
14EFB1A11211DADE00D19B0C /* ALAssetsLibrary.h in Headers */,
14EFB1A81211DB0B00D19B0C /* AssetsLibrary.h in Headers */,
144E375F14D7559600A640AE /* ALAsset.h in Headers */,
144E376314D755E300A640AE /* ALAssetRepresentation.h in Headers */,
144E376714D755FE00A640AE /* ALAssetsFilter.h in Headers */,
144E376B14D7561600A640AE /* ALAssetsGroup.h in Headers */,
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXHeadersBuildPhase section */
/* Begin PBXNativeTarget section */
8DC2EF4F0486A6940098B216 /* AssetsLibrary */ = {
isa = PBXNativeTarget;
buildConfigurationList = 1DEB91AD08733DA50010E9CD /* Build configuration list for PBXNativeTarget "AssetsLibrary" */;
buildPhases = (
8DC2EF500486A6940098B216 /* Headers */,
8DC2EF520486A6940098B216 /* Resources */,
8DC2EF540486A6940098B216 /* Sources */,
8DC2EF560486A6940098B216 /* Frameworks */,
);
buildRules = (
);
dependencies = (
);
name = AssetsLibrary;
productInstallPath = "$(HOME)/Library/Frameworks";
productName = UIKit;
productReference = 8DC2EF5B0486A6940098B216 /* AssetsLibrary.framework */;
productType = "com.apple.product-type.framework";
};
/* End PBXNativeTarget section */
/* Begin PBXProject section */
0867D690FE84028FC02AAC07 /* Project object */ = {
isa = PBXProject;
attributes = {
LastUpgradeCheck = 0510;
};
buildConfigurationList = 1DEB91B108733DA50010E9CD /* Build configuration list for PBXProject "AssetsLibrary" */;
compatibilityVersion = "Xcode 3.2";
developmentRegion = English;
hasScannedForEncodings = 1;
knownRegions = (
English,
Japanese,
French,
German,
);
mainGroup = 0867D691FE84028FC02AAC07 /* UIKit */;
productRefGroup = 034768DFFF38A50411DB9C8B /* Products */;
projectDirPath = "";
projectRoot = "";
targets = (
8DC2EF4F0486A6940098B216 /* AssetsLibrary */,
);
};
/* End PBXProject section */
/* Begin PBXResourcesBuildPhase section */
8DC2EF520486A6940098B216 /* Resources */ = {
isa = PBXResourcesBuildPhase;
buildActionMask = 2147483647;
files = (
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXResourcesBuildPhase section */
/* Begin PBXSourcesBuildPhase section */
8DC2EF540486A6940098B216 /* Sources */ = {
isa = PBXSourcesBuildPhase;
buildActionMask = 2147483647;
files = (
14EFB1A21211DADE00D19B0C /* ALAssetsLibrary.m in Sources */,
144E376014D7559600A640AE /* ALAsset.m in Sources */,
144E376414D755E300A640AE /* ALAssetRepresentation.m in Sources */,
144E376814D755FE00A640AE /* ALAssetsFilter.m in Sources */,
144E376C14D7561600A640AE /* ALAssetsGroup.m in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXSourcesBuildPhase section */
/* Begin XCBuildConfiguration section */
1DEB91AE08733DA50010E9CD /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
COMBINE_HIDPI_IMAGES = NO;
COPY_PHASE_STRIP = NO;
DYLIB_COMPATIBILITY_VERSION = 1;
DYLIB_CURRENT_VERSION = 1;
FRAMEWORK_VERSION = A;
GCC_DYNAMIC_NO_PIC = NO;
GCC_MODEL_TUNING = G5;
GCC_OPTIMIZATION_LEVEL = 0;
GCC_PRECOMPILE_PREFIX_HEADER = YES;
GCC_PREFIX_HEADER = AssetsLibrary_Prefix.pch;
INFOPLIST_FILE = Info.plist;
INSTALL_PATH = "@executable_path/../Frameworks";
PRODUCT_NAME = AssetsLibrary;
SYMROOT = ../build;
WRAPPER_EXTENSION = framework;
};
name = Debug;
};
1DEB91AF08733DA50010E9CD /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
COMBINE_HIDPI_IMAGES = NO;
DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
DYLIB_COMPATIBILITY_VERSION = 1;
DYLIB_CURRENT_VERSION = 1;
FRAMEWORK_VERSION = A;
GCC_MODEL_TUNING = G5;
GCC_PRECOMPILE_PREFIX_HEADER = YES;
GCC_PREFIX_HEADER = AssetsLibrary_Prefix.pch;
INFOPLIST_FILE = Info.plist;
INSTALL_PATH = "@executable_path/../Frameworks";
PRODUCT_NAME = AssetsLibrary;
SYMROOT = ../build;
WRAPPER_EXTENSION = framework;
};
name = Release;
};
1DEB91B208733DA50010E9CD /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
GCC_C_LANGUAGE_STANDARD = gnu99;
GCC_OPTIMIZATION_LEVEL = 0;
GCC_WARN_ABOUT_MISSING_PROTOTYPES = YES;
GCC_WARN_ABOUT_RETURN_TYPE = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
MACOSX_DEPLOYMENT_TARGET = 10.7;
ONLY_ACTIVE_ARCH = YES;
SDKROOT = macosx;
};
name = Debug;
};
1DEB91B308733DA50010E9CD /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
CODE_SIGN_IDENTITY = "Developer ID Application: The Iconfactory";
GCC_C_LANGUAGE_STANDARD = gnu99;
GCC_WARN_ABOUT_MISSING_PROTOTYPES = YES;
GCC_WARN_ABOUT_RETURN_TYPE = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
MACOSX_DEPLOYMENT_TARGET = 10.7;
PROVISIONING_PROFILE = "";
SDKROOT = macosx;
};
name = Release;
};
/* End XCBuildConfiguration section */
/* Begin XCConfigurationList section */
1DEB91AD08733DA50010E9CD /* Build configuration list for PBXNativeTarget "AssetsLibrary" */ = {
isa = XCConfigurationList;
buildConfigurations = (
1DEB91AE08733DA50010E9CD /* Debug */,
1DEB91AF08733DA50010E9CD /* Release */,
);
defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release;
};
1DEB91B108733DA50010E9CD /* Build configuration list for PBXProject "AssetsLibrary" */ = {
isa = XCConfigurationList;
buildConfigurations = (
1DEB91B208733DA50010E9CD /* Debug */,
1DEB91B308733DA50010E9CD /* Release */,
);
defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release;
};
/* End XCConfigurationList section */
};
rootObject = 0867D690FE84028FC02AAC07 /* Project object */;
}
================================================
FILE: Examples/Chameleon Demo/Chameleon/AssetsLibrary/AssetsLibrary_Prefix.pch
================================================
/*
* Copyright (c) 2012, The Iconfactory. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of The Iconfactory nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE ICONFACTORY BE LIABLE FOR ANY DIRECT,
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
* OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#ifdef __OBJC__
#import
#endif
================================================
FILE: Examples/Chameleon Demo/Chameleon/AssetsLibrary/Classes/ALAsset.h
================================================
/*
* Copyright (c) 2012, The Iconfactory. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of The Iconfactory nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE ICONFACTORY BE LIABLE FOR ANY DIRECT,
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
* OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#import
@interface ALAsset : NSObject
@end
================================================
FILE: Examples/Chameleon Demo/Chameleon/AssetsLibrary/Classes/ALAsset.m
================================================
/*
* Copyright (c) 2012, The Iconfactory. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of The Iconfactory nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE ICONFACTORY BE LIABLE FOR ANY DIRECT,
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
* OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#import "ALAsset.h"
@implementation ALAsset
@end
================================================
FILE: Examples/Chameleon Demo/Chameleon/AssetsLibrary/Classes/ALAssetRepresentation.h
================================================
/*
* Copyright (c) 2012, The Iconfactory. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of The Iconfactory nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE ICONFACTORY BE LIABLE FOR ANY DIRECT,
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
* OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#import
@interface ALAssetRepresentation : NSObject
@end
================================================
FILE: Examples/Chameleon Demo/Chameleon/AssetsLibrary/Classes/ALAssetRepresentation.m
================================================
/*
* Copyright (c) 2012, The Iconfactory. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of The Iconfactory nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE ICONFACTORY BE LIABLE FOR ANY DIRECT,
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
* OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#import "ALAssetRepresentation.h"
@implementation ALAssetRepresentation
@end
================================================
FILE: Examples/Chameleon Demo/Chameleon/AssetsLibrary/Classes/ALAssetsFilter.h
================================================
/*
* Copyright (c) 2012, The Iconfactory. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of The Iconfactory nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE ICONFACTORY BE LIABLE FOR ANY DIRECT,
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
* OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#import
@interface ALAssetsFilter : NSObject
@end
================================================
FILE: Examples/Chameleon Demo/Chameleon/AssetsLibrary/Classes/ALAssetsFilter.m
================================================
/*
* Copyright (c) 2012, The Iconfactory. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of The Iconfactory nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE ICONFACTORY BE LIABLE FOR ANY DIRECT,
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
* OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#import "ALAssetsFilter.h"
@implementation ALAssetsFilter
@end
================================================
FILE: Examples/Chameleon Demo/Chameleon/AssetsLibrary/Classes/ALAssetsGroup.h
================================================
/*
* Copyright (c) 2012, The Iconfactory. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of The Iconfactory nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE ICONFACTORY BE LIABLE FOR ANY DIRECT,
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
* OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#import
@class ALAsset;
typedef void (^ALAssetsGroupEnumerationResultsBlock)(ALAsset *result, NSUInteger index, BOOL *stop);
@interface ALAssetsGroup : NSObject
@end
================================================
FILE: Examples/Chameleon Demo/Chameleon/AssetsLibrary/Classes/ALAssetsGroup.m
================================================
/*
* Copyright (c) 2012, The Iconfactory. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of The Iconfactory nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE ICONFACTORY BE LIABLE FOR ANY DIRECT,
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
* OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#import "ALAssetsGroup.h"
@implementation ALAssetsGroup
@end
================================================
FILE: Examples/Chameleon Demo/Chameleon/AssetsLibrary/Classes/ALAssetsLibrary.h
================================================
/*
* Copyright (c) 2012, The Iconfactory. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of The Iconfactory nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE ICONFACTORY BE LIABLE FOR ANY DIRECT,
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
* OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#import
@class ALAssetsGroup, ALAsset;
typedef NSUInteger ALAssetsGroupType;
enum {
ALAssetsGroupLibrary = (1 << 0),
ALAssetsGroupAlbum = (1 << 1),
ALAssetsGroupEvent = (1 << 2),
ALAssetsGroupFaces = (1 << 3),
ALAssetsGroupSavedPhotos = (1 << 4),
ALAssetsGroupPhotoStream = (1 << 5),
ALAssetsGroupAll = 0xFFFFFFFF,
};
typedef enum {
ALAssetOrientationUp,
ALAssetOrientationDown,
ALAssetOrientationLeft,
ALAssetOrientationRight,
ALAssetOrientationUpMirrored,
ALAssetOrientationDownMirrored,
ALAssetOrientationLeftMirrored,
ALAssetOrientationRightMirrored,
} ALAssetOrientation;
typedef void (^ALAssetsLibraryGroupsEnumerationResultsBlock)(ALAssetsGroup *group, BOOL *stop);
typedef void (^ALAssetsLibraryAssetForURLResultBlock)(ALAsset *asset);
typedef void (^ALAssetsLibraryWriteImageCompletionBlock)(NSURL *assetURL, NSError *error);
typedef void (^ALAssetsLibraryWriteVideoCompletionBlock)(NSURL *assetURL, NSError *error);
typedef void (^ALAssetsLibraryAccessFailureBlock)(NSError *error);
typedef void (^ALAssetsLibraryGroupResultBlock)(ALAssetsGroup *group);
enum {
ALAssetsLibraryUnknownError = -1,
ALAssetsLibraryWriteFailedError = -3300,
ALAssetsLibraryWriteBusyError = -3301,
ALAssetsLibraryWriteInvalidDataError = -3302,
ALAssetsLibraryWriteIncompatibleDataError = -3303,
ALAssetsLibraryWriteDataEncodingError = -3304,
ALAssetsLibraryWriteDiskSpaceError = -3305,
ALAssetsLibraryDataUnavailableError = -3310,
ALAssetsLibraryAccessUserDeniedError = -3311,
ALAssetsLibraryAccessGloballyDeniedError = -3312,
};
extern NSString *const ALAssetsLibraryErrorDomain;
extern NSString *const ALAssetsLibraryChangedNotification;
@interface ALAssetsLibrary : NSObject
- (void)writeImageDataToSavedPhotosAlbum:(NSData *)imageData metadata:(NSDictionary *)metadata completionBlock:(ALAssetsLibraryWriteImageCompletionBlock)completionBlock;
@end
================================================
FILE: Examples/Chameleon Demo/Chameleon/AssetsLibrary/Classes/ALAssetsLibrary.m
================================================
/*
* Copyright (c) 2012, The Iconfactory. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of The Iconfactory nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE ICONFACTORY BE LIABLE FOR ANY DIRECT,
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
* OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#import "ALAssetsLibrary.h"
#import
#import
NSString *const ALAssetsLibraryErrorDomain = @"ALAssetsLibraryErrorDomain";
NSString *const ALAssetsLibraryChangedNotification = @"ALAssetsLibraryChangedNotification";
static NSString *UTIForImageData(NSData *data)
{
NSString *type = nil;
CGImageSourceRef imageSource = CGImageSourceCreateWithData((CFDataRef)data, NULL);
if (imageSource) {
type = [[(NSString *)CGImageSourceGetType(imageSource) copy] autorelease];
CFRelease(imageSource);
}
return type;
}
@implementation ALAssetsLibrary
- (void)_deferredBlock:(void (^)(void))block
{
block();
}
- (void)writeImageDataToSavedPhotosAlbum:(NSData *)imageData metadata:(NSDictionary *)metadata completionBlock:(ALAssetsLibraryWriteImageCompletionBlock)completionBlock
{
// Chameleon's UIKit has an internal class called UIPhotosAlbum which was used to implement
// UIImageWriteToSavedPhotosAlbum(). Somehow it'd be nice if these things shared code, but I don't
// really want to make UIKit depend on having AssetsLibrary. Since I wasn't sure how to best accomplish
// that, it's just duplicated here for now in a slightly different way so that we can support writing
// any sort of image data and not just PNGs.
// The actual presentation of the save dialog and the saving itself is deferred because that's how
// my UIImageWriteToSavedPhotosAlbum() did it and ALAssetsLibrary says these methods are asynchronous
// so we'll pretend that's okay.
if (imageData) {
ALAssetsLibraryWriteImageCompletionBlock doneBlock = [completionBlock copy];
[self performSelector:@selector(_deferredBlock:) withObject:[[^{
NSError *error = nil;
NSSavePanel *panel = [NSSavePanel savePanel];
NSString *fileType = UTIForImageData(imageData);
if (fileType) {
[panel setAllowedFileTypes:[NSArray arrayWithObject:fileType]];
}
if (NSFileHandlingPanelOKButton == [panel runModal] && [panel URL]) {
[imageData writeToURL:[panel URL] options:NSDataWritingAtomic error:&error];
} else {
error = [NSError errorWithDomain:@"save panel cancelled" code:1 userInfo:nil];
}
if (doneBlock) {
doneBlock([panel URL], error);
[doneBlock release];
}
} copy] autorelease] afterDelay:0];
}
}
@end
================================================
FILE: Examples/Chameleon Demo/Chameleon/AssetsLibrary/Classes/AssetsLibrary.h
================================================
/*
* Copyright (c) 2012, The Iconfactory. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of The Iconfactory nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE ICONFACTORY BE LIABLE FOR ANY DIRECT,
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
* OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#import "ALAsset.h"
#import "ALAssetRepresentation.h"
#import "ALAssetsFilter.h"
#import "ALAssetsGroup.h"
#import "ALAssetsLibrary.h"
================================================
FILE: Examples/Chameleon Demo/Chameleon/AssetsLibrary/Info.plist
================================================
CFBundleDevelopmentRegionEnglishCFBundleExecutable${EXECUTABLE_NAME}CFBundleIconFileCFBundleIdentifierorg.chameleonproject.AssetsLibraryCFBundleInfoDictionaryVersion6.0CFBundleName${PRODUCT_NAME}CFBundlePackageTypeFMWKCFBundleShortVersionString1.0CFBundleSignature????CFBundleVersion1NSPrincipalClass
================================================
FILE: Examples/Chameleon Demo/Chameleon/LICENSE
================================================
Copyright (c) 2011, The Iconfactory. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
1. Redistributions of source code must retain the above copyright
notice, this list of conditions and the following disclaimer.
2. Redistributions in binary form must reproduce the above copyright notice,
this list of conditions and the following disclaimer in the documentation
and/or other materials provided with the distribution.
3. Neither the name of The Iconfactory nor the names of its contributors may
be used to endorse or promote products derived from this software without
specific prior written permission.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
DISCLAIMED. IN NO EVENT SHALL THE ICONFACTORY BE LIABLE FOR ANY DIRECT,
INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
================================================
FILE: Examples/Chameleon Demo/Chameleon/MediaPlayer/Classes/MPMediaPlayback.h
================================================
//
// MPMediaPlayback.h
// MediaPlayer
//
// Created by Michael Dales on 08/07/2011.
// Copyright 2011 Digital Flapjack Ltd. All rights reserved.
//
#import
@protocol MPMediaPlayback
- (void)play;
- (void)pause;
- (void)prepareToPlay;
- (void)stop;
@end
================================================
FILE: Examples/Chameleon Demo/Chameleon/MediaPlayer/Classes/MPMoviePlayerController.h
================================================
//
// MPMoviewPlayerController.h
// MediaPlayer
//
// Created by Michael Dales on 08/07/2011.
// Copyright 2011 Digital Flapjack Ltd. All rights reserved.
//
#import
#import "MPMediaPlayback.h"
#import
enum {
MPMovieLoadStateUnknown = 0,
MPMovieLoadStatePlayable = 1 << 0,
MPMovieLoadStatePlaythroughOK = 1 << 1,
MPMovieLoadStateStalled = 1 << 2,
};
typedef NSInteger MPMovieLoadState;
enum {
MPMovieControlStyleNone,
MPMovieControlStyleEmbedded,
MPMovieControlStyleFullscreen,
MPMovieControlStyleDefault = MPMovieControlStyleFullscreen
};
typedef NSInteger MPMovieControlStyle;
enum {
MPMovieFinishReasonPlaybackEnded,
MPMovieFinishReasonPlaybackError,
MPMovieFinishReasonUserExited
};
typedef NSInteger MPMovieFinishReason;
enum {
MPMovieSourceTypeUnknown,
MPMovieSourceTypeFile,
MPMovieSourceTypeStreaming
};
typedef NSInteger MPMovieSourceType;
enum {
MPMovieRepeatModeNone,
MPMovieRepeatModeOne
};
typedef NSInteger MPMovieRepeatMode;
enum {
MPMoviePlaybackStateStopped,
MPMoviePlaybackStatePlaying,
MPMoviePlaybackStatePaused,
MPMoviePlaybackStateInterrupted,
MPMoviePlaybackStateSeekingForward,
MPMoviePlaybackStateSeekingBackward
};
typedef NSInteger MPMoviePlaybackState;
typedef enum {
MPMovieScalingModeNone,
MPMovieScalingModeAspectFit,
MPMovieScalingModeAspectFill,
MPMovieScalingModeFill
} MPMovieScalingMode;
extern NSString *const MPMoviePlayerPlaybackDidFinishReasonUserInfoKey;
// notifications
extern NSString *const MPMoviePlayerPlaybackStateDidChangeNotification;
extern NSString *const MPMoviePlayerPlaybackDidFinishNotification;
extern NSString *const MPMoviePlayerLoadStateDidChangeNotification;
extern NSString *const MPMovieDurationAvailableNotification;
@class UIInternalMovieView;
@interface MPMoviePlayerController : NSObject
{
@private
UIInternalMovieView *movieView;
QTMovie *movie;
}
@property (nonatomic, readonly) UIView *view;
@property (nonatomic, readonly) MPMovieLoadState loadState;
@property (nonatomic, copy) NSURL *contentURL;
@property (nonatomic) MPMovieControlStyle controlStyle;
@property (nonatomic) MPMovieSourceType movieSourceType;
// A view for customization which is always displayed behind movie content.
@property(nonatomic, readonly) UIView *backgroundView;
@property (nonatomic, readonly) MPMoviePlaybackState playbackState;
@property (nonatomic) MPMovieRepeatMode repeatMode;
// Indicates if a movie should automatically start playback when it is likely to finish uninterrupted based on e.g. network conditions. Defaults to YES.
@property(nonatomic) BOOL shouldAutoplay;
@property (nonatomic, readonly) NSTimeInterval duration;
@property (nonatomic) MPMovieScalingMode scalingMode;
- (id)initWithContentURL: (NSURL*)url;
@end
================================================
FILE: Examples/Chameleon Demo/Chameleon/MediaPlayer/Classes/MPMoviePlayerController.m
================================================
//
// MPMoviewPlayerController.m
// MediaPlayer
//
// Created by Michael Dales on 08/07/2011.
// Copyright 2011 Digital Flapjack Ltd. All rights reserved.
//
#import "MPMoviePlayerController.h"
#import "UIInternalMovieView.h"
NSString *const MPMoviePlayerPlaybackDidFinishReasonUserInfoKey = @"MPMoviePlayerPlaybackDidFinishReasonUserInfoKey";
// notifications
NSString *const MPMoviePlayerPlaybackStateDidChangeNotification = @"MPMoviePlayerPlaybackStateDidChangeNotification";
NSString *const MPMoviePlayerPlaybackDidFinishNotification = @"MPMoviePlayerPlaybackDidFinishNotification";
NSString *const MPMoviePlayerLoadStateDidChangeNotification = @"MPMoviePlayerLoadStateDidChangeNotification";
NSString *const MPMovieDurationAvailableNotification = @"MPMovieDurationAvailableNotification";
@implementation MPMoviePlayerController
@synthesize view=_view;
@synthesize loadState=_loadState;
@synthesize contentURL=_contentURL;
@synthesize controlStyle=_controlStyle;
@synthesize movieSourceType=_movieSourceType;
@synthesize backgroundView;
@synthesize playbackState=_playbackState;
@synthesize repeatMode=_repeatMode;
@synthesize shouldAutoplay;
@synthesize scalingMode=_scalingMode;
///////////////////////////////////////////////////////////////////////////////
//
- (void)setScalingMode:(MPMovieScalingMode)scalingMode
{
_scalingMode = scalingMode;
movieView.scalingMode = scalingMode;
}
///////////////////////////////////////////////////////////////////////////////
//
- (void)setRepeatMode:(MPMovieRepeatMode)repeatMode
{
_repeatMode = repeatMode;
[movie setAttribute: [NSNumber numberWithBool: repeatMode == MPMovieRepeatModeOne]
forKey: QTMovieLoopsAttribute];
}
///////////////////////////////////////////////////////////////////////////////
//
- (NSTimeInterval)duration
{
QTTime time = [movie duration];
NSTimeInterval interval;
if (QTGetTimeInterval(time, &interval))
return interval;
else
return 0.0;
}
///////////////////////////////////////////////////////////////////////////////
//
- (UIView*)view
{
return movieView;
}
///////////////////////////////////////////////////////////////////////////////
//
- (MPMovieLoadState)loadState
{
NSNumber* loadState = [movie attributeForKey: QTMovieLoadStateAttribute];
switch ([loadState intValue]) {
case QTMovieLoadStateError:
{
NSLog(@"woo");
NSNumber *stopCode = [NSNumber numberWithInt: MPMovieFinishReasonPlaybackError];
NSDictionary *userInfo = [NSDictionary dictionaryWithObject: stopCode
forKey: MPMoviePlayerPlaybackDidFinishReasonUserInfoKey];
// if there's a loading error we generate a stop notification
[[NSNotificationCenter defaultCenter] postNotificationName: MPMoviePlayerPlaybackDidFinishNotification
object: self
userInfo: userInfo];
_loadState = MPMovieLoadStateUnknown;
}
break;
case QTMovieLoadStateLoading:
_loadState = MPMovieLoadStateUnknown;
break;
case QTMovieLoadStateLoaded:
// we have the meta data, so post the duration available notification
[[NSNotificationCenter defaultCenter] postNotificationName: MPMovieDurationAvailableNotification
object: self];
_loadState = MPMovieLoadStateUnknown;
break;
case QTMovieLoadStatePlayable:
_loadState = MPMovieLoadStatePlayable;
break;
case QTMovieLoadStatePlaythroughOK:
_loadState = MPMovieLoadStatePlaythroughOK;
break;
case QTMovieLoadStateComplete:
_loadState = MPMovieLoadStatePlaythroughOK;
break;
}
return _loadState;
}
#pragma mark - notifications
///////////////////////////////////////////////////////////////////////////////
//
- (void)didEndOccurred: (NSNotification*)notification
{
if (notification.object != movie)
return;
_playbackState = MPMoviePlaybackStateStopped;
NSNumber *stopCode = [NSNumber numberWithInt: MPMovieFinishReasonPlaybackEnded];
NSDictionary *userInfo = [NSDictionary dictionaryWithObject: stopCode
forKey: MPMoviePlayerPlaybackDidFinishReasonUserInfoKey];
[[NSNotificationCenter defaultCenter] postNotificationName: MPMoviePlayerPlaybackDidFinishNotification
object: self
userInfo: userInfo];
}
///////////////////////////////////////////////////////////////////////////////
//
- (void)loadStateChangeOccurred: (NSNotification*)notification
{
if (notification.object != movie)
return;
[[NSNotificationCenter defaultCenter] postNotificationName: MPMoviePlayerLoadStateDidChangeNotification
object: self];
}
#pragma mark - constructor/destructor
///////////////////////////////////////////////////////////////////////////////
//
- (id)initWithContentURL:(NSURL *)url
{
self = [super init];
if (self)
{
_contentURL = [url retain];
_loadState = MPMovieLoadStateUnknown;
_controlStyle = MPMovieControlStyleDefault;
_movieSourceType = MPMovieSourceTypeUnknown;
_playbackState = MPMoviePlaybackStateStopped;
_repeatMode = MPMovieRepeatModeNone;
NSError *error = nil;
movie = [[QTMovie alloc] initWithURL: url
error: &error];
movieView = [[UIInternalMovieView alloc] initWithMovie: movie];
self.scalingMode = MPMovieScalingModeAspectFit;
[[NSNotificationCenter defaultCenter] addObserver: self
selector: @selector(loadStateChangeOccurred:)
name: QTMovieLoadStateDidChangeNotification
object: nil];
[[NSNotificationCenter defaultCenter] addObserver: self
selector: @selector(didEndOccurred:)
name: QTMovieDidEndNotification
object: nil];
}
return self;
}
///////////////////////////////////////////////////////////////////////////////
//
- (void)dealloc
{
[[NSNotificationCenter defaultCenter] removeObserver: self];
[_view release];
[super dealloc];
}
#pragma mark - MPMediaPlayback
///////////////////////////////////////////////////////////////////////////////
//
- (void)play
{
[movie play];
_playbackState = MPMoviePlaybackStatePlaying;
}
///////////////////////////////////////////////////////////////////////////////
//
- (void)pause
{
[movie stop];
_playbackState = MPMoviePlaybackStatePaused;
}
///////////////////////////////////////////////////////////////////////////////
//
- (void)prepareToPlay {
// Do nothing
}
///////////////////////////////////////////////////////////////////////////////
//
- (void)stop
{
[movie stop];
_playbackState = MPMoviePlaybackStateStopped;
}
#pragma mark - Pending
- (void) setShouldAutoplay:(BOOL)shouldAutoplay {
NSLog(@"[CHAMELEON] MPMoviePlayerController.shouldAutoplay not implemented");
}
- (UIView*) backgroundView {
NSLog(@"[CHAMELEON] MPMoviePlayerController.backgroundView not implemented");
return nil;
}
@end
================================================
FILE: Examples/Chameleon Demo/Chameleon/MediaPlayer/Classes/MPMusicPlayerController.h
================================================
/*
* Copyright (c) 2011, The Iconfactory. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of The Iconfactory nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE ICONFACTORY BE LIABLE FOR ANY DIRECT,
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
* OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#import
enum {
MPMusicPlaybackStateStopped,
MPMusicPlaybackStatePlaying,
MPMusicPlaybackStatePaused,
MPMusicPlaybackStateInterrupted,
MPMusicPlaybackStateSeekingForward,
MPMusicPlaybackStateSeekingBackward
};
typedef NSInteger MPMusicPlaybackState;
extern NSString *const MPMusicPlayerControllerPlaybackStateDidChangeNotification;
@interface MPMusicPlayerController : NSObject {
}
+ (MPMusicPlayerController *)iPodMusicPlayer;
- (void)beginGeneratingPlaybackNotifications;
- (void)endGeneratingPlaybackNotifications;
@property (nonatomic, readonly) MPMusicPlaybackState playbackState;
@end
================================================
FILE: Examples/Chameleon Demo/Chameleon/MediaPlayer/Classes/MPMusicPlayerController.m
================================================
/*
* Copyright (c) 2011, The Iconfactory. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of The Iconfactory nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE ICONFACTORY BE LIABLE FOR ANY DIRECT,
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
* OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#import "MPMusicPlayerController.h"
NSString *const MPMusicPlayerControllerPlaybackStateDidChangeNotification = @"MPMusicPlayerControllerPlaybackStateDidChangeNotification";
@implementation MPMusicPlayerController
+ (MPMusicPlayerController *)iPodMusicPlayer
{
return nil;
}
- (MPMusicPlaybackState)playbackState
{
return MPMusicPlaybackStateStopped;
}
- (void)beginGeneratingPlaybackNotifications
{
}
- (void)endGeneratingPlaybackNotifications
{
}
@end
================================================
FILE: Examples/Chameleon Demo/Chameleon/MediaPlayer/Classes/MediaPlayer.h
================================================
/*
* Copyright (c) 2011, The Iconfactory. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of The Iconfactory nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE ICONFACTORY BE LIABLE FOR ANY DIRECT,
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
* OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#import "MPMusicPlayerController.h"
#import "MPMoviePlayerController.h"
================================================
FILE: Examples/Chameleon Demo/Chameleon/MediaPlayer/Classes/UIInternalMovieView.h
================================================
//
// UIInternalMovieView.h
// MediaPlayer
//
// Created by Michael Dales on 08/07/2011.
// Copyright 2011 Digital Flapjack Ltd. All rights reserved.
//
#import
#import
#import "MPMoviePlayerController.h"
@interface UIInternalMovieView : UIView {
@private
QTMovieLayer *movieLayer;
}
@property (nonatomic, retain) QTMovie* movie;
@property (nonatomic, assign) MPMovieScalingMode scalingMode;
- (id)initWithMovie: (QTMovie*)movie;
@end
================================================
FILE: Examples/Chameleon Demo/Chameleon/MediaPlayer/Classes/UIInternalMovieView.m
================================================
//
// UIInternalMovieView.m
// MediaPlayer
//
// Created by Michael Dales on 08/07/2011.
// Copyright 2011 Digital Flapjack Ltd. All rights reserved.
//
#import "UIInternalMovieView.h"
@implementation UIInternalMovieView
@synthesize movie=_movie;
@synthesize scalingMode=_scalingMode;
///////////////////////////////////////////////////////////////////////////////
//
- (void)setScalingMode:(MPMovieScalingMode)scalingMode
{
_scalingMode = scalingMode;
switch (scalingMode)
{
case MPMovieScalingModeNone:
movieLayer.contentsGravity = kCAGravityCenter;
break;
case MPMovieScalingModeAspectFit:
movieLayer.contentsGravity = kCAGravityResizeAspect;
break;
case MPMovieScalingModeAspectFill:
movieLayer.contentsGravity = kCAGravityResizeAspectFill;
break;
case MPMovieScalingModeFill:
movieLayer.contentsGravity = kCAGravityResize;
break;
}
}
///////////////////////////////////////////////////////////////////////////////
//
- (id)initWithMovie:(QTMovie *)movie
{
if ((self = [super init]) != nil)
{
self.movie = movie;
movieLayer = [[QTMovieLayer alloc] initWithMovie: movie];
[self.layer addSublayer: movieLayer];
}
return self;
}
///////////////////////////////////////////////////////////////////////////////
//
- (void)dealloc
{
[_movie release];
[super dealloc];
}
///////////////////////////////////////////////////////////////////////////////
//
- (void)setFrame:(CGRect)frame
{
[super setFrame: frame];
[movieLayer setFrame: frame];
}
@end
================================================
FILE: Examples/Chameleon Demo/Chameleon/MediaPlayer/Info.plist
================================================
CFBundleDevelopmentRegionEnglishCFBundleExecutable${EXECUTABLE_NAME}CFBundleName${PRODUCT_NAME}CFBundleIconFileCFBundleIdentifierorg.chameleonproject.MediaPlayerCFBundleInfoDictionaryVersion6.0CFBundlePackageTypeFMWKCFBundleSignature????CFBundleVersion1CFBundleShortVersionString1.0NSPrincipalClass
================================================
FILE: Examples/Chameleon Demo/Chameleon/MediaPlayer/MediaPlayer.xcodeproj/project.pbxproj
================================================
// !$*UTF8*$!
{
archiveVersion = 1;
classes = {
};
objectVersion = 46;
objects = {
/* Begin PBXBuildFile section */
14C25EF31211ED0400622309 /* MediaPlayer.h in Headers */ = {isa = PBXBuildFile; fileRef = 14C25EF21211ED0400622309 /* MediaPlayer.h */; settings = {ATTRIBUTES = (Public, ); }; };
14C25F001211ED4C00622309 /* MPMusicPlayerController.h in Headers */ = {isa = PBXBuildFile; fileRef = 14C25EFE1211ED4C00622309 /* MPMusicPlayerController.h */; settings = {ATTRIBUTES = (Public, ); }; };
14C25F011211ED4C00622309 /* MPMusicPlayerController.m in Sources */ = {isa = PBXBuildFile; fileRef = 14C25EFF1211ED4C00622309 /* MPMusicPlayerController.m */; };
14EFB1BB1211DB5300D19B0C /* Cocoa.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 14EFB1BA1211DB5300D19B0C /* Cocoa.framework */; };
4C1677D913C70F1A00814195 /* MPMoviePlayerController.h in Headers */ = {isa = PBXBuildFile; fileRef = 4C1677D713C70F1900814195 /* MPMoviePlayerController.h */; settings = {ATTRIBUTES = (Public, ); }; };
4C1677DA13C70F1A00814195 /* MPMoviePlayerController.m in Sources */ = {isa = PBXBuildFile; fileRef = 4C1677D813C70F1900814195 /* MPMoviePlayerController.m */; };
4C16781613C71E4900814195 /* MPMediaPlayback.h in Headers */ = {isa = PBXBuildFile; fileRef = 4C16781513C71E4900814195 /* MPMediaPlayback.h */; settings = {ATTRIBUTES = (Public, ); }; };
4C16781A13C71E6200814195 /* UIInternalMovieView.h in Headers */ = {isa = PBXBuildFile; fileRef = 4C16781813C71E6200814195 /* UIInternalMovieView.h */; settings = {ATTRIBUTES = (Private, ); }; };
4C16781B13C71E6200814195 /* UIInternalMovieView.m in Sources */ = {isa = PBXBuildFile; fileRef = 4C16781913C71E6200814195 /* UIInternalMovieView.m */; };
4C16787D13C71FB900814195 /* UIKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 4C16787C13C71FB900814195 /* UIKit.framework */; };
4C16789F13C7206500814195 /* QTKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 4C16789E13C7206500814195 /* QTKit.framework */; };
4C72FDF613C746E800D3E453 /* QuartzCore.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 4C72FDF513C746E800D3E453 /* QuartzCore.framework */; };
/* End PBXBuildFile section */
/* Begin PBXContainerItemProxy section */
4C16787913C71F8A00814195 /* PBXContainerItemProxy */ = {
isa = PBXContainerItemProxy;
containerPortal = 4C16787213C71F8A00814195 /* UIKit.xcodeproj */;
proxyType = 2;
remoteGlobalIDString = 8DC2EF5B0486A6940098B216;
remoteInfo = UIKit;
};
/* End PBXContainerItemProxy section */
/* Begin PBXFileReference section */
0867D69BFE84028FC02AAC07 /* Foundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Foundation.framework; path = /System/Library/Frameworks/Foundation.framework; sourceTree = ""; };
0867D6A5FE840307C02AAC07 /* AppKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = AppKit.framework; path = /System/Library/Frameworks/AppKit.framework; sourceTree = ""; };
14C25EF21211ED0400622309 /* MediaPlayer.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = MediaPlayer.h; path = Classes/MediaPlayer.h; sourceTree = ""; };
14C25EF41211ED0C00622309 /* MediaPlayer_Prefix.pch */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MediaPlayer_Prefix.pch; sourceTree = ""; };
14C25EFE1211ED4C00622309 /* MPMusicPlayerController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = MPMusicPlayerController.h; path = Classes/MPMusicPlayerController.h; sourceTree = ""; };
14C25EFF1211ED4C00622309 /* MPMusicPlayerController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = MPMusicPlayerController.m; path = Classes/MPMusicPlayerController.m; sourceTree = ""; };
14EFB1BA1211DB5300D19B0C /* Cocoa.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Cocoa.framework; path = System/Library/Frameworks/Cocoa.framework; sourceTree = SDKROOT; };
4C1677D713C70F1900814195 /* MPMoviePlayerController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = MPMoviePlayerController.h; path = Classes/MPMoviePlayerController.h; sourceTree = ""; };
4C1677D813C70F1900814195 /* MPMoviePlayerController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = MPMoviePlayerController.m; path = Classes/MPMoviePlayerController.m; sourceTree = ""; };
4C16781513C71E4900814195 /* MPMediaPlayback.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = MPMediaPlayback.h; path = Classes/MPMediaPlayback.h; sourceTree = ""; };
4C16781813C71E6200814195 /* UIInternalMovieView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = UIInternalMovieView.h; path = Classes/UIInternalMovieView.h; sourceTree = ""; };
4C16781913C71E6200814195 /* UIInternalMovieView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = UIInternalMovieView.m; path = Classes/UIInternalMovieView.m; sourceTree = ""; };
4C16787213C71F8A00814195 /* UIKit.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = UIKit.xcodeproj; path = ../UIKit/UIKit.xcodeproj; sourceTree = ""; };
4C16787C13C71FB900814195 /* UIKit.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; path = UIKit.framework; sourceTree = SOURCE_ROOT; };
4C16789E13C7206500814195 /* QTKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = QTKit.framework; path = System/Library/Frameworks/QTKit.framework; sourceTree = SDKROOT; };
4C72FDF513C746E800D3E453 /* QuartzCore.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = QuartzCore.framework; path = System/Library/Frameworks/QuartzCore.framework; sourceTree = SDKROOT; };
8DC2EF5A0486A6940098B216 /* Info.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; };
8DC2EF5B0486A6940098B216 /* MediaPlayer.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = MediaPlayer.framework; sourceTree = BUILT_PRODUCTS_DIR; };
/* End PBXFileReference section */
/* Begin PBXFrameworksBuildPhase section */
8DC2EF560486A6940098B216 /* Frameworks */ = {
isa = PBXFrameworksBuildPhase;
buildActionMask = 2147483647;
files = (
4C72FDF613C746E800D3E453 /* QuartzCore.framework in Frameworks */,
4C16789F13C7206500814195 /* QTKit.framework in Frameworks */,
4C16787D13C71FB900814195 /* UIKit.framework in Frameworks */,
14EFB1BB1211DB5300D19B0C /* Cocoa.framework in Frameworks */,
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXFrameworksBuildPhase section */
/* Begin PBXGroup section */
034768DFFF38A50411DB9C8B /* Products */ = {
isa = PBXGroup;
children = (
8DC2EF5B0486A6940098B216 /* MediaPlayer.framework */,
);
name = Products;
sourceTree = "";
};
0867D691FE84028FC02AAC07 /* UIKit */ = {
isa = PBXGroup;
children = (
4C72FDF513C746E800D3E453 /* QuartzCore.framework */,
4C16789E13C7206500814195 /* QTKit.framework */,
4C16787C13C71FB900814195 /* UIKit.framework */,
08FB77AEFE84172EC02AAC07 /* Classes */,
4C16780A13C71DDC00814195 /* Private Classes */,
089C1665FE841158C02AAC07 /* Resources */,
32C88DFF0371C24200C91783 /* Other Sources */,
0867D69AFE84028FC02AAC07 /* External Frameworks and Libraries */,
034768DFFF38A50411DB9C8B /* Products */,
4C16787213C71F8A00814195 /* UIKit.xcodeproj */,
);
name = UIKit;
sourceTree = "";
};
0867D69AFE84028FC02AAC07 /* External Frameworks and Libraries */ = {
isa = PBXGroup;
children = (
0867D6A5FE840307C02AAC07 /* AppKit.framework */,
0867D69BFE84028FC02AAC07 /* Foundation.framework */,
14EFB1BA1211DB5300D19B0C /* Cocoa.framework */,
);
name = "External Frameworks and Libraries";
sourceTree = "";
};
089C1665FE841158C02AAC07 /* Resources */ = {
isa = PBXGroup;
children = (
8DC2EF5A0486A6940098B216 /* Info.plist */,
);
name = Resources;
sourceTree = "";
};
08FB77AEFE84172EC02AAC07 /* Classes */ = {
isa = PBXGroup;
children = (
14C25EF21211ED0400622309 /* MediaPlayer.h */,
14C25EFE1211ED4C00622309 /* MPMusicPlayerController.h */,
14C25EFF1211ED4C00622309 /* MPMusicPlayerController.m */,
4C1677D713C70F1900814195 /* MPMoviePlayerController.h */,
4C1677D813C70F1900814195 /* MPMoviePlayerController.m */,
4C16781513C71E4900814195 /* MPMediaPlayback.h */,
);
name = Classes;
sourceTree = "";
};
32C88DFF0371C24200C91783 /* Other Sources */ = {
isa = PBXGroup;
children = (
14C25EF41211ED0C00622309 /* MediaPlayer_Prefix.pch */,
);
name = "Other Sources";
sourceTree = "";
};
4C16780A13C71DDC00814195 /* Private Classes */ = {
isa = PBXGroup;
children = (
4C16781813C71E6200814195 /* UIInternalMovieView.h */,
4C16781913C71E6200814195 /* UIInternalMovieView.m */,
);
name = "Private Classes";
sourceTree = "";
};
4C16787313C71F8A00814195 /* Products */ = {
isa = PBXGroup;
children = (
4C16787A13C71F8A00814195 /* UIKit.framework */,
);
name = Products;
sourceTree = "";
};
/* End PBXGroup section */
/* Begin PBXHeadersBuildPhase section */
8DC2EF500486A6940098B216 /* Headers */ = {
isa = PBXHeadersBuildPhase;
buildActionMask = 2147483647;
files = (
14C25EF31211ED0400622309 /* MediaPlayer.h in Headers */,
14C25F001211ED4C00622309 /* MPMusicPlayerController.h in Headers */,
4C1677D913C70F1A00814195 /* MPMoviePlayerController.h in Headers */,
4C16781613C71E4900814195 /* MPMediaPlayback.h in Headers */,
4C16781A13C71E6200814195 /* UIInternalMovieView.h in Headers */,
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXHeadersBuildPhase section */
/* Begin PBXNativeTarget section */
8DC2EF4F0486A6940098B216 /* MediaPlayer */ = {
isa = PBXNativeTarget;
buildConfigurationList = 1DEB91AD08733DA50010E9CD /* Build configuration list for PBXNativeTarget "MediaPlayer" */;
buildPhases = (
8DC2EF500486A6940098B216 /* Headers */,
8DC2EF520486A6940098B216 /* Resources */,
8DC2EF540486A6940098B216 /* Sources */,
8DC2EF560486A6940098B216 /* Frameworks */,
);
buildRules = (
);
dependencies = (
);
name = MediaPlayer;
productInstallPath = "$(HOME)/Library/Frameworks";
productName = UIKit;
productReference = 8DC2EF5B0486A6940098B216 /* MediaPlayer.framework */;
productType = "com.apple.product-type.framework";
};
/* End PBXNativeTarget section */
/* Begin PBXProject section */
0867D690FE84028FC02AAC07 /* Project object */ = {
isa = PBXProject;
attributes = {
LastUpgradeCheck = 0510;
};
buildConfigurationList = 1DEB91B108733DA50010E9CD /* Build configuration list for PBXProject "MediaPlayer" */;
compatibilityVersion = "Xcode 3.2";
developmentRegion = English;
hasScannedForEncodings = 1;
knownRegions = (
English,
Japanese,
French,
German,
);
mainGroup = 0867D691FE84028FC02AAC07 /* UIKit */;
productRefGroup = 034768DFFF38A50411DB9C8B /* Products */;
projectDirPath = "";
projectReferences = (
{
ProductGroup = 4C16787313C71F8A00814195 /* Products */;
ProjectRef = 4C16787213C71F8A00814195 /* UIKit.xcodeproj */;
},
);
projectRoot = "";
targets = (
8DC2EF4F0486A6940098B216 /* MediaPlayer */,
);
};
/* End PBXProject section */
/* Begin PBXReferenceProxy section */
4C16787A13C71F8A00814195 /* UIKit.framework */ = {
isa = PBXReferenceProxy;
fileType = wrapper.framework;
path = UIKit.framework;
remoteRef = 4C16787913C71F8A00814195 /* PBXContainerItemProxy */;
sourceTree = BUILT_PRODUCTS_DIR;
};
/* End PBXReferenceProxy section */
/* Begin PBXResourcesBuildPhase section */
8DC2EF520486A6940098B216 /* Resources */ = {
isa = PBXResourcesBuildPhase;
buildActionMask = 2147483647;
files = (
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXResourcesBuildPhase section */
/* Begin PBXSourcesBuildPhase section */
8DC2EF540486A6940098B216 /* Sources */ = {
isa = PBXSourcesBuildPhase;
buildActionMask = 2147483647;
files = (
14C25F011211ED4C00622309 /* MPMusicPlayerController.m in Sources */,
4C1677DA13C70F1A00814195 /* MPMoviePlayerController.m in Sources */,
4C16781B13C71E6200814195 /* UIInternalMovieView.m in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXSourcesBuildPhase section */
/* Begin XCBuildConfiguration section */
1DEB91AE08733DA50010E9CD /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
COPY_PHASE_STRIP = NO;
DYLIB_COMPATIBILITY_VERSION = 1;
DYLIB_CURRENT_VERSION = 1;
FRAMEWORK_SEARCH_PATHS = (
"$(inherited)",
"\"$(SRCROOT)\"",
);
FRAMEWORK_VERSION = A;
GCC_DYNAMIC_NO_PIC = NO;
GCC_MODEL_TUNING = G5;
GCC_OPTIMIZATION_LEVEL = 0;
GCC_PRECOMPILE_PREFIX_HEADER = YES;
GCC_PREFIX_HEADER = MediaPlayer_Prefix.pch;
INFOPLIST_FILE = Info.plist;
INSTALL_PATH = "@executable_path/../Frameworks";
PRODUCT_NAME = MediaPlayer;
SYMROOT = ../build;
VALID_ARCHS = "i386 x86_64";
WRAPPER_EXTENSION = framework;
};
name = Debug;
};
1DEB91AF08733DA50010E9CD /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
DYLIB_COMPATIBILITY_VERSION = 1;
DYLIB_CURRENT_VERSION = 1;
FRAMEWORK_SEARCH_PATHS = (
"$(inherited)",
"\"$(SRCROOT)\"",
);
FRAMEWORK_VERSION = A;
GCC_MODEL_TUNING = G5;
GCC_PRECOMPILE_PREFIX_HEADER = YES;
GCC_PREFIX_HEADER = MediaPlayer_Prefix.pch;
INFOPLIST_FILE = Info.plist;
INSTALL_PATH = "@executable_path/../Frameworks";
PRODUCT_NAME = MediaPlayer;
SYMROOT = ../build;
VALID_ARCHS = "i386 x86_64";
WRAPPER_EXTENSION = framework;
};
name = Release;
};
1DEB91B208733DA50010E9CD /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
GCC_C_LANGUAGE_STANDARD = gnu99;
GCC_OPTIMIZATION_LEVEL = 0;
GCC_WARN_ABOUT_MISSING_PROTOTYPES = YES;
GCC_WARN_ABOUT_RETURN_TYPE = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
MACOSX_DEPLOYMENT_TARGET = 10.6;
ONLY_ACTIVE_ARCH = YES;
SDKROOT = macosx;
};
name = Debug;
};
1DEB91B308733DA50010E9CD /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
CODE_SIGN_IDENTITY = "3rd Party Mac Developer Application";
GCC_C_LANGUAGE_STANDARD = gnu99;
GCC_WARN_ABOUT_MISSING_PROTOTYPES = YES;
GCC_WARN_ABOUT_RETURN_TYPE = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
MACOSX_DEPLOYMENT_TARGET = 10.6;
PROVISIONING_PROFILE = "";
SDKROOT = macosx;
};
name = Release;
};
/* End XCBuildConfiguration section */
/* Begin XCConfigurationList section */
1DEB91AD08733DA50010E9CD /* Build configuration list for PBXNativeTarget "MediaPlayer" */ = {
isa = XCConfigurationList;
buildConfigurations = (
1DEB91AE08733DA50010E9CD /* Debug */,
1DEB91AF08733DA50010E9CD /* Release */,
);
defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release;
};
1DEB91B108733DA50010E9CD /* Build configuration list for PBXProject "MediaPlayer" */ = {
isa = XCConfigurationList;
buildConfigurations = (
1DEB91B208733DA50010E9CD /* Debug */,
1DEB91B308733DA50010E9CD /* Release */,
);
defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release;
};
/* End XCConfigurationList section */
};
rootObject = 0867D690FE84028FC02AAC07 /* Project object */;
}
================================================
FILE: Examples/Chameleon Demo/Chameleon/MediaPlayer/MediaPlayer.xcodeproj/project.xcworkspace/contents.xcworkspacedata
================================================
================================================
FILE: Examples/Chameleon Demo/Chameleon/MediaPlayer/MediaPlayer_Prefix.pch
================================================
/*
* Copyright (c) 2011, The Iconfactory. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of The Iconfactory nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE ICONFACTORY BE LIABLE FOR ANY DIRECT,
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
* OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#ifdef __OBJC__
#import
#endif
================================================
FILE: Examples/Chameleon Demo/Chameleon/MessageUI/Classes/MFMailComposeViewController.h
================================================
/*
* Copyright (c) 2011, The Iconfactory. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of The Iconfactory nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE ICONFACTORY BE LIABLE FOR ANY DIRECT,
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
* OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#import
@class MFMailComposeViewController;
enum MFMailComposeResult {
MFMailComposeResultCancelled,
MFMailComposeResultSaved,
MFMailComposeResultSent,
MFMailComposeResultFailed
};
typedef enum MFMailComposeResult MFMailComposeResult;
@protocol MFMailComposeViewControllerDelegate
@optional
- (void)mailComposeController:(MFMailComposeViewController *)controller didFinishWithResult:(MFMailComposeResult)result error:(NSError *)error;
@end
@interface MFMailComposeViewController : UINavigationController
+ (BOOL)canSendMail;
- (void)setSubject:(NSString*)subject;
- (void)setToRecipients:(NSArray*)toRecipients;
- (void)setMessageBody:(NSString*)body isHTML:(BOOL)isHTML;
- (void)setCcRecipients:(NSArray*)ccRecipients;
- (void)setBccRecipients:(NSArray*)bccRecipients;
- (void)addAttachmentData:(NSData*)attachment mimeType:(NSString*)mimeType fileName:(NSString*)filename;
@property (nonatomic, assign) id mailComposeDelegate;
@end
================================================
FILE: Examples/Chameleon Demo/Chameleon/MessageUI/Classes/MFMailComposeViewController.m
================================================
/*
* Copyright (c) 2011, The Iconfactory. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of The Iconfactory nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE ICONFACTORY BE LIABLE FOR ANY DIRECT,
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
* OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#import "MFMailComposeViewController.h"
@implementation MFMailComposeViewController
+ (BOOL)canSendMail
{
return NO;
}
- (void)setSubject:(NSString*)subject
{
}
- (void)setToRecipients:(NSArray*)toRecipients
{
}
- (void)setMessageBody:(NSString*)body isHTML:(BOOL)isHTML
{
}
- (void)setCcRecipients:(NSArray*)ccRecipients
{
}
- (void)setBccRecipients:(NSArray*)bccRecipients
{
}
- (void)addAttachmentData:(NSData*)attachment mimeType:(NSString*)mimeType fileName:(NSString*)filename
{
}
@end
================================================
FILE: Examples/Chameleon Demo/Chameleon/MessageUI/Classes/MessageUI.h
================================================
/*
* Copyright (c) 2011, The Iconfactory. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of The Iconfactory nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE ICONFACTORY BE LIABLE FOR ANY DIRECT,
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
* OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#import "MFMailComposeViewController.h"
#import "MFMessageComposeViewController.h"
================================================
FILE: Examples/Chameleon Demo/Chameleon/MessageUI/Info.plist
================================================
CFBundleDevelopmentRegionEnglishCFBundleExecutable${EXECUTABLE_NAME}CFBundleName${PRODUCT_NAME}CFBundleIconFileCFBundleIdentifierorg.chameleonproject.MessageUICFBundleInfoDictionaryVersion6.0CFBundlePackageTypeFMWKCFBundleSignature????CFBundleVersion1CFBundleShortVersionString1.0NSPrincipalClass
================================================
FILE: Examples/Chameleon Demo/Chameleon/MessageUI/MFMessageComposeViewController.h
================================================
//
// MFMessageComposeViewController.h
// MessageUI
//
// Created by Peter Steinberger on 24.03.11.
//
/*
* Copyright (c) 2011, The Iconfactory. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of The Iconfactory nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE ICONFACTORY BE LIABLE FOR ANY DIRECT,
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
* OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
@protocol MFMessageComposeViewControllerDelegate;
enum MessageComposeResult {
MessageComposeResultCancelled,
MessageComposeResultSent,
MessageComposeResultFailed
};
typedef enum MessageComposeResult MessageComposeResult;
@interface MFMessageComposeViewController : NSObject
+ (BOOL)canSendText;
@property (nonatomic, assign) id messageComposeDelegate;
@property(nonatomic, copy) NSArray *recipients;
@property(nonatomic, copy) NSString *body;
@end
@protocol MFMessageComposeViewControllerDelegate
@required
- (void)messageComposeViewController:(MFMessageComposeViewController *)controller didFinishWithResult:(MessageComposeResult)result;
@end
================================================
FILE: Examples/Chameleon Demo/Chameleon/MessageUI/MFMessageComposeViewController.m
================================================
//
// MFMessageComposeViewController.m
// MessageUI
//
// Created by Peter Steinberger on 24.03.11.
//
/*
* Copyright (c) 2011, The Iconfactory. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of The Iconfactory nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE ICONFACTORY BE LIABLE FOR ANY DIRECT,
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
* OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#import "MFMessageComposeViewController.h"
@implementation MFMessageComposeViewController
+ (BOOL)canSendText {
return NO; // most likely we can't send messages on a mac ;)
}
@end
================================================
FILE: Examples/Chameleon Demo/Chameleon/MessageUI/MessageUI.xcodeproj/project.pbxproj
================================================
// !$*UTF8*$!
{
archiveVersion = 1;
classes = {
};
objectVersion = 46;
objects = {
/* Begin PBXBuildFile section */
143B578F1230357600F43562 /* MFMailComposeViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 14FB132C12302FD900B615ED /* MFMailComposeViewController.m */; };
143B57941230357C00F43562 /* UIKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 14FB133A1230307C00B615ED /* UIKit.framework */; };
14C25EF31211ED0400622309 /* MessageUI.h in Headers */ = {isa = PBXBuildFile; fileRef = 14C25EF21211ED0400622309 /* MessageUI.h */; settings = {ATTRIBUTES = (Public, ); }; };
14EFB1BB1211DB5300D19B0C /* Cocoa.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 14EFB1BA1211DB5300D19B0C /* Cocoa.framework */; };
14FB132D12302FD900B615ED /* MFMailComposeViewController.h in Headers */ = {isa = PBXBuildFile; fileRef = 14FB132B12302FD900B615ED /* MFMailComposeViewController.h */; settings = {ATTRIBUTES = (Public, ); }; };
78CB48DD133ABB2C008636DA /* MFMessageComposeViewController.h in Headers */ = {isa = PBXBuildFile; fileRef = 78CB48DB133ABB2C008636DA /* MFMessageComposeViewController.h */; settings = {ATTRIBUTES = (Public, ); }; };
78CB48DE133ABB2C008636DA /* MFMessageComposeViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 78CB48DC133ABB2C008636DA /* MFMessageComposeViewController.m */; };
/* End PBXBuildFile section */
/* Begin PBXContainerItemProxy section */
14FB13391230307C00B615ED /* PBXContainerItemProxy */ = {
isa = PBXContainerItemProxy;
containerPortal = 14FB13351230307C00B615ED /* UIKit.xcodeproj */;
proxyType = 2;
remoteGlobalIDString = 8DC2EF5B0486A6940098B216;
remoteInfo = UIKit;
};
14FB133C1230308E00B615ED /* PBXContainerItemProxy */ = {
isa = PBXContainerItemProxy;
containerPortal = 14FB13351230307C00B615ED /* UIKit.xcodeproj */;
proxyType = 1;
remoteGlobalIDString = 8DC2EF4F0486A6940098B216;
remoteInfo = UIKit;
};
780E7544133AC53400D8C77B /* PBXContainerItemProxy */ = {
isa = PBXContainerItemProxy;
containerPortal = 780E7540133AC53400D8C77B /* UIKit.xcodeproj */;
proxyType = 2;
remoteGlobalIDString = 8DC2EF5B0486A6940098B216;
remoteInfo = UIKit;
};
/* End PBXContainerItemProxy section */
/* Begin PBXFileReference section */
0867D69BFE84028FC02AAC07 /* Foundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Foundation.framework; path = /System/Library/Frameworks/Foundation.framework; sourceTree = ""; };
0867D6A5FE840307C02AAC07 /* AppKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = AppKit.framework; path = /System/Library/Frameworks/AppKit.framework; sourceTree = ""; };
14C25EF21211ED0400622309 /* MessageUI.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = MessageUI.h; path = Classes/MessageUI.h; sourceTree = ""; };
14EFB1BA1211DB5300D19B0C /* Cocoa.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Cocoa.framework; path = System/Library/Frameworks/Cocoa.framework; sourceTree = SDKROOT; };
14FB132512302F8700B615ED /* MessageUI_Prefix.pch */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MessageUI_Prefix.pch; sourceTree = ""; };
14FB132B12302FD900B615ED /* MFMailComposeViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = MFMailComposeViewController.h; path = Classes/MFMailComposeViewController.h; sourceTree = ""; };
14FB132C12302FD900B615ED /* MFMailComposeViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = MFMailComposeViewController.m; path = Classes/MFMailComposeViewController.m; sourceTree = ""; };
14FB13351230307C00B615ED /* UIKit.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = UIKit.xcodeproj; path = ../UIKit/UIKit.xcodeproj; sourceTree = SOURCE_ROOT; };
780E7540133AC53400D8C77B /* UIKit.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = UIKit.xcodeproj; path = ../UIKit/UIKit.xcodeproj; sourceTree = ""; };
78CB48DB133ABB2C008636DA /* MFMessageComposeViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MFMessageComposeViewController.h; sourceTree = ""; };
78CB48DC133ABB2C008636DA /* MFMessageComposeViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = MFMessageComposeViewController.m; sourceTree = ""; };
8DC2EF5A0486A6940098B216 /* Info.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; };
8DC2EF5B0486A6940098B216 /* MessageUI.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = MessageUI.framework; sourceTree = BUILT_PRODUCTS_DIR; };
/* End PBXFileReference section */
/* Begin PBXFrameworksBuildPhase section */
8DC2EF560486A6940098B216 /* Frameworks */ = {
isa = PBXFrameworksBuildPhase;
buildActionMask = 2147483647;
files = (
143B57941230357C00F43562 /* UIKit.framework in Frameworks */,
14EFB1BB1211DB5300D19B0C /* Cocoa.framework in Frameworks */,
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXFrameworksBuildPhase section */
/* Begin PBXGroup section */
034768DFFF38A50411DB9C8B /* Products */ = {
isa = PBXGroup;
children = (
8DC2EF5B0486A6940098B216 /* MessageUI.framework */,
);
name = Products;
sourceTree = "";
};
0867D691FE84028FC02AAC07 /* UIKit */ = {
isa = PBXGroup;
children = (
14FB13351230307C00B615ED /* UIKit.xcodeproj */,
08FB77AEFE84172EC02AAC07 /* Classes */,
089C1665FE841158C02AAC07 /* Resources */,
32C88DFF0371C24200C91783 /* Other Sources */,
0867D69AFE84028FC02AAC07 /* External Frameworks and Libraries */,
034768DFFF38A50411DB9C8B /* Products */,
780E7540133AC53400D8C77B /* UIKit.xcodeproj */,
);
name = UIKit;
sourceTree = "";
};
0867D69AFE84028FC02AAC07 /* External Frameworks and Libraries */ = {
isa = PBXGroup;
children = (
0867D6A5FE840307C02AAC07 /* AppKit.framework */,
0867D69BFE84028FC02AAC07 /* Foundation.framework */,
14EFB1BA1211DB5300D19B0C /* Cocoa.framework */,
);
name = "External Frameworks and Libraries";
sourceTree = "";
};
089C1665FE841158C02AAC07 /* Resources */ = {
isa = PBXGroup;
children = (
8DC2EF5A0486A6940098B216 /* Info.plist */,
);
name = Resources;
sourceTree = "";
};
08FB77AEFE84172EC02AAC07 /* Classes */ = {
isa = PBXGroup;
children = (
14C25EF21211ED0400622309 /* MessageUI.h */,
14FB132B12302FD900B615ED /* MFMailComposeViewController.h */,
14FB132C12302FD900B615ED /* MFMailComposeViewController.m */,
78CB48DB133ABB2C008636DA /* MFMessageComposeViewController.h */,
78CB48DC133ABB2C008636DA /* MFMessageComposeViewController.m */,
);
name = Classes;
sourceTree = "";
};
14FB13361230307C00B615ED /* Products */ = {
isa = PBXGroup;
children = (
14FB133A1230307C00B615ED /* UIKit.framework */,
);
name = Products;
sourceTree = "";
};
32C88DFF0371C24200C91783 /* Other Sources */ = {
isa = PBXGroup;
children = (
14FB132512302F8700B615ED /* MessageUI_Prefix.pch */,
);
name = "Other Sources";
sourceTree = "";
};
780E7541133AC53400D8C77B /* Products */ = {
isa = PBXGroup;
children = (
780E7545133AC53400D8C77B /* UIKit.framework */,
);
name = Products;
sourceTree = "";
};
/* End PBXGroup section */
/* Begin PBXHeadersBuildPhase section */
8DC2EF500486A6940098B216 /* Headers */ = {
isa = PBXHeadersBuildPhase;
buildActionMask = 2147483647;
files = (
14C25EF31211ED0400622309 /* MessageUI.h in Headers */,
14FB132D12302FD900B615ED /* MFMailComposeViewController.h in Headers */,
78CB48DD133ABB2C008636DA /* MFMessageComposeViewController.h in Headers */,
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXHeadersBuildPhase section */
/* Begin PBXNativeTarget section */
8DC2EF4F0486A6940098B216 /* MessageUI */ = {
isa = PBXNativeTarget;
buildConfigurationList = 1DEB91AD08733DA50010E9CD /* Build configuration list for PBXNativeTarget "MessageUI" */;
buildPhases = (
8DC2EF500486A6940098B216 /* Headers */,
8DC2EF520486A6940098B216 /* Resources */,
8DC2EF540486A6940098B216 /* Sources */,
8DC2EF560486A6940098B216 /* Frameworks */,
);
buildRules = (
);
dependencies = (
14FB133D1230308E00B615ED /* PBXTargetDependency */,
);
name = MessageUI;
productInstallPath = "$(HOME)/Library/Frameworks";
productName = UIKit;
productReference = 8DC2EF5B0486A6940098B216 /* MessageUI.framework */;
productType = "com.apple.product-type.framework";
};
/* End PBXNativeTarget section */
/* Begin PBXProject section */
0867D690FE84028FC02AAC07 /* Project object */ = {
isa = PBXProject;
attributes = {
LastUpgradeCheck = 0510;
};
buildConfigurationList = 1DEB91B108733DA50010E9CD /* Build configuration list for PBXProject "MessageUI" */;
compatibilityVersion = "Xcode 3.2";
developmentRegion = English;
hasScannedForEncodings = 1;
knownRegions = (
English,
Japanese,
French,
German,
);
mainGroup = 0867D691FE84028FC02AAC07 /* UIKit */;
productRefGroup = 034768DFFF38A50411DB9C8B /* Products */;
projectDirPath = "";
projectReferences = (
{
ProductGroup = 780E7541133AC53400D8C77B /* Products */;
ProjectRef = 780E7540133AC53400D8C77B /* UIKit.xcodeproj */;
},
{
ProductGroup = 14FB13361230307C00B615ED /* Products */;
ProjectRef = 14FB13351230307C00B615ED /* UIKit.xcodeproj */;
},
);
projectRoot = "";
targets = (
8DC2EF4F0486A6940098B216 /* MessageUI */,
);
};
/* End PBXProject section */
/* Begin PBXReferenceProxy section */
14FB133A1230307C00B615ED /* UIKit.framework */ = {
isa = PBXReferenceProxy;
fileType = wrapper.framework;
path = UIKit.framework;
remoteRef = 14FB13391230307C00B615ED /* PBXContainerItemProxy */;
sourceTree = BUILT_PRODUCTS_DIR;
};
780E7545133AC53400D8C77B /* UIKit.framework */ = {
isa = PBXReferenceProxy;
fileType = wrapper.framework;
path = UIKit.framework;
remoteRef = 780E7544133AC53400D8C77B /* PBXContainerItemProxy */;
sourceTree = BUILT_PRODUCTS_DIR;
};
/* End PBXReferenceProxy section */
/* Begin PBXResourcesBuildPhase section */
8DC2EF520486A6940098B216 /* Resources */ = {
isa = PBXResourcesBuildPhase;
buildActionMask = 2147483647;
files = (
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXResourcesBuildPhase section */
/* Begin PBXSourcesBuildPhase section */
8DC2EF540486A6940098B216 /* Sources */ = {
isa = PBXSourcesBuildPhase;
buildActionMask = 2147483647;
files = (
143B578F1230357600F43562 /* MFMailComposeViewController.m in Sources */,
78CB48DE133ABB2C008636DA /* MFMessageComposeViewController.m in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXSourcesBuildPhase section */
/* Begin PBXTargetDependency section */
14FB133D1230308E00B615ED /* PBXTargetDependency */ = {
isa = PBXTargetDependency;
name = UIKit;
targetProxy = 14FB133C1230308E00B615ED /* PBXContainerItemProxy */;
};
/* End PBXTargetDependency section */
/* Begin XCBuildConfiguration section */
1DEB91AE08733DA50010E9CD /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
COMBINE_HIDPI_IMAGES = NO;
COPY_PHASE_STRIP = NO;
DYLIB_COMPATIBILITY_VERSION = 1;
DYLIB_CURRENT_VERSION = 1;
FRAMEWORK_VERSION = A;
GCC_DYNAMIC_NO_PIC = NO;
GCC_MODEL_TUNING = G5;
GCC_OPTIMIZATION_LEVEL = 0;
GCC_PRECOMPILE_PREFIX_HEADER = YES;
GCC_PREFIX_HEADER = MessageUI_Prefix.pch;
GCC_VERSION = com.apple.compilers.llvm.clang.1_0;
INFOPLIST_FILE = Info.plist;
INSTALL_PATH = "@executable_path/../Frameworks";
PRODUCT_NAME = MessageUI;
SYMROOT = ../build;
WRAPPER_EXTENSION = framework;
};
name = Debug;
};
1DEB91AF08733DA50010E9CD /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
COMBINE_HIDPI_IMAGES = NO;
DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
DYLIB_COMPATIBILITY_VERSION = 1;
DYLIB_CURRENT_VERSION = 1;
FRAMEWORK_VERSION = A;
GCC_MODEL_TUNING = G5;
GCC_PRECOMPILE_PREFIX_HEADER = YES;
GCC_PREFIX_HEADER = MessageUI_Prefix.pch;
GCC_VERSION = com.apple.compilers.llvm.clang.1_0;
INFOPLIST_FILE = Info.plist;
INSTALL_PATH = "@executable_path/../Frameworks";
PRODUCT_NAME = MessageUI;
SYMROOT = ../build;
WRAPPER_EXTENSION = framework;
};
name = Release;
};
1DEB91B208733DA50010E9CD /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
GCC_C_LANGUAGE_STANDARD = gnu99;
GCC_OPTIMIZATION_LEVEL = 0;
GCC_WARN_ABOUT_MISSING_PROTOTYPES = YES;
GCC_WARN_ABOUT_RETURN_TYPE = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
MACOSX_DEPLOYMENT_TARGET = 10.7;
ONLY_ACTIVE_ARCH = YES;
SDKROOT = macosx;
};
name = Debug;
};
1DEB91B308733DA50010E9CD /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
CODE_SIGN_IDENTITY = "Developer ID Application: The Iconfactory";
GCC_C_LANGUAGE_STANDARD = gnu99;
GCC_WARN_ABOUT_MISSING_PROTOTYPES = YES;
GCC_WARN_ABOUT_RETURN_TYPE = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
MACOSX_DEPLOYMENT_TARGET = 10.7;
PROVISIONING_PROFILE = "";
SDKROOT = macosx;
};
name = Release;
};
/* End XCBuildConfiguration section */
/* Begin XCConfigurationList section */
1DEB91AD08733DA50010E9CD /* Build configuration list for PBXNativeTarget "MessageUI" */ = {
isa = XCConfigurationList;
buildConfigurations = (
1DEB91AE08733DA50010E9CD /* Debug */,
1DEB91AF08733DA50010E9CD /* Release */,
);
defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release;
};
1DEB91B108733DA50010E9CD /* Build configuration list for PBXProject "MessageUI" */ = {
isa = XCConfigurationList;
buildConfigurations = (
1DEB91B208733DA50010E9CD /* Debug */,
1DEB91B308733DA50010E9CD /* Release */,
);
defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release;
};
/* End XCConfigurationList section */
};
rootObject = 0867D690FE84028FC02AAC07 /* Project object */;
}
================================================
FILE: Examples/Chameleon Demo/Chameleon/MessageUI/MessageUI.xcodeproj/project.xcworkspace/contents.xcworkspacedata
================================================
================================================
FILE: Examples/Chameleon Demo/Chameleon/MessageUI/MessageUI_Prefix.pch
================================================
/*
* Copyright (c) 2011, The Iconfactory. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of The Iconfactory nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE ICONFACTORY BE LIABLE FOR ANY DIRECT,
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
* OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#ifdef __OBJC__
#import
#endif
================================================
FILE: Examples/Chameleon Demo/Chameleon/README.md
================================================
# Chameleon
Chameleon is a port of Apple's UIKit (and some minimal related frameworks) to Mac OS X. It is meant to be as much of a drop-in replacement for the real UIKit as possible. It also adapts some iOS user interface conventions to the Mac (such as UIAlertView being represented by NSAlert) so that apps built using Chameleon have as much chance as possible of feeling at home on the desktop with relatively little porting effort.
Chameleon requires OS X 10.6 or higher. Apps built with it have been proven to be acceptable to Apple for the Mac App Store. Chameleon was first built by [The Iconfactory](http://iconfactory.com/) to unify the codebase of [Twitterrific](http://www.twitterrific.com/) for both Mac and iOS.
The UIKit implementation mostly targets iOS 3.2's version of UIKit. Not everything is implemented at this time, but a surprisingly large subset is. There are some methods and/or behaviors from later versions of iOS implemented as well. Any UIKit methods that were deprecated around iOS 3.2 are not included.
As a general rule, if Apple's UIKit behaves in a certain way for some piece of code, that behavior should be considered correct even if you don't like how Apple's version does things. If Chameleon's behavior differs, Chameleon is wrong. That said, before immediately blaming problems on Chameleon, be absolutely sure that your code is, in fact, behaving differently than it would on Apple's implementation. Also be certain that there isn't a good reason Chameleon's behavior may differ. (An example of a difference that is intended is the behavior of UIAlertView - in Apple's UIKit, it is a UIView and has certain expected behaviors and capabilities as a result. In Chameleon, it is still a UIView, but it is presented as an NSAlert and that is simply how it should be to achieve a more native feel but it also means any UIView tricks that may have worked with a UIAlertView on iOS will not work the same under Chameleon. UIActionSheet and UITextView are other examples of areas that have sometimes large but intentional differences.)
## Usage
Chameleon is actually a collection of several frameworks, the largest of which is UIKit. The others are mostly stubs that made porting simple demos and test apps from iOS very simple with minimal (in some cases, zero) code changes and may or may not be necessary for you.
The Xcode projects build embeddable frameworks which can then be bundled within your own app's bundle and distributed in a self-contained way.
## Design
The UIKit port in Chameleon starts at a very low level and attempts to go so far as to even route UIEvent objects along a similar path starting in the single UIApplication instance and getting routed from there to the correct UIWindows and UIViews.
The interface between AppKit's NSViews and NSWindows and Chameleon's UIWindow and UIViews occurs at the "screen" level. UIKitView is an NSView which you add to your NSView hierarchy in whatever way you want. The UIKitView hosts a UIScreen instance which is home to UIKit's interface elements.
Each UIWindow belongs to a UIScreen, and UIViews must exist on UIWindows. This should mostly work the same as you've come to expect on iOS. An important thing to note is that Mac applications often have more than one window. If you use more than one UIKitView in your app, be aware that this means your application now has more than one UIScreen and as a result some methods such as [UIScreen mainScreen] may suddenly do unexpected things. When porting Twitterrific from iOS, this was one source of unexpected bugs as a few things were making assumptions about there only being a single, main screen since that is normal on current iOS devices.
Once a UIKitView exists and there's a UIScreen available to work with, your code can proceed to build a UIWindow and UIViews on top of it and be largely unaware that it is actually running on OSX instead of iOS. For those cases where you need to customize some UI, `UIUserInterfaceIdiomDesktop` has been added so that your code can differentiate between running on a pad, phone, or desktop in a consistent way. To keep code cross platform, the following is a good way to structure things so that Apple's UIKit doesn't encounter the unknown `UIUserInterfaceIdiomDesktop` symbol when compiling for iOS:
if (UI_USER_INTERFACE_IDIOM() == UIUserInterfaceIdiomPhone) {
// iPhone
} else if (UI_USER_INTERFACE_IDIOM() == UIUserInterfaceIdiomPad) {
// iPad
} else {
// Mac
}
(You can always use #ifdef or other compile-time approaches for platform differentiation, too - especially since a Mac app built with Chameleon doesn't need to adapt to multiple UI idioms at runtime the way a universal iOS app does. I just find it nice to have a similar pattern for all 3 idioms - but maybe that's just me.)
You can usually just create an instance of your iOS app's UIApplicationDelegate object and then pass it into UIKitView's helper method `-launchApplicationWithDelegate:afterDelay:` which will emulate the startup process of an iOS app (it will even attempt to show a Default.png if a delay is given). You might perform this step in your NSApplicationDelegate object's `-applicationDidFinishLaunching:` method. It is not necessary to use UIKitView's helper method to "launch" your app, but it can be a good way to get started.
Generally the interfaces to the classes are the same as Apple's documented interfaces. Some objects have additional methods that are useful for OS X and are defined in `(ClassName)AppKitIntegration.h` headers which are not included by the standard `UIKit.h` header. To easily include all AppKit extensions into your code, import `UIKit/AppKitIntegration.h` when compiling on OS X. There are also a couple of non-standard UI classes defined such as UIKey and UIViewAdapter that I designed out of necessity. (Keyboard handling in particular is a weak spot of Apple's current UIKit and so I developed my own rough API in place of anything "official" being documented by Apple.)
## Examples
Right now there's hardly any demos or examples or documentation. There's a simple app called BigApple in the Examples folder which might be enough to get started. It also shows how the UIKit Xcode project can be referenced from another Xcode project and setup as a dependency so that it is built automatically when the BigApple project is built.
## Authors
The Chameleon project was created by Sean Heber (Twitter: [@BigZaphod](http://twitter.com/BigZaphod/)) of The Iconfactory and he wrote nearly all of the initial version over several months. Craig Hockenberry (Twitter: [@chockenberry](http://twitter.com/chockenberry/)) was the first user/tester of Chameleon and found many holes and edge cases in the first implementation.
## License
Copyright (c) 2011, The Iconfactory. All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
1. Redistributions of source code must retain the above copyright
notice, this list of conditions and the following disclaimer.
2. Redistributions in binary form must reproduce the above copyright notice,
this list of conditions and the following disclaimer in the documentation
and/or other materials provided with the distribution.
3. Neither the name of The Iconfactory nor the names of its contributors may
be used to endorse or promote products derived from this software without
specific prior written permission.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
DISCLAIMED. IN NO EVENT SHALL THE ICONFACTORY BE LIABLE FOR ANY DIRECT,
INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
================================================
FILE: Examples/Chameleon Demo/Chameleon/StoreKit/Classes/SKPayment.h
================================================
/*
* Copyright (c) 2011, The Iconfactory. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of The Iconfactory nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE ICONFACTORY BE LIABLE FOR ANY DIRECT,
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
* OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#import
@interface SKPayment : NSObject {
}
+ (id)paymentWithProductIdentifier:(NSString *)identifier;
@property (nonatomic, readonly) NSString *productIdentifier;
@end
================================================
FILE: Examples/Chameleon Demo/Chameleon/StoreKit/Classes/SKPayment.m
================================================
/*
* Copyright (c) 2011, The Iconfactory. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of The Iconfactory nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE ICONFACTORY BE LIABLE FOR ANY DIRECT,
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
* OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#import "SKPayment.h"
@implementation SKPayment
+ (id)paymentWithProductIdentifier:(NSString *)identifier
{
return nil;
}
- (NSString *)productIdentifier
{
return nil;
}
@end
================================================
FILE: Examples/Chameleon Demo/Chameleon/StoreKit/Classes/SKPaymentQueue.h
================================================
/*
* Copyright (c) 2011, The Iconfactory. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of The Iconfactory nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE ICONFACTORY BE LIABLE FOR ANY DIRECT,
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
* OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#import
@class SKPayment, SKPaymentTransaction;
@protocol SKPaymentTransactionObserver
@end
@interface SKPaymentQueue : NSObject {
}
+ (BOOL)canMakePayments;
+ (SKPaymentQueue *)defaultQueue;
- (void)addTransactionObserver:(id)observer;
- (void)removeTransactionObserver:(id)observer;
- (void)addPayment:(SKPayment *)payment;
- (void)finishTransaction:(SKPaymentTransaction *)transaction;
- (void)restoreCompletedTransactions;
@property(nonatomic, readonly) NSArray *transactions;
@end
================================================
FILE: Examples/Chameleon Demo/Chameleon/StoreKit/Classes/SKPaymentQueue.m
================================================
/*
* Copyright (c) 2011, The Iconfactory. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of The Iconfactory nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE ICONFACTORY BE LIABLE FOR ANY DIRECT,
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
* OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#import "SKPaymentQueue.h"
@implementation SKPaymentQueue
+ (BOOL)canMakePayments
{
return NO;
}
+ (SKPaymentQueue *)defaultQueue
{
return nil;
}
- (void)addTransactionObserver:(id)observer
{
}
- (void)removeTransactionObserver:(id)observer
{
}
- (void)addPayment:(SKPayment *)payment
{
}
- (void)finishTransaction:(SKPaymentTransaction *)transaction
{
}
- (void)restoreCompletedTransactions
{
}
- (NSArray *)transactions
{
return nil;
}
@end
================================================
FILE: Examples/Chameleon Demo/Chameleon/StoreKit/Classes/SKPaymentTransaction.h
================================================
/*
* Copyright (c) 2011, The Iconfactory. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of The Iconfactory nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE ICONFACTORY BE LIABLE FOR ANY DIRECT,
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
* OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#import
@class SKPayment, SKPaymentTransaction;
enum {
SKPaymentTransactionStatePurchasing,
SKPaymentTransactionStatePurchased,
SKPaymentTransactionStateFailed,
SKPaymentTransactionStateRestored
};
typedef NSInteger SKPaymentTransactionState;
@interface SKPaymentTransaction : NSObject {
}
@property (nonatomic, readonly) NSError *error;
@property (nonatomic, readonly) SKPayment *payment;
@property (nonatomic, readonly) SKPaymentTransactionState transactionState;
@property (nonatomic, readonly) NSString *transactionIdentifier;
@property (nonatomic, readonly) NSData *transactionReceipt;
@property (nonatomic, readonly) NSDate *transactionDate;
@property (nonatomic, readonly) SKPaymentTransaction *originalTransaction;
@end
================================================
FILE: Examples/Chameleon Demo/Chameleon/StoreKit/Classes/SKPaymentTransaction.m
================================================
/*
* Copyright (c) 2011, The Iconfactory. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of The Iconfactory nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE ICONFACTORY BE LIABLE FOR ANY DIRECT,
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
* OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#import "SKPaymentTransaction.h"
@implementation SKPaymentTransaction
- (NSError *)error
{
return nil;
}
- (SKPayment *)payment
{
return nil;
}
- (SKPaymentTransactionState)transactionState
{
return SKPaymentTransactionStateFailed;
}
- (NSString *)transactionIdentifier
{
return nil;
}
- (NSData *)transactionReceipt
{
return nil;
}
- (NSDate *)transactionDate
{
return nil;
}
- (SKPaymentTransaction *)originalTransaction
{
return nil;
}
@end
================================================
FILE: Examples/Chameleon Demo/Chameleon/StoreKit/Classes/SKProduct.h
================================================
/*
* Copyright (c) 2011, The Iconfactory. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of The Iconfactory nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE ICONFACTORY BE LIABLE FOR ANY DIRECT,
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
* OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#import
@interface SKProduct : NSObject {
}
@property (nonatomic, readonly) NSString *productIdentifier;
@property (nonatomic, readonly) NSString *localizedTitle;
@property (nonatomic, readonly) NSString *localizedDescription;
@property (nonatomic, readonly) NSDecimalNumber *price;
@property (nonatomic, readonly) NSLocale *priceLocale;
@end
================================================
FILE: Examples/Chameleon Demo/Chameleon/StoreKit/Classes/SKProduct.m
================================================
/*
* Copyright (c) 2011, The Iconfactory. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of The Iconfactory nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE ICONFACTORY BE LIABLE FOR ANY DIRECT,
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
* OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#import "SKProduct.h"
@implementation SKProduct
- (NSString *)productIdentifier
{
return nil;
}
- (NSString *)localizedTitle;
{
return nil;
}
- (NSString *)localizedDescription;
{
return nil;
}
- (NSDecimalNumber *)price;
{
return nil;
}
- (NSLocale *)priceLocale
{
return nil;
}
@end
================================================
FILE: Examples/Chameleon Demo/Chameleon/StoreKit/Classes/SKProductsRequest.h
================================================
/*
* Copyright (c) 2011, The Iconfactory. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of The Iconfactory nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE ICONFACTORY BE LIABLE FOR ANY DIRECT,
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
* OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#import "SKRequest.h"
@protocol SKProductsRequestDelegate
@end
@interface SKProductsRequest : SKRequest {
}
- (id)initWithProductIdentifiers:(NSSet *)productIdentifiers;
- (void)start;
- (void)cancel;
@property(nonatomic, assign) id delegate;
@end
================================================
FILE: Examples/Chameleon Demo/Chameleon/StoreKit/Classes/SKProductsRequest.m
================================================
/*
* Copyright (c) 2011, The Iconfactory. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of The Iconfactory nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE ICONFACTORY BE LIABLE FOR ANY DIRECT,
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
* OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#import "SKProductsRequest.h"
@implementation SKProductsRequest
@dynamic delegate;
- (id)initWithProductIdentifiers:(NSSet *)productIdentifiers
{
if ((self=[super init])) {
}
return self;
}
- (void)start
{
}
- (void)cancel
{
}
@end
================================================
FILE: Examples/Chameleon Demo/Chameleon/StoreKit/Classes/SKProductsResponse.h
================================================
/*
* Copyright (c) 2011, The Iconfactory. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of The Iconfactory nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE ICONFACTORY BE LIABLE FOR ANY DIRECT,
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
* OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#import
@interface SKProductsResponse : NSObject {
}
@property (nonatomic, readonly) NSArray *products;
@property (nonatomic, readonly) NSArray *invalidProductIdentifiers;
@end
================================================
FILE: Examples/Chameleon Demo/Chameleon/StoreKit/Classes/SKProductsResponse.m
================================================
/*
* Copyright (c) 2011, The Iconfactory. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of The Iconfactory nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE ICONFACTORY BE LIABLE FOR ANY DIRECT,
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
* OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#import "SKProductsResponse.h"
@implementation SKProductsResponse
- (NSArray *)products
{
return nil;
}
- (NSArray *)invalidProductIdentifiers
{
return nil;
}
@end
================================================
FILE: Examples/Chameleon Demo/Chameleon/StoreKit/Classes/SKRequest.h
================================================
/*
* Copyright (c) 2011, The Iconfactory. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of The Iconfactory nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE ICONFACTORY BE LIABLE FOR ANY DIRECT,
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
* OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#import
@protocol SKRequestDelegate
@end
@interface SKRequest : NSObject {
@private
__unsafe_unretained id _delegate;
}
@property(nonatomic, assign) id delegate;
@end
================================================
FILE: Examples/Chameleon Demo/Chameleon/StoreKit/Classes/SKRequest.m
================================================
/*
* Copyright (c) 2011, The Iconfactory. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of The Iconfactory nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE ICONFACTORY BE LIABLE FOR ANY DIRECT,
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
* OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#import "SKRequest.h"
@implementation SKRequest
@synthesize delegate=_delegate;
@end
================================================
FILE: Examples/Chameleon Demo/Chameleon/StoreKit/Classes/StoreKit.h
================================================
/*
* Copyright (c) 2011, The Iconfactory. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of The Iconfactory nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE ICONFACTORY BE LIABLE FOR ANY DIRECT,
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
* OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
enum {
SKErrorUnknown,
SKErrorClientInvalid,
SKErrorPaymentCancelled,
SKErrorPaymentInvalid,
SKErrorPaymentNotAllowed
};
#import "SKProduct.h"
#import "SKRequest.h"
#import "SKProductsRequest.h"
#import "SKPaymentQueue.h"
#import "SKPayment.h"
#import "SKPaymentTransaction.h"
#import "SKProductsResponse.h"
================================================
FILE: Examples/Chameleon Demo/Chameleon/StoreKit/Info.plist
================================================
CFBundleDevelopmentRegionEnglishCFBundleExecutable${EXECUTABLE_NAME}CFBundleName${PRODUCT_NAME}CFBundleIconFileCFBundleIdentifierorg.chameleonproject.StoreKitCFBundleInfoDictionaryVersion6.0CFBundlePackageTypeFMWKCFBundleSignature????CFBundleVersion1CFBundleShortVersionString1.0NSPrincipalClass
================================================
FILE: Examples/Chameleon Demo/Chameleon/StoreKit/StoreKit.xcodeproj/project.pbxproj
================================================
// !$*UTF8*$!
{
archiveVersion = 1;
classes = {
};
objectVersion = 46;
objects = {
/* Begin PBXBuildFile section */
1436CFFB12147A91001DFEFB /* SKProduct.h in Headers */ = {isa = PBXBuildFile; fileRef = 1436CFF612147A91001DFEFB /* SKProduct.h */; settings = {ATTRIBUTES = (Public, ); }; };
1436CFFC12147A91001DFEFB /* SKProduct.m in Sources */ = {isa = PBXBuildFile; fileRef = 1436CFF712147A91001DFEFB /* SKProduct.m */; };
1436CFFD12147A91001DFEFB /* SKRequest.h in Headers */ = {isa = PBXBuildFile; fileRef = 1436CFF812147A91001DFEFB /* SKRequest.h */; settings = {ATTRIBUTES = (Public, ); }; };
1436CFFE12147A91001DFEFB /* SKRequest.m in Sources */ = {isa = PBXBuildFile; fileRef = 1436CFF912147A91001DFEFB /* SKRequest.m */; };
1436CFFF12147A91001DFEFB /* StoreKit.h in Headers */ = {isa = PBXBuildFile; fileRef = 1436CFFA12147A91001DFEFB /* StoreKit.h */; settings = {ATTRIBUTES = (Public, ); }; };
1436D00212147ABE001DFEFB /* SKProductsRequest.h in Headers */ = {isa = PBXBuildFile; fileRef = 1436D00012147ABE001DFEFB /* SKProductsRequest.h */; settings = {ATTRIBUTES = (Public, ); }; };
1436D00312147ABE001DFEFB /* SKProductsRequest.m in Sources */ = {isa = PBXBuildFile; fileRef = 1436D00112147ABE001DFEFB /* SKProductsRequest.m */; };
1436D00E12147B21001DFEFB /* SKPaymentQueue.h in Headers */ = {isa = PBXBuildFile; fileRef = 1436D00C12147B21001DFEFB /* SKPaymentQueue.h */; settings = {ATTRIBUTES = (Public, ); }; };
1436D00F12147B21001DFEFB /* SKPaymentQueue.m in Sources */ = {isa = PBXBuildFile; fileRef = 1436D00D12147B21001DFEFB /* SKPaymentQueue.m */; };
1436D04712147C74001DFEFB /* SKPayment.h in Headers */ = {isa = PBXBuildFile; fileRef = 1436D04512147C74001DFEFB /* SKPayment.h */; settings = {ATTRIBUTES = (Public, ); }; };
1436D04812147C74001DFEFB /* SKPayment.m in Sources */ = {isa = PBXBuildFile; fileRef = 1436D04612147C74001DFEFB /* SKPayment.m */; };
1436D05912147D11001DFEFB /* SKPaymentTransaction.h in Headers */ = {isa = PBXBuildFile; fileRef = 1436D05712147D11001DFEFB /* SKPaymentTransaction.h */; settings = {ATTRIBUTES = (Public, ); }; };
1436D05A12147D11001DFEFB /* SKPaymentTransaction.m in Sources */ = {isa = PBXBuildFile; fileRef = 1436D05812147D11001DFEFB /* SKPaymentTransaction.m */; };
1436D07312147E51001DFEFB /* SKProductsResponse.h in Headers */ = {isa = PBXBuildFile; fileRef = 1436D07112147E51001DFEFB /* SKProductsResponse.h */; settings = {ATTRIBUTES = (Public, ); }; };
1436D07412147E51001DFEFB /* SKProductsResponse.m in Sources */ = {isa = PBXBuildFile; fileRef = 1436D07212147E51001DFEFB /* SKProductsResponse.m */; };
14EFB1BB1211DB5300D19B0C /* Cocoa.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 14EFB1BA1211DB5300D19B0C /* Cocoa.framework */; };
/* End PBXBuildFile section */
/* Begin PBXFileReference section */
0867D69BFE84028FC02AAC07 /* Foundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Foundation.framework; path = /System/Library/Frameworks/Foundation.framework; sourceTree = ""; };
0867D6A5FE840307C02AAC07 /* AppKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = AppKit.framework; path = /System/Library/Frameworks/AppKit.framework; sourceTree = ""; };
1436CFC912147935001DFEFB /* StoreKit_Prefix.pch */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = StoreKit_Prefix.pch; sourceTree = ""; };
1436CFF612147A91001DFEFB /* SKProduct.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SKProduct.h; sourceTree = ""; };
1436CFF712147A91001DFEFB /* SKProduct.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SKProduct.m; sourceTree = ""; };
1436CFF812147A91001DFEFB /* SKRequest.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SKRequest.h; sourceTree = ""; };
1436CFF912147A91001DFEFB /* SKRequest.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SKRequest.m; sourceTree = ""; };
1436CFFA12147A91001DFEFB /* StoreKit.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = StoreKit.h; sourceTree = ""; };
1436D00012147ABE001DFEFB /* SKProductsRequest.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SKProductsRequest.h; sourceTree = ""; };
1436D00112147ABE001DFEFB /* SKProductsRequest.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SKProductsRequest.m; sourceTree = ""; };
1436D00C12147B21001DFEFB /* SKPaymentQueue.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SKPaymentQueue.h; sourceTree = ""; };
1436D00D12147B21001DFEFB /* SKPaymentQueue.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SKPaymentQueue.m; sourceTree = ""; };
1436D04512147C74001DFEFB /* SKPayment.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SKPayment.h; sourceTree = ""; };
1436D04612147C74001DFEFB /* SKPayment.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SKPayment.m; sourceTree = ""; };
1436D05712147D11001DFEFB /* SKPaymentTransaction.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SKPaymentTransaction.h; sourceTree = ""; };
1436D05812147D11001DFEFB /* SKPaymentTransaction.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SKPaymentTransaction.m; sourceTree = ""; };
1436D07112147E51001DFEFB /* SKProductsResponse.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SKProductsResponse.h; sourceTree = ""; };
1436D07212147E51001DFEFB /* SKProductsResponse.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SKProductsResponse.m; sourceTree = ""; };
14EFB1BA1211DB5300D19B0C /* Cocoa.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Cocoa.framework; path = System/Library/Frameworks/Cocoa.framework; sourceTree = SDKROOT; };
8DC2EF5A0486A6940098B216 /* Info.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; };
8DC2EF5B0486A6940098B216 /* StoreKit.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = StoreKit.framework; sourceTree = BUILT_PRODUCTS_DIR; };
/* End PBXFileReference section */
/* Begin PBXFrameworksBuildPhase section */
8DC2EF560486A6940098B216 /* Frameworks */ = {
isa = PBXFrameworksBuildPhase;
buildActionMask = 2147483647;
files = (
14EFB1BB1211DB5300D19B0C /* Cocoa.framework in Frameworks */,
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXFrameworksBuildPhase section */
/* Begin PBXGroup section */
034768DFFF38A50411DB9C8B /* Products */ = {
isa = PBXGroup;
children = (
8DC2EF5B0486A6940098B216 /* StoreKit.framework */,
);
name = Products;
sourceTree = "";
};
0867D691FE84028FC02AAC07 /* UIKit */ = {
isa = PBXGroup;
children = (
08FB77AEFE84172EC02AAC07 /* Classes */,
089C1665FE841158C02AAC07 /* Resources */,
32C88DFF0371C24200C91783 /* Other Sources */,
0867D69AFE84028FC02AAC07 /* External Frameworks and Libraries */,
034768DFFF38A50411DB9C8B /* Products */,
);
name = UIKit;
sourceTree = "";
};
0867D69AFE84028FC02AAC07 /* External Frameworks and Libraries */ = {
isa = PBXGroup;
children = (
0867D6A5FE840307C02AAC07 /* AppKit.framework */,
0867D69BFE84028FC02AAC07 /* Foundation.framework */,
14EFB1BA1211DB5300D19B0C /* Cocoa.framework */,
);
name = "External Frameworks and Libraries";
sourceTree = "";
};
089C1665FE841158C02AAC07 /* Resources */ = {
isa = PBXGroup;
children = (
8DC2EF5A0486A6940098B216 /* Info.plist */,
);
name = Resources;
sourceTree = "";
};
08FB77AEFE84172EC02AAC07 /* Classes */ = {
isa = PBXGroup;
children = (
1436CFF612147A91001DFEFB /* SKProduct.h */,
1436CFF712147A91001DFEFB /* SKProduct.m */,
1436CFF812147A91001DFEFB /* SKRequest.h */,
1436CFF912147A91001DFEFB /* SKRequest.m */,
1436CFFA12147A91001DFEFB /* StoreKit.h */,
1436D00012147ABE001DFEFB /* SKProductsRequest.h */,
1436D00112147ABE001DFEFB /* SKProductsRequest.m */,
1436D00C12147B21001DFEFB /* SKPaymentQueue.h */,
1436D00D12147B21001DFEFB /* SKPaymentQueue.m */,
1436D04512147C74001DFEFB /* SKPayment.h */,
1436D04612147C74001DFEFB /* SKPayment.m */,
1436D05712147D11001DFEFB /* SKPaymentTransaction.h */,
1436D05812147D11001DFEFB /* SKPaymentTransaction.m */,
1436D07112147E51001DFEFB /* SKProductsResponse.h */,
1436D07212147E51001DFEFB /* SKProductsResponse.m */,
);
path = Classes;
sourceTree = "";
};
32C88DFF0371C24200C91783 /* Other Sources */ = {
isa = PBXGroup;
children = (
1436CFC912147935001DFEFB /* StoreKit_Prefix.pch */,
);
name = "Other Sources";
sourceTree = "";
};
/* End PBXGroup section */
/* Begin PBXHeadersBuildPhase section */
8DC2EF500486A6940098B216 /* Headers */ = {
isa = PBXHeadersBuildPhase;
buildActionMask = 2147483647;
files = (
1436CFFF12147A91001DFEFB /* StoreKit.h in Headers */,
1436CFFB12147A91001DFEFB /* SKProduct.h in Headers */,
1436CFFD12147A91001DFEFB /* SKRequest.h in Headers */,
1436D00212147ABE001DFEFB /* SKProductsRequest.h in Headers */,
1436D00E12147B21001DFEFB /* SKPaymentQueue.h in Headers */,
1436D04712147C74001DFEFB /* SKPayment.h in Headers */,
1436D05912147D11001DFEFB /* SKPaymentTransaction.h in Headers */,
1436D07312147E51001DFEFB /* SKProductsResponse.h in Headers */,
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXHeadersBuildPhase section */
/* Begin PBXNativeTarget section */
8DC2EF4F0486A6940098B216 /* StoreKit */ = {
isa = PBXNativeTarget;
buildConfigurationList = 1DEB91AD08733DA50010E9CD /* Build configuration list for PBXNativeTarget "StoreKit" */;
buildPhases = (
8DC2EF500486A6940098B216 /* Headers */,
8DC2EF520486A6940098B216 /* Resources */,
8DC2EF540486A6940098B216 /* Sources */,
8DC2EF560486A6940098B216 /* Frameworks */,
);
buildRules = (
);
dependencies = (
);
name = StoreKit;
productInstallPath = "$(HOME)/Library/Frameworks";
productName = UIKit;
productReference = 8DC2EF5B0486A6940098B216 /* StoreKit.framework */;
productType = "com.apple.product-type.framework";
};
/* End PBXNativeTarget section */
/* Begin PBXProject section */
0867D690FE84028FC02AAC07 /* Project object */ = {
isa = PBXProject;
attributes = {
LastUpgradeCheck = 0500;
};
buildConfigurationList = 1DEB91B108733DA50010E9CD /* Build configuration list for PBXProject "StoreKit" */;
compatibilityVersion = "Xcode 3.2";
developmentRegion = English;
hasScannedForEncodings = 1;
knownRegions = (
English,
Japanese,
French,
German,
);
mainGroup = 0867D691FE84028FC02AAC07 /* UIKit */;
productRefGroup = 034768DFFF38A50411DB9C8B /* Products */;
projectDirPath = "";
projectRoot = "";
targets = (
8DC2EF4F0486A6940098B216 /* StoreKit */,
);
};
/* End PBXProject section */
/* Begin PBXResourcesBuildPhase section */
8DC2EF520486A6940098B216 /* Resources */ = {
isa = PBXResourcesBuildPhase;
buildActionMask = 2147483647;
files = (
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXResourcesBuildPhase section */
/* Begin PBXSourcesBuildPhase section */
8DC2EF540486A6940098B216 /* Sources */ = {
isa = PBXSourcesBuildPhase;
buildActionMask = 2147483647;
files = (
1436CFFC12147A91001DFEFB /* SKProduct.m in Sources */,
1436CFFE12147A91001DFEFB /* SKRequest.m in Sources */,
1436D00312147ABE001DFEFB /* SKProductsRequest.m in Sources */,
1436D00F12147B21001DFEFB /* SKPaymentQueue.m in Sources */,
1436D04812147C74001DFEFB /* SKPayment.m in Sources */,
1436D05A12147D11001DFEFB /* SKPaymentTransaction.m in Sources */,
1436D07412147E51001DFEFB /* SKProductsResponse.m in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXSourcesBuildPhase section */
/* Begin XCBuildConfiguration section */
1DEB91AE08733DA50010E9CD /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
COMBINE_HIDPI_IMAGES = YES;
COPY_PHASE_STRIP = NO;
DYLIB_COMPATIBILITY_VERSION = 1;
DYLIB_CURRENT_VERSION = 1;
FRAMEWORK_VERSION = A;
GCC_DYNAMIC_NO_PIC = NO;
GCC_MODEL_TUNING = G5;
GCC_OPTIMIZATION_LEVEL = 0;
GCC_PRECOMPILE_PREFIX_HEADER = YES;
GCC_PREFIX_HEADER = StoreKit_Prefix.pch;
GCC_VERSION = com.apple.compilers.llvm.clang.1_0;
INFOPLIST_FILE = Info.plist;
INSTALL_PATH = "@executable_path/../Frameworks";
PRODUCT_NAME = StoreKit;
SYMROOT = ../build;
VALID_ARCHS = "i386 x86_64";
WRAPPER_EXTENSION = framework;
};
name = Debug;
};
1DEB91AF08733DA50010E9CD /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
COMBINE_HIDPI_IMAGES = YES;
DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
DYLIB_COMPATIBILITY_VERSION = 1;
DYLIB_CURRENT_VERSION = 1;
FRAMEWORK_VERSION = A;
GCC_MODEL_TUNING = G5;
GCC_PRECOMPILE_PREFIX_HEADER = YES;
GCC_PREFIX_HEADER = StoreKit_Prefix.pch;
GCC_VERSION = com.apple.compilers.llvm.clang.1_0;
INFOPLIST_FILE = Info.plist;
INSTALL_PATH = "@executable_path/../Frameworks";
PRODUCT_NAME = StoreKit;
SYMROOT = ../build;
VALID_ARCHS = "i386 x86_64";
WRAPPER_EXTENSION = framework;
};
name = Release;
};
1DEB91B208733DA50010E9CD /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
GCC_C_LANGUAGE_STANDARD = gnu99;
GCC_OPTIMIZATION_LEVEL = 0;
GCC_WARN_ABOUT_MISSING_PROTOTYPES = YES;
GCC_WARN_ABOUT_RETURN_TYPE = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
MACOSX_DEPLOYMENT_TARGET = 10.7;
ONLY_ACTIVE_ARCH = YES;
SDKROOT = macosx;
};
name = Debug;
};
1DEB91B308733DA50010E9CD /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
CODE_SIGN_IDENTITY = "Developer ID Application: The Iconfactory";
GCC_C_LANGUAGE_STANDARD = gnu99;
GCC_WARN_ABOUT_MISSING_PROTOTYPES = YES;
GCC_WARN_ABOUT_RETURN_TYPE = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
MACOSX_DEPLOYMENT_TARGET = 10.7;
PROVISIONING_PROFILE = "";
SDKROOT = macosx;
};
name = Release;
};
/* End XCBuildConfiguration section */
/* Begin XCConfigurationList section */
1DEB91AD08733DA50010E9CD /* Build configuration list for PBXNativeTarget "StoreKit" */ = {
isa = XCConfigurationList;
buildConfigurations = (
1DEB91AE08733DA50010E9CD /* Debug */,
1DEB91AF08733DA50010E9CD /* Release */,
);
defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release;
};
1DEB91B108733DA50010E9CD /* Build configuration list for PBXProject "StoreKit" */ = {
isa = XCConfigurationList;
buildConfigurations = (
1DEB91B208733DA50010E9CD /* Debug */,
1DEB91B308733DA50010E9CD /* Release */,
);
defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release;
};
/* End XCConfigurationList section */
};
rootObject = 0867D690FE84028FC02AAC07 /* Project object */;
}
================================================
FILE: Examples/Chameleon Demo/Chameleon/StoreKit/StoreKit.xcodeproj/project.xcworkspace/contents.xcworkspacedata
================================================
================================================
FILE: Examples/Chameleon Demo/Chameleon/StoreKit/StoreKit_Prefix.pch
================================================
/*
* Copyright (c) 2011, The Iconfactory. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of The Iconfactory nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE ICONFACTORY BE LIABLE FOR ANY DIRECT,
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
* OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#ifdef __OBJC__
#import
#endif
================================================
FILE: Examples/Chameleon Demo/Chameleon/UIKit/.gitignore
================================================
.DS_Store
*.xcodeproj/*.pbxuser
*.xcodeproj/*.perspectivev3
*.xcodeproj/xcuserdata
*.xcodeproj/project.xcworkspace/xcuserdata
================================================
FILE: Examples/Chameleon Demo/Chameleon/UIKit/Classes/AppKitIntegration.h
================================================
/*
* Copyright (c) 2011, The Iconfactory. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of The Iconfactory nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE ICONFACTORY BE LIABLE FOR ANY DIRECT,
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
* OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#import "UIColorAppKitIntegration.h"
#import "UIFontAppKitIntegration.h"
#import "UIImageAppKitIntegration.h"
#import "UIResponderAppKitIntegration.h"
#import "UIScreenAppKitIntegration.h"
#import "UIActionSheetAppKitIntegration.h"
#import "UIApplicationAppKitIntegration.h"
================================================
FILE: Examples/Chameleon Demo/Chameleon/UIKit/Classes/NSIndexPath+UITableView.h
================================================
/*
* Copyright (c) 2011, The Iconfactory. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of The Iconfactory nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE ICONFACTORY BE LIABLE FOR ANY DIRECT,
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
* OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#import
@interface NSIndexPath (UITableView)
+ (NSIndexPath *)indexPathForRow:(NSUInteger)row inSection:(NSUInteger)section;
@property (readonly) NSUInteger row;
@property (readonly) NSUInteger section;
@end
================================================
FILE: Examples/Chameleon Demo/Chameleon/UIKit/Classes/NSIndexPath+UITableView.m
================================================
/*
* Copyright (c) 2011, The Iconfactory. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of The Iconfactory nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE ICONFACTORY BE LIABLE FOR ANY DIRECT,
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
* OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#import "NSIndexPath+UITableView.h"
@implementation NSIndexPath (UITableView)
+ (NSIndexPath *)indexPathForRow:(NSUInteger)row inSection:(NSUInteger)section
{
NSUInteger path[2] = {section, row};
return [self indexPathWithIndexes:path length:2];
}
- (NSUInteger)row
{
return [self indexAtPosition:1];
}
-(NSUInteger)section
{
return [self indexAtPosition:0];
}
@end
================================================
FILE: Examples/Chameleon Demo/Chameleon/UIKit/Classes/UIAcceleration.h
================================================
/*
* Copyright (c) 2011, The Iconfactory. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of The Iconfactory nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE ICONFACTORY BE LIABLE FOR ANY DIRECT,
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
* OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#import
typedef double UIAccelerationValue;
@interface UIAcceleration : NSObject {
UIAccelerationValue _x;
UIAccelerationValue _y;
UIAccelerationValue _z;
NSTimeInterval _timestamp;
}
@property (nonatomic, readonly) UIAccelerationValue x;
@property (nonatomic, readonly) UIAccelerationValue y;
@property (nonatomic, readonly) UIAccelerationValue z;
@property (nonatomic, readonly) NSTimeInterval timestamp;
@end
================================================
FILE: Examples/Chameleon Demo/Chameleon/UIKit/Classes/UIAcceleration.m
================================================
/*
* Copyright (c) 2011, The Iconfactory. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of The Iconfactory nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE ICONFACTORY BE LIABLE FOR ANY DIRECT,
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
* OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#import "UIAcceleration.h"
@implementation UIAcceleration
@synthesize x=_x, y=_y, z=_z, timestamp=_timestamp;
@end
================================================
FILE: Examples/Chameleon Demo/Chameleon/UIKit/Classes/UIAccelerometer.h
================================================
/*
* Copyright (c) 2011, The Iconfactory. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of The Iconfactory nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE ICONFACTORY BE LIABLE FOR ANY DIRECT,
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
* OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#import
@class UIAccelerometer, UIAcceleration;
@protocol UIAccelerometerDelegate
- (void)accelerometer:(UIAccelerometer *)accelerometer didAccelerate:(UIAcceleration *)acceleration;
@end
@interface UIAccelerometer : NSObject {
@private
NSTimeInterval _updateInterval;
__unsafe_unretained id _delegate;
}
+ (UIAccelerometer *)sharedAccelerometer;
@property (nonatomic, assign) id delegate;
@property (nonatomic) NSTimeInterval updateInterval;
@end
================================================
FILE: Examples/Chameleon Demo/Chameleon/UIKit/Classes/UIAccelerometer.m
================================================
/*
* Copyright (c) 2011, The Iconfactory. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of The Iconfactory nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE ICONFACTORY BE LIABLE FOR ANY DIRECT,
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
* OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#import "UIAccelerometer.h"
@implementation UIAccelerometer
@synthesize updateInterval=_updateInterval, delegate=_delegate;
+ (UIAccelerometer *)sharedAccelerometer
{
return nil;
}
@end
================================================
FILE: Examples/Chameleon Demo/Chameleon/UIKit/Classes/UIAccessibility.h
================================================
/*
* Copyright (c) 2011, The Iconfactory. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of The Iconfactory nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE ICONFACTORY BE LIABLE FOR ANY DIRECT,
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
* OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#import
typedef uint64_t UIAccessibilityTraits;
extern UIAccessibilityTraits UIAccessibilityTraitNone;
extern UIAccessibilityTraits UIAccessibilityTraitButton;
extern UIAccessibilityTraits UIAccessibilityTraitLink;
extern UIAccessibilityTraits UIAccessibilityTraitSearchField;
extern UIAccessibilityTraits UIAccessibilityTraitImage;
extern UIAccessibilityTraits UIAccessibilityTraitSelected;
extern UIAccessibilityTraits UIAccessibilityTraitPlaysSound;
extern UIAccessibilityTraits UIAccessibilityTraitKeyboardKey;
extern UIAccessibilityTraits UIAccessibilityTraitStaticText;
extern UIAccessibilityTraits UIAccessibilityTraitSummaryElement;
extern UIAccessibilityTraits UIAccessibilityTraitNotEnabled;
extern UIAccessibilityTraits UIAccessibilityTraitUpdatesFrequently;
extern UIAccessibilityTraits UIAccessibilityTraitHeader;
extern UIAccessibilityTraits UIAccessibilityTraitAllowsDirectInteraction;
typedef uint32_t UIAccessibilityNotifications;
extern UIAccessibilityNotifications UIAccessibilityScreenChangedNotification;
extern UIAccessibilityNotifications UIAccessibilityLayoutChangedNotification;
extern UIAccessibilityNotifications UIAccessibilityAnnouncementNotification;
extern UIAccessibilityNotifications UIAccessibilityPageScrolledNotification;
@interface NSObject (UIAccessibility)
@property (nonatomic) BOOL isAccessibilityElement;
@property (nonatomic) NSString *accessibilityLabel;
@property (nonatomic) NSString *accessibilityHint;
@property (nonatomic) NSString *accessibilityValue;
@property (nonatomic) UIAccessibilityTraits accessibilityTraits;
@property (nonatomic) CGRect accessibilityFrame;
@property (nonatomic) BOOL accessibilityViewIsModal;
@property (nonatomic) BOOL accessibilityElementsHidden;
@end
@interface NSObject (UIAccessibilityContainer)
- (NSInteger)accessibilityElementCount;
- (id)accessibilityElementAtIndex:(NSInteger)index;
- (NSInteger)indexOfAccessibilityElement:(id)element;
@end
@interface NSObject (UIAccessibilityFocus)
- (void)accessibilityElementDidBecomeFocused;
- (void)accessibilityElementDidLoseFocus;
- (BOOL)accessibilityElementIsFocused;
@end
extern void UIAccessibilityPostNotification(UIAccessibilityNotifications notification, id argument);
extern BOOL UIAccessibilityIsVoiceOverRunning(void);
================================================
FILE: Examples/Chameleon Demo/Chameleon/UIKit/Classes/UIAccessibility.m
================================================
/*
* Copyright (c) 2011, The Iconfactory. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of The Iconfactory nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE ICONFACTORY BE LIABLE FOR ANY DIRECT,
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
* OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#import "UIAccessibility.h"
UIAccessibilityTraits UIAccessibilityTraitNone = 0;
UIAccessibilityTraits UIAccessibilityTraitButton = 1;
UIAccessibilityTraits UIAccessibilityTraitLink = 2;
UIAccessibilityTraits UIAccessibilityTraitImage = 4;
UIAccessibilityTraits UIAccessibilityTraitSelected = 8;
UIAccessibilityTraits UIAccessibilityTraitPlaysSound = 16;
UIAccessibilityTraits UIAccessibilityTraitKeyboardKey = 32;
UIAccessibilityTraits UIAccessibilityTraitStaticText = 64;
UIAccessibilityTraits UIAccessibilityTraitSummaryElement = 128;
UIAccessibilityTraits UIAccessibilityTraitNotEnabled = 256;
UIAccessibilityTraits UIAccessibilityTraitUpdatesFrequently = 512;
UIAccessibilityTraits UIAccessibilityTraitSearchField = 1024;
UIAccessibilityTraits UIAccessibilityTraitHeader = 2048;
UIAccessibilityTraits UIAccessibilityTraitAllowsDirectInteraction = 8192;
UIAccessibilityNotifications UIAccessibilityScreenChangedNotification = 1000;
UIAccessibilityNotifications UIAccessibilityLayoutChangedNotification = 1001;
UIAccessibilityNotifications UIAccessibilityAnnouncementNotification = 1002;
UIAccessibilityNotifications UIAccessibilityPageScrolledNotification = 1003;
@implementation NSObject (UIAccessibility)
- (BOOL)isAccessibilityElement
{
return NO;
}
- (void)setIsAccessibilityElement:(BOOL)isElement
{
}
- (NSString *)accessibilityLabel
{
return nil;
}
- (void)setAccessibilityLabel:(NSString *)label
{
}
- (NSString *)accessibilityHint
{
return nil;
}
- (void)setAccessibilityHint:(NSString *)hint
{
}
- (NSString *)accessibilityValue
{
return nil;
}
- (void)setAccessibilityValue:(NSString *)value
{
}
- (UIAccessibilityTraits)accessibilityTraits
{
return UIAccessibilityTraitNone; // STUB
}
- (void)setAccessibilityTraits:(UIAccessibilityTraits)traits
{
}
- (CGRect)accessibilityFrame
{
return CGRectNull;
}
- (void)setAccessibilityFrame:(CGRect)frame
{
}
- (BOOL)accessibilityViewIsModal
{
return NO;
}
- (void)setAccessibilityViewIsModal:(BOOL)isModal
{
}
- (BOOL)accessibilityElementsHidden
{
return NO;
}
- (void)setAccessibilityElementsHidden:(BOOL)accessibilityElementsHidden
{
}
@end
@implementation NSObject (UIAccessibilityContainer)
- (NSInteger)accessibilityElementCount
{
return 0;
}
- (id)accessibilityElementAtIndex:(NSInteger)index
{
return nil;
}
- (NSInteger)indexOfAccessibilityElement:(id)element
{
return NSNotFound;
}
@end
@implementation NSObject (UIAccessibilityFocus)
- (void)accessibilityElementDidBecomeFocused
{
}
- (void)accessibilityElementDidLoseFocus
{
}
- (BOOL)accessibilityElementIsFocused
{
return NO;
}
@end
void UIAccessibilityPostNotification(UIAccessibilityNotifications notification, id argument)
{
}
BOOL UIAccessibilityIsVoiceOverRunning()
{
return NO;
}
================================================
FILE: Examples/Chameleon Demo/Chameleon/UIKit/Classes/UIAccessibilityElement.h
================================================
/*
* Copyright (c) 2011, The Iconfactory. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of The Iconfactory nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE ICONFACTORY BE LIABLE FOR ANY DIRECT,
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
* OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#import "UIAccessibility.h"
@interface UIAccessibilityElement : NSObject {
NSString *_accessibilityLabel;
NSString *_accessibilityHint;
NSString *_accessibilityValue;
CGRect _accessibilityFrame;
UIAccessibilityTraits _accessibilityTraits;
}
- (id)initWithAccessibilityContainer:(id)container;
@property (nonatomic, strong) NSString *accessibilityLabel;
@property (nonatomic, strong) NSString *accessibilityHint;
@property (nonatomic, strong) NSString *accessibilityValue;
@property (nonatomic, assign) CGRect accessibilityFrame;
@property (nonatomic, assign) UIAccessibilityTraits accessibilityTraits;
@end
================================================
FILE: Examples/Chameleon Demo/Chameleon/UIKit/Classes/UIAccessibilityElement.m
================================================
/*
* Copyright (c) 2011, The Iconfactory. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of The Iconfactory nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE ICONFACTORY BE LIABLE FOR ANY DIRECT,
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
* OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#import "UIAccessibilityElement.h"
@implementation UIAccessibilityElement
@synthesize accessibilityLabel=_accessibilityLabel, accessibilityHint=_accessibilityHint, accessibilityValue=_accessibilityValue;
@synthesize accessibilityFrame=_accessibilityFrame, accessibilityTraits=_accessibilityTraits;
- (id)initWithAccessibilityContainer:(id)container
{
if ((self=[super init])) {
}
return self;
}
- (void)dealloc
{
[_accessibilityLabel release];
[_accessibilityHint release];
[_accessibilityValue release];
[super dealloc];
}
@end
================================================
FILE: Examples/Chameleon Demo/Chameleon/UIKit/Classes/UIAction.h
================================================
/*
* Copyright (c) 2011, The Iconfactory. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of The Iconfactory nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE ICONFACTORY BE LIABLE FOR ANY DIRECT,
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
* OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#import
@interface UIAction : NSObject {
__unsafe_unretained id _target;
SEL _action;
}
@property (nonatomic, assign) id target;
@property (nonatomic, assign) SEL action;
@end
================================================
FILE: Examples/Chameleon Demo/Chameleon/UIKit/Classes/UIAction.m
================================================
/*
* Copyright (c) 2011, The Iconfactory. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of The Iconfactory nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE ICONFACTORY BE LIABLE FOR ANY DIRECT,
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
* OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#import "UIAction.h"
@implementation UIAction
@synthesize target=_target, action=_action;
- (BOOL)isEqual:(id)object
{
if (object == self) {
return YES;
} else if ([object isKindOfClass:[self class]]) {
return ([object target] == self.target && [object action] == self.action);
} else {
return NO;
}
}
@end
================================================
FILE: Examples/Chameleon Demo/Chameleon/UIKit/Classes/UIActionSheet.h
================================================
/*
* Copyright (c) 2011, The Iconfactory. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of The Iconfactory nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE ICONFACTORY BE LIABLE FOR ANY DIRECT,
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
* OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#import "UIView.h"
#import "UIInterface.h"
@class UIActionSheet, UITabBar, UIToolbar, UIBarButtonItem;
@protocol UIActionSheetDelegate
@optional
- (void)actionSheet:(UIActionSheet *)actionSheet clickedButtonAtIndex:(NSInteger)buttonIndex;
- (void)willPresentActionSheet:(UIActionSheet *)actionSheet;
- (void)didPresentActionSheet:(UIActionSheet *)actionSheet;
- (void)actionSheet:(UIActionSheet *)actionSheet willDismissWithButtonIndex:(NSInteger)buttonIndex;
- (void)actionSheet:(UIActionSheet *)actionSheet didDismissWithButtonIndex:(NSInteger)buttonIndex;
- (void)actionSheetCancel:(UIActionSheet *)actionSheet;
@end
typedef enum {
UIActionSheetStyleAutomatic = -1,
UIActionSheetStyleDefault = UIBarStyleDefault,
UIActionSheetStyleBlackTranslucent = UIBarStyleBlackTranslucent,
UIActionSheetStyleBlackOpaque = UIBarStyleBlackOpaque,
} UIActionSheetStyle;
@interface UIActionSheet : UIView {
@private
__unsafe_unretained id _delegate;
NSInteger _destructiveButtonIndex;
NSInteger _cancelButtonIndex;
NSInteger _firstOtherButtonIndex;
NSString *_title;
NSMutableArray *_menuTitles;
NSMutableArray *_separatorIndexes;
UIActionSheetStyle _actionSheetStyle;
id _menu;
struct {
unsigned clickedButtonAtIndex : 1;
unsigned willPresentActionSheet : 1;
unsigned didPresentActionSheet : 1;
unsigned willDismissWithButtonIndex : 1;
unsigned didDismissWithButtonIndex : 1;
unsigned actionSheetCancel : 1;
} _delegateHas;
}
- (id)initWithTitle:(NSString *)title delegate:(id)delegate cancelButtonTitle:(NSString *)cancelButtonTitle destructiveButtonTitle:(NSString *)destructiveButtonTitle otherButtonTitles:(NSString *)otherButtonTitles, ...;
- (NSInteger)addButtonWithTitle:(NSString *)title;
- (void)showInView:(UIView *)view; // menu will appear wherever the mouse cursor is
- (void)showFromRect:(CGRect)rect inView:(UIView *)view animated:(BOOL)animated; // if rect is CGRectNull, the menu will appear wherever the mouse cursor is
- (void)dismissWithClickedButtonIndex:(NSInteger)buttonIndex animated:(BOOL)animated;
// these are not yet implemented:
- (void)showFromToolbar:(UIToolbar *)view;
- (void)showFromTabBar:(UITabBar *)view;
- (void)showFromBarButtonItem:(UIBarButtonItem *)item animated:(BOOL)animated;
@property (nonatomic, copy) NSString *title;
@property (nonatomic, assign) id delegate;
@property (nonatomic, assign) UIActionSheetStyle actionSheetStyle;
@property (nonatomic, readonly, getter=isVisible) BOOL visible;
@property (nonatomic) NSInteger destructiveButtonIndex;
@property (nonatomic) NSInteger cancelButtonIndex;
@property (nonatomic, readonly) NSInteger firstOtherButtonIndex;
@property (nonatomic, readonly) NSInteger numberOfButtons;
@end
================================================
FILE: Examples/Chameleon Demo/Chameleon/UIKit/Classes/UIActionSheet.m
================================================
/*
* Copyright (c) 2011, The Iconfactory. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of The Iconfactory nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE ICONFACTORY BE LIABLE FOR ANY DIRECT,
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
* OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#import "UIActionSheet.h"
#import "UIWindow.h"
#import "UIScreenAppKitIntegration.h"
#import "UIKitView.h"
#import "UIApplication+UIPrivate.h"
#import "UIBarButtonItem.h"
#import
#import
#import
@implementation UIActionSheet
@synthesize delegate=_delegate, destructiveButtonIndex=_destructiveButtonIndex, cancelButtonIndex=_cancelButtonIndex, title=_title;
@synthesize firstOtherButtonIndex=_firstOtherButtonIndex, actionSheetStyle = _actionSheetStyle;
- (id)initWithFrame:(CGRect)frame
{
if ((self=[super initWithFrame:frame])) {
_menuTitles = [[NSMutableArray alloc] init];
_separatorIndexes = [[NSMutableArray alloc] init];
_destructiveButtonIndex = -1;
_cancelButtonIndex = -1;
_firstOtherButtonIndex = -1;
}
return self;
}
- (id)initWithTitle:(NSString *)title delegate:(id < UIActionSheetDelegate >)delegate cancelButtonTitle:(NSString *)cancelButtonTitle destructiveButtonTitle:(NSString *)destructiveButtonTitle otherButtonTitles:(NSString *)otherButtonTitles, ...
{
if ((self=[self initWithFrame:CGRectZero])) {
self.delegate = delegate;
_firstOtherButtonIndex = -1; // sort of a hack to reset this because the addButtonWithTitle's above can change it's value :)
if (otherButtonTitles) {
[self addButtonWithTitle:otherButtonTitles];
id buttonTitle = nil;
va_list argumentList;
va_start(argumentList, otherButtonTitles);
while ((buttonTitle=(__bridge NSString *)va_arg(argumentList, void *))) {
[self addButtonWithTitle:buttonTitle];
}
va_end(argumentList);
}
if (destructiveButtonTitle) {
self.destructiveButtonIndex = [self addButtonWithTitle:destructiveButtonTitle];
}
if (cancelButtonTitle) {
self.cancelButtonIndex = [self addButtonWithTitle:cancelButtonTitle];
}
}
return self;
}
- (void)dealloc
{
[_title release];
[_menu release];
[_menuTitles release];
[_separatorIndexes release];
[super dealloc];
}
- (void)setDelegate:(id)newDelegate
{
_delegate = newDelegate;
_delegateHas.clickedButtonAtIndex = [_delegate respondsToSelector:@selector(actionSheet:clickedButtonAtIndex:)];
_delegateHas.willPresentActionSheet = [_delegate respondsToSelector:@selector(willPresentActionSheet:)];
_delegateHas.didPresentActionSheet = [_delegate respondsToSelector:@selector(didPresentActionSheet:)];
_delegateHas.willDismissWithButtonIndex = [_delegate respondsToSelector:@selector(actionSheet:willDismissWithButtonIndex:)];
_delegateHas.didDismissWithButtonIndex = [_delegate respondsToSelector:@selector(actionSheet:didDismissWithButtonIndex:)];
_delegateHas.actionSheetCancel = [_delegate respondsToSelector:@selector(actionSheetCancel:)];
}
- (NSInteger)addButtonWithTitle:(NSString *)title
{
[_menuTitles addObject:title ?: @""];
NSInteger index = [_menuTitles count]-1;
if (_firstOtherButtonIndex == -1 ) {
_firstOtherButtonIndex = index;
}
return index;
}
- (void)addSeparator
{
[_separatorIndexes addObject:[NSNumber numberWithInt:[_menuTitles count]]];
}
- (void)setDestructiveButtonIndex:(NSInteger)index
{
if (index != _destructiveButtonIndex) {
if (index >= 0) {
assert(index<[_menuTitles count]);
} else {
index = -1;
}
_destructiveButtonIndex = index;
}
}
- (void)setCancelButtonIndex:(NSInteger)index
{
if (index != _cancelButtonIndex) {
if (index >= 0) {
assert(index<[_menuTitles count]);
} else {
index = -1;
}
_cancelButtonIndex = index;
}
}
- (BOOL)isVisible
{
return (_menu != nil);
}
- (NSInteger)numberOfButtons
{
return [_menuTitles count];
}
- (void)_showFromPoint:(CGPoint)point rightAligned:(BOOL)rightAligned inView:(UIView *)view
{
[view addSubview:self];
if (!_menu && self.window) {
_menu = [[NSMenu alloc] initWithTitle:_title ?: @""];
[_menu setAutoenablesItems:NO];
[_menu setAllowsContextMenuPlugIns:NO];
for (NSInteger index=0; index<[_menuTitles count]; index++) {
if ([_separatorIndexes containsObject:[NSNumber numberWithInt:index]]) {
[_menu addItem:[NSMenuItem separatorItem]];
}
// don't even bother putting a cancel menu item on there. I think on OSX it's always going to be pointless
// as clicking outside of the menu is always the same thing as tapping the cancel button and that's just
// how it's got to work, I think.
if (index != _cancelButtonIndex) {
NSMenuItem *theItem = [[NSMenuItem alloc] initWithTitle:[_menuTitles objectAtIndex:index] action:@selector(_didSelectMenuItem:) keyEquivalent:@""];
[theItem setTag:index];
[theItem setTarget:self];
[_menu addItem:theItem];
[theItem release];
}
}
// convert the point from view's coordinate space to the underlying NSView's coordinate space
CGPoint windowPoint = [self convertPoint:point toView:nil];
CGPoint screenPoint = [self.window convertPoint:windowPoint toWindow:nil];
// then offset it if desired
if (rightAligned) {
screenPoint.x -= [_menu size].width;
}
if (_delegateHas.willPresentActionSheet) {
[_delegate willPresentActionSheet:self];
}
// note that presenting an NSMenu is apparently modal. so, to pretend that it isn't, exactly, I'll delay the presentation
// of the menu to the start of a new runloop. At least that way, code that may be expecting to run right after setting the
// menu to visible would still run before the menu itself shows up on screen. Of course behavior is going to be pretty different
// after that point since if the app is assuming it can keep on doing normal runloop stuff, it ain't gonna happen.
// but since clicks outside of an NSMenu dismiss it, there's not a lot a user can do to an app to change state when a menu
// is up in the first place.
[self performSelector:@selector(_actuallyPresentTheMenuFromPoint:) withObject:[NSValue valueWithCGPoint:screenPoint] afterDelay:0];
}
}
- (void)_clickedButtonAtIndex:(NSInteger)index
{
if (_delegateHas.clickedButtonAtIndex){
[_delegate actionSheet:self clickedButtonAtIndex:index];
}
if (index == _cancelButtonIndex && _delegateHas.actionSheetCancel) {
[_delegate actionSheetCancel:self];
}
if (_delegateHas.willDismissWithButtonIndex) {
[_delegate actionSheet:self willDismissWithButtonIndex:index];
}
[self dismissWithClickedButtonIndex:index animated:YES];
if (_delegateHas.didDismissWithButtonIndex) {
[_delegate actionSheet:self didDismissWithButtonIndex:index];
}
}
- (void)_didSelectMenuItem:(NSMenuItem *)item
{
[self _clickedButtonAtIndex:[item tag]];
}
- (void)_actuallyPresentTheMenuFromPoint:(NSValue *)aPoint
{
// hard to say where best to put this, but I guess this makes some sense? I can't call it after it's actually
// on screen because of the modal-ness of NSMenu
if (_delegateHas.didPresentActionSheet) {
[_delegate didPresentActionSheet:self];
}
// this goes modal... meh.
BOOL itemSelected = [_menu popUpMenuPositioningItem:nil atLocation:NSPointFromCGPoint([aPoint CGPointValue]) inView:[self.window.screen UIKitView]];
// because of the modal nature of NSMenu, if there's a touch active (like, being held down) when a menu is triggered, the modal NSMenu
// takes over the event stream and so a mouseUp is never delivered to the UIKitView. This means it never gets to the app and it leaves
// the "touch" tracking system in an inconsistent state. This triggers the touchesCancelled UIResponder stuff to allow UIKit code to clean
// itself up after the menu is done.
[[UIApplication sharedApplication] _cancelTouches];
if (!itemSelected) {
[self _clickedButtonAtIndex:_cancelButtonIndex];
}
}
- (void)showInView:(UIView *)view
{
// Since we're using an NSMenu to represent UIActionSheet on OSX, I'm going to make the assumption that a showInView: is triggered from
// a click somewhere. If it's triggered on a delay, that might be a problem. However for a typical app, I suspect that is generally
// not the case. I can't think of a better behavior right now, so I'm going to fetch the current mouse position and translate coords
// so that the menu presents from there.
[self showFromRect:CGRectNull inView:view animated:YES];
}
- (void)showFromRect:(CGRect)rect inView:(UIView *)view animated:(BOOL)animated
{
// If the rect is NULL, use that as a flag to indicate that the menu should be presented from wherever the mouse cursor is
// instead of a specific place on screen. This is not really normal UIKit behavior, of course, but I think it makes sense
// here on the Mac.
if (CGRectIsNull(rect)) {
// translate them thar points!
NSPoint mouseLocation = [NSEvent mouseLocation];
CGPoint screenPoint = [view.window.screen convertPoint:NSPointToCGPoint(mouseLocation) fromScreen:nil];
CGPoint windowPoint = [view.window convertPoint:screenPoint fromWindow:nil];
CGPoint viewPoint = [view convertPoint:windowPoint fromView:nil];
[self _showFromPoint:viewPoint rightAligned:NO inView:view];
} else {
[self _showFromPoint:CGPointMake(rect.origin.x+rect.size.width, rect.origin.y+rect.size.height) rightAligned:YES inView:view];
}
}
- (void)showFromToolbar:(UIToolbar *)view
{
}
- (void)showFromTabBar:(UITabBar *)view
{
}
- (void)showFromBarButtonItem:(UIBarButtonItem *)item animated:(BOOL)animated
{
}
- (void)dismissWithClickedButtonIndex:(NSInteger)buttonIndex animated:(BOOL)animated
{
if (animated) {
[_menu cancelTracking];
} else {
[_menu cancelTrackingWithoutAnimation];
}
// kill off the menu
[_menu release];
_menu = nil;
// remove ourself from the superview that we piggy-backed on
[self removeFromSuperview];
}
@end
================================================
FILE: Examples/Chameleon Demo/Chameleon/UIKit/Classes/UIActionSheetAppKitIntegration.h
================================================
/*
* Copyright (c) 2011, The Iconfactory. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of The Iconfactory nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE ICONFACTORY BE LIABLE FOR ANY DIRECT,
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
* OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#import "UIActionSheet.h"
@interface UIActionSheet (AppKitIntegration)
- (void)addSeparator;
@end
================================================
FILE: Examples/Chameleon Demo/Chameleon/UIKit/Classes/UIActivityIndicatorView.h
================================================
/*
* Copyright (c) 2011, The Iconfactory. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of The Iconfactory nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE ICONFACTORY BE LIABLE FOR ANY DIRECT,
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
* OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#import "UIView.h"
typedef enum {
UIActivityIndicatorViewStyleWhiteLarge,
UIActivityIndicatorViewStyleWhite,
UIActivityIndicatorViewStyleGray,
} UIActivityIndicatorViewStyle;
@interface UIActivityIndicatorView : UIView {
@private
UIActivityIndicatorViewStyle _activityIndicatorViewStyle;
BOOL _hidesWhenStopped;
BOOL _animating;
}
- (id)initWithActivityIndicatorStyle:(UIActivityIndicatorViewStyle)style;
- (void)startAnimating;
- (void)stopAnimating;
- (BOOL)isAnimating;
@property BOOL hidesWhenStopped;
@property UIActivityIndicatorViewStyle activityIndicatorViewStyle;
@end
================================================
FILE: Examples/Chameleon Demo/Chameleon/UIKit/Classes/UIActivityIndicatorView.m
================================================
/*
* Copyright (c) 2011, The Iconfactory. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of The Iconfactory nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE ICONFACTORY BE LIABLE FOR ANY DIRECT,
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
* OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#import "UIActivityIndicatorView.h"
#import "UIImage.h"
#import "UIGraphics.h"
#import "UIColor.h"
#import "UIFont.h"
#import "UIStringDrawing.h"
#import "UIBezierPath.h"
#import
static CGSize UIActivityIndicatorViewStyleSize(UIActivityIndicatorViewStyle style)
{
if (style == UIActivityIndicatorViewStyleWhiteLarge) {
return CGSizeMake(37,37);
} else {
return CGSizeMake(20,20);
}
}
static UIImage *UIActivityIndicatorViewFrameImage(UIActivityIndicatorViewStyle style, NSInteger frame, NSInteger numberOfFrames, CGFloat scale)
{
const CGSize frameSize = UIActivityIndicatorViewStyleSize(style);
const CGFloat radius = frameSize.width / 2.f;
const CGFloat TWOPI = M_PI * 2.f;
const CGFloat numberOfTeeth = 12;
const CGFloat toothWidth = (style == UIActivityIndicatorViewStyleWhiteLarge)? 3.5 : 2;
UIColor *toothColor = (style == UIActivityIndicatorViewStyleGray)? [UIColor grayColor] : [UIColor whiteColor];
UIGraphicsBeginImageContextWithOptions(frameSize, NO, scale);
CGContextRef c = UIGraphicsGetCurrentContext();
// first put the origin in the center of the frame. this makes things easier later
CGContextTranslateCTM(c, radius, radius);
// now rotate the entire thing depending which frame we're trying to generate
CGContextRotateCTM(c, frame / (CGFloat)numberOfFrames * TWOPI);
// draw all the teeth
for (NSInteger toothNumber=0; toothNumber _delegate;
NSInteger _cancelButtonIndex;
NSMutableArray *_buttonTitles;
struct {
unsigned clickedButtonAtIndex : 1;
unsigned alertViewCancel : 1;
unsigned willPresentAlertView : 1;
unsigned didPresentAlertView : 1;
unsigned willDismissWithButtonIndex : 1;
unsigned didDismissWithButtonIndex : 1;
} _delegateHas;
}
- (id)initWithTitle:(NSString *)title message:(NSString *)message delegate:(id)delegate cancelButtonTitle:(NSString *)cancelButtonTitle otherButtonTitles:(NSString *)otherButtonTitles, ...;
- (NSInteger)addButtonWithTitle:(NSString *)title;
- (NSString *)buttonTitleAtIndex:(NSInteger)buttonIndex;
- (void)show;
- (void)dismissWithClickedButtonIndex:(NSInteger)buttonIndex animated:(BOOL)animated; // not implemented at the moment since I use NSAlert and runModal and this would present problems. :/
@property (nonatomic, copy) NSString *title;
@property (nonatomic, copy) NSString *message;
@property (nonatomic, assign) id delegate;
@property (nonatomic) NSInteger cancelButtonIndex;
@property (nonatomic,readonly) NSInteger numberOfButtons;
@end
@protocol UIAlertViewDelegate
@optional
- (void)alertView:(UIAlertView *)alertView clickedButtonAtIndex:(NSInteger)buttonIndex;
- (void)alertViewCancel:(UIAlertView *)alertView; // never called
- (void)willPresentAlertView:(UIAlertView *)alertView; // before animation and showing view
- (void)didPresentAlertView:(UIAlertView *)alertView; // after animation
- (void)alertView:(UIAlertView *)alertView willDismissWithButtonIndex:(NSInteger)buttonIndex; // before animation and hiding view
- (void)alertView:(UIAlertView *)alertView didDismissWithButtonIndex:(NSInteger)buttonIndex; // after animation
@end
================================================
FILE: Examples/Chameleon Demo/Chameleon/UIKit/Classes/UIAlertView.m
================================================
/*
* Copyright (c) 2011, The Iconfactory. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of The Iconfactory nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE ICONFACTORY BE LIABLE FOR ANY DIRECT,
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
* OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#import "UIAlertView.h"
#import "UIApplication.h"
#import
#import
#import
@interface UIAlertView ()
@property (nonatomic, strong) NSMutableArray *buttonTitles;
@end
@implementation UIAlertView
@synthesize title=_title, message=_message, delegate=_delegate, cancelButtonIndex=_cancelButtonIndex, buttonTitles=_buttonTitles;
- (id)initWithTitle:(NSString *)title message:(NSString *)message delegate:(id)delegate cancelButtonTitle:(NSString *)cancelButtonTitle otherButtonTitles:(NSString *)otherButtonTitles, ...
{
if ((self=[super initWithFrame:CGRectZero])) {
self.title = title;
self.message = message;
self.delegate = delegate;
self.buttonTitles = [NSMutableArray arrayWithCapacity:1];
if (cancelButtonTitle) {
self.cancelButtonIndex = [self addButtonWithTitle:cancelButtonTitle];
}
if (otherButtonTitles) {
[self addButtonWithTitle:otherButtonTitles];
id buttonTitle = nil;
va_list argumentList;
va_start(argumentList, otherButtonTitles);
while ((buttonTitle=(__bridge NSString *)va_arg(argumentList, void *))) {
[self addButtonWithTitle:buttonTitle];
}
va_end(argumentList);
}
}
return self;
}
- (void)dealloc
{
[_title release];
[_message release];
[_buttonTitles release];
[super dealloc];
}
- (void)setDelegate:(id)newDelegate
{
_delegate = newDelegate;
_delegateHas.clickedButtonAtIndex = [_delegate respondsToSelector:@selector(alertView:clickedButtonAtIndex:)];
_delegateHas.alertViewCancel = [_delegate respondsToSelector:@selector(alertViewCancel:)];
_delegateHas.willPresentAlertView = [_delegate respondsToSelector:@selector(willPresentAlertView:)];
_delegateHas.didPresentAlertView = [_delegate respondsToSelector:@selector(didPresentAlertView:)];
_delegateHas.willDismissWithButtonIndex = [_delegate respondsToSelector:@selector(alertView:willDismissWithButtonIndex:)];
_delegateHas.didDismissWithButtonIndex = [_delegate respondsToSelector:@selector(alertView:didDismissWithButtonIndex:)];
}
- (NSInteger)addButtonWithTitle:(NSString *)title
{
[self.buttonTitles addObject:title];
return ([self.buttonTitles count] - 1);
}
- (NSString *)buttonTitleAtIndex:(NSInteger)buttonIndex
{
return [self.buttonTitles objectAtIndex:buttonIndex];
}
- (NSInteger)numberOfButtons
{
return [self.buttonTitles count];
}
- (void)show
{
// capture the current button configuration and build an NSAlert
// we show it after letting the runloop finish because UIKit stuff is often written with the assumption
// that showing an alert doesn't block the runloop. Kinda icky, but the same pattern is used for UIActionSheet
// and the UIMenuController and I don't know there's a lot that I can do about it.
// NSAlert does have a mode that doesn't block the runloop, but it has other drawbacks that I didn't like
// so opting to do it this way here. :/
NSAlert *alert = [[[NSAlert alloc] init] autorelease];
NSMutableArray *buttonOrder = [[[NSMutableArray alloc] initWithCapacity:self.numberOfButtons] autorelease];
if (self.title) {
[alert setMessageText:self.title];
}
if (self.message) {
[alert setInformativeText:self.message];
}
for (NSInteger buttonIndex=0; buttonIndex= 0) {
NSButton *btn = [alert addButtonWithTitle:[self.buttonTitles objectAtIndex:self.cancelButtonIndex]];
// only change the key equivelent if there's more than one button, otherwise we lose the "Return" key for triggering the default action
if (self.numberOfButtons > 1) {
[btn setKeyEquivalent:@"\033"]; // this should make the escape key trigger the cancel option
}
[buttonOrder addObject:[NSNumber numberWithInt:self.cancelButtonIndex]];
}
if (_delegateHas.willPresentAlertView) {
[_delegate willPresentAlertView:self];
}
[self performSelector:@selector(_showAlertWithOptions:)
withObject:[NSDictionary dictionaryWithObjectsAndKeys:
alert, @"alert",
buttonOrder, @"buttonOrder",
nil]
afterDelay:0];
}
- (void)_showAlertWithOptions:(NSDictionary *)options
{
NSAlert *alert = [options objectForKey:@"alert"];
NSMutableArray *buttonOrder = [options objectForKey:@"buttonOrder"];
if (_delegateHas.didPresentAlertView) {
[_delegate didPresentAlertView:self];
}
NSInteger result = [alert runModal];
NSInteger buttonIndex = -1;
switch (result) {
case NSAlertFirstButtonReturn:
buttonIndex = [[buttonOrder objectAtIndex:0] intValue];
break;
case NSAlertSecondButtonReturn:
buttonIndex = [[buttonOrder objectAtIndex:1] intValue];
break;
case NSAlertThirdButtonReturn:
buttonIndex = [[buttonOrder objectAtIndex:2] intValue];
break;
default:
buttonIndex = [[buttonOrder objectAtIndex:2+(result-NSAlertThirdButtonReturn)] intValue];
break;
}
if (_delegateHas.clickedButtonAtIndex) {
[_delegate alertView:self clickedButtonAtIndex:buttonIndex];
}
if (_delegateHas.willDismissWithButtonIndex) {
[_delegate alertView:self willDismissWithButtonIndex:buttonIndex];
}
if (_delegateHas.didDismissWithButtonIndex) {
[_delegate alertView:self didDismissWithButtonIndex:buttonIndex];
}
}
- (void)dismissWithClickedButtonIndex:(NSInteger)buttonIndex animated:(BOOL)animated
{
}
@end
================================================
FILE: Examples/Chameleon Demo/Chameleon/UIKit/Classes/UIAppearance.h
================================================
/*
* Copyright (c) 2012, The Iconfactory. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
*
* 2. Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
*
* 3. Neither the name of The Iconfactory nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE ICONFACTORY BE LIABLE FOR ANY DIRECT,
* INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
* BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE
* OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
#import
#define UI_APPEARANCE_SELECTOR
@protocol UIAppearanceContainer
@end
@protocol UIAppearance
+ (id)appearance;
+ (id)appearanceWhenContainedIn:(Class