Im a noob to iphone development and I am having trouble implementing an if-statement within the didSelectIndex method of AwesomeMenu. The method fires and returns the value of the index selected, but it doesn't respond when I attempt to use the index in a conditional statement within the method. For example, my log only prints "Select the index : 0", but not "Index 0". This is very frustrating to say the least. Any help is greatly appreciated.
MY CODE:
- (void)AwesomeMenu:(AwesomeMenu *)menu didSelectIndex:(NSInteger)idx{
if (idx==0) {
NSLog(@"Index 0"); //Doesn't print
}else if(idx==1){
NSLog(@"Index 1"); //Doesn't print
}else{
NSLog(@"Else Block test"); //Doesn't print
}
NSLog(@"Select the index : %d",idx); //<--This Works.
}