Warum UITextField becomeFirstResponder gibt KEINE?

Dies ist mein code:

while (true) {
    if ([identificationField becomeFirstResponder]) {

        NSLog(@"finally!");
        break;
    }
    else{
        if ([identificationField canBecomeFirstResponder]) {
            NSLog(@"can");
        }
        else{
            NSLog(@"cannot");
        }
        NSLog(@"%@", identificationField);
        NSLog(@"dadgum!!");

    }
}

Dies ist, was es Protokolle:

   2014-02-05 11:33:54.253 Store Test[22488:70b] can

   2014-02-05 11:33:54.254 Store Test[22488:70b] <UITextField:
   0xb5c89a0; frame = (10 1; 300 43); text = ''; clipsToBounds = YES;
   opaque = NO; autoresize = TM+BM; gestureRecognizers = <NSArray:
   0xb5cc7b0>; layer = <CALayer: 0xb5c8b40>>

   2014-02-05 11:33:54.254 Store Test[22488:70b] dadgum!!

Weiß jemand, warum könnte es tun? Wie Sie sehen können, kann das Textfeld werden die first responder, es will einfach nicht.

InformationsquelleAutor user1654889 | 2014-02-05
Schreibe einen Kommentar