I can't seem to start an NSTimer. Here is my simple example, and hopefully someone can help me out....
I have a subclass of NSView which has a NSTimer property. It overrides initWithFrame which does:
<code>
NSRunLoop *r=[NSRunLoop currentRunLoop];
[super initWithFrame:frameRect];
timer=[NSTimer timerWithTimeInterval:2 target:self selector:@selector(nextFrame

userInfo:nil repeats:YES];
[r addTimer:timer forMode:[r currentMode]];
return self;
</code>
Now the nextFrame: method is there and works (it just executes NSBeep()). It segfaults on [r currentMode] (I assume because it return nil). And I don't understand what the forMode: argument is. Regardless, if I just make up a string (ie @"") the method is never called.
Hopefully someone understands what's wrong here.
Thanks!!
Jeff