iphone - How to check which UIViewController is active -
I have to check which UIViewController is active, so I have implemented some cases based on the result.
[self.navigationController.visibleViewController className]
It always gives blank.
I am checking with this statement:
if ([iDetailController isKindOfClass: [IDetailController class]])
but It fails, please help me if I'm doing something wrong.
Use the following method:
if ([self amber ecloss : [IDFTE Controller Class]]) {
CFShow (@ "Yes, this is the IDETTE Controller Controller"); }
isMemberOfClass tells you that the example is an accurate example of that class. There is also KindOfClass:
if ([isCindOfClass: [BaseView class]]) {
CFShow (@ "For all this The classes that are extending the baseview will be logged ");`
}
The hacking test is that the class is an extension of a certain class.
Comments
Post a Comment