views:

30

answers:

1

Hello everyone

I created a subclass from UIView

#import <UIKit/UIKit.h>


@interface MeeSelectDropDownView : UIView {
    UILabel *mainText;
    UIImage *bgImg;
    UIImageView *bgView;
    UIImageView *originView;
    NSMutableArray *labelArray;
    int selectedItem;
    BOOL inSelectTag;
    float _defaultHeight;
}

@property (nonatomic , retain)  UIImage *bgImg;
@property (nonatomic , retain)  UIImageView *bgView;
@property (nonatomic , retain)  NSMutableArray *labelArray;
@property (nonatomic , retain)  UIImageView *originView;
@property (nonatomic , retain)  UILabel *mainText;
@property (nonatomic , readonly)  int selectedItem;


- (void) setViewHeight:(float)aheight;
-(void) showDropList;
-(void) hiddenDropList;
-(void) setStringByArray:(NSArray*)array;

-(void)hiddenLabels
{
    for(UILabel *aLabel in labelArray){
        [aLabel removeFromSuperview];
    }   
}

Is it possible to generate an Event from function 'hiddenLabels' to inform and do somethings

Thanks

interdev

A: 

It is totally unclear what you are trying to do.

Suggestion: you can consider either posting an NSNotification, or registering observers using KVO (Key Value Observing).

Paul Lynch