Re: UITextView as its own delegate - infinite loop on keyboard select

2010-03-01 Thread Roland King
On 01-Mar-2010, at 7:34 PM, Uli Kusterer wrote: > On 01.03.2010, at 12:05, Roland King wrote: >> Firstly if that's what happened, the program would recurse, the stack would >> be full of textViewDidChangeSelection: calls each calling the next, but that >> is not what happens, the program hangs,

Re: UITextView as its own delegate - infinite loop on keyboard select

2010-03-01 Thread Uli Kusterer
On 01.03.2010, at 12:05, Roland King wrote: > Firstly if that's what happened, the program would recurse, the stack would > be full of textViewDidChangeSelection: calls each calling the next, but that > is not what happens, the program hangs, the code infinitely loops, but it > does not recurse,

Re: UITextView as its own delegate - infinite loop on keyboard select

2010-03-01 Thread Roland King
On 01-Mar-2010, at 9:29 AM, Kyle Sluder wrote: > On Sat, Feb 27, 2010 at 6:37 PM, Roland King wrote: >> Thanks that's what I see too. That thread doesn't explain why of course. I >> have a trivial test case so I'll file this as a bug and see what comes back >> because I think the behaviour is wr

Re: UITextView as its own delegate - infinite loop on keyboard select

2010-02-28 Thread Kyle Sluder
On Sat, Feb 27, 2010 at 6:37 PM, Roland King wrote: > Thanks that's what I see too. That thread doesn't explain why of course. I > have a trivial test case so I'll file this as a bug and see what comes back > because I think the behaviour is wrong. For now I'm using a different object > as delegat

Re: UITextView as its own delegate - infinite loop on keyboard select

2010-02-27 Thread Roland King
Oh and one other point after reading that whole thread (on an iPhone that's surprisingly hard!), the application does infinite loop but it doesn't recurse, so I do not believe the suggestion in the middle of that thread that respondsToSelector: checks self and then the delegate (which is it

Re: UITextView as its own delegate - infinite loop on keyboard select

2010-02-27 Thread Roland King
On 28-Feb-2010, at 9:21, Kyle Sluder wrote: Do not make a UITextView its own delegate. More information here: http://lists.apple.com/archives/Cocoa-dev/2009/Jul/msg01406.html --Kyle Sluder Thanks that's what I see too. That thread doesn't explain why of course. I have a trivial tes

Re: UITextView as its own delegate - infinite loop on keyboard select

2010-02-27 Thread Kyle Sluder
On Sat, Feb 27, 2010 at 5:39 AM, Roland King wrote: > I have a UITextView subclass which, when you touch it to start editing, hangs > in an infinite loop before the keyboard comes up. The subclass sets itself as > its own delegate in the constructor (because the subclass in this instance > want

UITextView as its own delegate - infinite loop on keyboard select

2010-02-27 Thread Roland King
I have a UITextView subclass which, when you touch it to start editing, hangs in an infinite loop before the keyboard comes up. The subclass sets itself as its own delegate in the constructor (because the subclass in this instance wants to capture editing ended events and deal with them internal