end edit for NSTextView & switch to next key view
end edit for NSTextView & switch to next key view
- Subject: end edit for NSTextView & switch to next key view
- From: Esteban <email@hidden>
- Date: Tue, 16 Apr 2002 00:28:46 -0700
Hi,
I'm working on an application that has a configuration sheet for
adding reminders. It has a NSTextField for the subject, followed by an
NSTextView inside an NSScrollView (which I'll call a NSTextScrollView)
for the message, followed by a NSRadio matrix, followed by several other
views for options (play sound, time, etc).
In Interface Builder I have the nextKeyView of each view connected to
the next appropriate view. for the first three views i mentioned above,
the nextKeyView chain goes like the following: NSTextField ->
NSTextScrollView -> NSRadio matrix
The problem I'm encountering is when switching keyViews from the
NSTextScrollView to the NSRadio matrix. I'm intercepting the keys being
pressed in a custom NSTextView inside the NSScrollView. If a tab or
enter key was pressed i proceed to call a "custom" delegate method
called endEditing:(id)textView which attempts to do [configurationSheet
selectNextKeyView];
Now that last line seems to work except it skips completely over the NS
Radio Matrix and into the next NSTextField, for entering the hour. Also
the NSTextView remains with a blinking cursor albeit no longer focused.
The hour textField is focused and I can enter data into it.
I've tried making the NSRadio matrix the first responder, tried to
endFieldEditing for the NSTextView, and tried to select the nextKeyview
as above, but nothing seems to work. I'm thinking selecting the
nextKeyView should endFieldEditing for the NSTextView if a field editor
is active. I've even called NSWindow's (NSPanel subclasses from that)
endEditingFor:(id)object but that fails to work.
Amazingly calling [configurationSheet
makeFirstResponder:configurationSheet] works fine, so apparently there
is no need to force the field editor to end by calling endEditingFor
I appreciate any suggestions or comments.
Thank you,
-Esteban Uribe
email@hidden
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.