1

我如何继承UITextViewin以 UIActionSheet覆盖in 。canBeforeFirstResponderdisable copy, select, and select allUITextView

#import <UIKit/UIKit.h>

@class English;

@protocol EnglishDelegate

- (void)dismissViewDidFinish:(UIViewController *)viewController;

@end


@interface English: UIViewController <UITextViewDelegate, UIScrollViewDelegate>


{
id<EnglishDelegate> delegate;
UITextView *textView;
UINavigationBar *navBar;
UINavigationController *navigationController;

}

@property (nonatomic, retain) UITextView *textView;
@property (nonatomic, assign) UINavigationBar *navBar;
@property (strong, nonatomic) UINavigationController *navigationController;
@property (nonatomic, assign) id<EnglishDelegate> delegate;
@property (nonatomic, retain) UIScrollView *scrollView; 

-(void)dismissView:(id)sender;

@end

任何人都知道如何在 h 文件中对其进行子类化。

感谢帮助。

4

1 回答 1

2

您不会UITextView在另一个类中进行子类化;您只需将其子类化到另一个文件中并按canBecomeFirstResponder如下方式覆盖:

- (BOOL)canBecomeFirstResponder {
    return NO;
}
于 2012-05-13T15:36:37.900 回答