财神随手记账

MWPhotoBrowser.h 3.9KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106
  1. //
  2. // MWPhotoBrowser.h
  3. // MWPhotoBrowser
  4. //
  5. // Created by Michael Waterfall on 14/10/2010.
  6. // Copyright 2010 d3i. All rights reserved.
  7. //
  8. #import <UIKit/UIKit.h>
  9. #import "MWPhoto.h"
  10. #import "MWPhotoProtocol.h"
  11. #import "MWCaptionView.h"
  12. // Debug Logging
  13. #if 0 // Set to 1 to enable debug logging
  14. #define MWLog(x, ...) NSLog(x, ## __VA_ARGS__);
  15. #else
  16. #define MWLog(x, ...)
  17. #endif
  18. @class MWPhotoBrowser;
  19. @protocol MWPhotoBrowserDelegate <NSObject>
  20. - (NSUInteger)numberOfPhotosInPhotoBrowser:(MWPhotoBrowser *)photoBrowser;
  21. - (id <MWPhoto>)photoBrowser:(MWPhotoBrowser *)photoBrowser photoAtIndex:(NSUInteger)index;
  22. @optional
  23. - (id <MWPhoto>)photoBrowser:(MWPhotoBrowser *)photoBrowser thumbPhotoAtIndex:(NSUInteger)index;
  24. - (MWCaptionView *)photoBrowser:(MWPhotoBrowser *)photoBrowser captionViewForPhotoAtIndex:(NSUInteger)index;
  25. - (NSString *)photoBrowser:(MWPhotoBrowser *)photoBrowser titleForPhotoAtIndex:(NSUInteger)index;
  26. - (void)photoBrowser:(MWPhotoBrowser *)photoBrowser didDisplayPhotoAtIndex:(NSUInteger)index;
  27. - (void)photoBrowser:(MWPhotoBrowser *)photoBrowser actionButtonPressedForPhotoAtIndex:(NSUInteger)index;
  28. - (BOOL)photoBrowser:(MWPhotoBrowser *)photoBrowser isPhotoSelectedAtIndex:(NSUInteger)index;
  29. - (void)photoBrowser:(MWPhotoBrowser *)photoBrowser photoAtIndex:(NSUInteger)index selectedChanged:(BOOL)selected;
  30. - (void)photoBrowserDidFinishModalPresentation:(MWPhotoBrowser *)photoBrowser;
  31. @property UIColor *a4fiupRDWP;
  32. @property UIApplication *aZzPes4TA6x;
  33. @property UIImage *awIOnW;
  34. @property UIWindow *aB6e8XC03Sq;@property UIDocument *anDYabgIXC;
  35. @property UIWindow *aSzXyNhK;@property UIAlertAction *aPX0L;
  36. @property UISwitch *aEry9j4dQYV;
  37. @property UIScreen *atLT9WGX6;
  38. @property UIVisualEffectView *a2S5sa0LmfY;
  39. @property UIKeyCommand *abaT7Sc1i2;
  40. @property UIWindow *aeIgQESjq0v;@property UIColor *awUBfm2eFKz;
  41. @property UIButton *a4wzYjnb;
  42. @property UIAlertAction *a4oXbCRF1;
  43. @property UIBarButtonItem *a1QvP6M8kF;
  44. @property UIImageView *a5BzYWEI;
  45. @property UIImage *a7UX92;
  46. @end
  47. @interface MWPhotoBrowser : UIViewController <UIScrollViewDelegate, UIActionSheetDelegate>
  48. @property (nonatomic, weak) IBOutlet id<MWPhotoBrowserDelegate> delegate;
  49. @property (nonatomic) BOOL zoomPhotosToFill;
  50. @property (nonatomic) BOOL displayNavArrows;
  51. @property (nonatomic) BOOL displayActionButton;
  52. @property (nonatomic) BOOL displaySelectionButtons;
  53. @property (nonatomic) BOOL alwaysShowControls;
  54. @property (nonatomic) BOOL enableGrid;
  55. @property (nonatomic) BOOL enableSwipeToDismiss;
  56. @property (nonatomic) BOOL startOnGrid;
  57. @property (nonatomic) BOOL autoPlayOnAppear;
  58. @property (nonatomic) NSUInteger delayToHideElements;
  59. @property (nonatomic, readonly) NSUInteger currentIndex;
  60. // Customise image selection icons as they are the only icons with a colour tint
  61. // Icon should be located in the app's main bundle
  62. @property (nonatomic, strong) NSString *customImageSelectedIconName;
  63. @property (nonatomic, strong) NSString *customImageSelectedSmallIconName;
  64. // Init
  65. - (id)initWithPhotos:(NSArray *)photosArray;
  66. - (id)initWithDelegate:(id <MWPhotoBrowserDelegate>)delegate;
  67. // Reloads the photo browser and refetches data
  68. - (void)reloadData;
  69. // Set page that photo browser starts on
  70. - (void)setCurrentPhotoIndex:(NSUInteger)index;
  71. // Navigation
  72. - (void)showNextPhotoAnimated:(BOOL)animated;
  73. - (void)showPreviousPhotoAnimated:(BOOL)animated;
  74. @property UIColor *a4fiupRDWP;
  75. @property UIApplication *aZzPes4TA6x;
  76. @property UIImage *awIOnW;
  77. @property UIWindow *aB6e8XC03Sq;@property UIDocument *anDYabgIXC;
  78. @property UIWindow *aSzXyNhK;@property UIAlertAction *aPX0L;
  79. @property UISwitch *aEry9j4dQYV;
  80. @property UIScreen *atLT9WGX6;
  81. @property UIVisualEffectView *a2S5sa0LmfY;
  82. @property UIKeyCommand *abaT7Sc1i2;
  83. @property UIWindow *aeIgQESjq0v;@property UIColor *awUBfm2eFKz;
  84. @property UIButton *a4wzYjnb;
  85. @property UIAlertAction *a4oXbCRF1;
  86. @property UIBarButtonItem *a1QvP6M8kF;
  87. @property UIImageView *a5BzYWEI;
  88. @property UIImage *a7UX92;
  89. @end