2015-10-20 69 views
0

我试图重写SETFRAME:功能和我的代码如下所示:使用方法重写

%new 
- (void)setFrame:(CGRect)frame 
{ 
    [super setFrame:frame]; 
} 

但我从编译器错误:

error: use of undeclared identifier 'super' 
    [super setFrame:frame]; 
    ^
1 error generated. 

我已经尝试使用[[[UIView] init] setFrame:frame];但它不起作用。

编辑: 我使用THEOS

回答

0

通过移除%,新的功能在这种情况下添加%原稿,这项工作对我来说解决。