10 #import <UIKit/UIKit.h>
11 #import <QuartzCore/QuartzCore.h>
13 typedef enum FPPopoverArrowDirection: NSUInteger {
14 FPPopoverArrowDirectionUp = 1UL << 0,
15 FPPopoverArrowDirectionDown = 1UL << 1,
16 FPPopoverArrowDirectionLeft = 1UL << 2,
17 FPPopoverArrowDirectionRight = 1UL << 3,
18 FPPopoverNoArrow = 1UL << 4,
20 FPPopoverArrowDirectionVertical = FPPopoverArrowDirectionUp | FPPopoverArrowDirectionDown | FPPopoverNoArrow,
21 FPPopoverArrowDirectionHorizontal = FPPopoverArrowDirectionLeft | FPPopoverArrowDirectionRight,
23 FPPopoverArrowDirectionAny = FPPopoverArrowDirectionUp | FPPopoverArrowDirectionDown |
24 FPPopoverArrowDirectionLeft | FPPopoverArrowDirectionRight
26 } FPPopoverArrowDirection;
28 #ifndef FPPopoverArrowDirectionIsVertical
29 #define FPPopoverArrowDirectionIsVertical(direction) ((direction) == FPPopoverArrowDirectionVertical || (direction) == FPPopoverArrowDirectionUp || (direction) == FPPopoverArrowDirectionDown || (direction) == FPPopoverNoArrow)
32 #ifndef FPPopoverArrowDirectionIsHorizontal
33 #define FPPopoverArrowDirectionIsHorizontal(direction) ((direction) == FPPopoverArrowDirectionHorizontal || (direction) == FPPopoverArrowDirectionLeft || (direction) == FPPopoverArrowDirectionRight)
39 FPPopoverLightGrayTint,
42 FPPopoverDefaultTint = FPPopoverBlackTint
45 @interface FPPopoverView : UIView
47 @property(nonatomic,strong) NSString *title;
48 @property(nonatomic,assign) CGPoint relativeOrigin;
49 @property(nonatomic,assign) FPPopoverTint tint;
50 @property(nonatomic,assign) BOOL draw3dBorder;
51 @property(nonatomic,assign) BOOL border;
53 -(void)setArrowDirection:(FPPopoverArrowDirection)arrowDirection;
54 -(FPPopoverArrowDirection)arrowDirection;
57 - (void)setAxOffset:(CGFloat)axOffset;
58 - (void)setAyOffset:(CGFloat)ayOffset;
60 -(void)addContentView:(UIView*)contentView;