Re: problem with sheet contextInfo
Re: problem with sheet contextInfo
- Subject: Re: problem with sheet contextInfo
- From: Jim Balhoff <email@hidden>
- Date: Tue, 26 Feb 2002 15:46:18 -0500
On Tuesday, February 26, 2002, at 11:16 AM, Bill Cheeseman wrote:
on 02-02-26 8:55 AM, Jim Balhoff at email@hidden wrote:
The problem is, if I finished the editing of
cell 1 (which sends the action) by clicking into cell 2, it is cell 2
that is cleared. I would have expected cell 1, which I passed as the
contextInfo, to be cleared.
Looking quickly at your code, I suspect the problem occurs because you
do no
checking when the user dismisses the sheet to make sure sender is the
control you think it is. Shouldn't your endMySheet: action method test
whether sender is the same object as the cell in the form that
originally
invoked cellCompletedEdit:?
Well, the sender that calls the endMySheet: action method is a button on
the sheet. I try to clear the formcell (by sending a message to
contextInfo) in the - (void)sheetDidEnd:(NSWindow *)sheet
returnCode:(int)returnCode contextInfo:(NSFormCell *)contextInfo method,
where the contextInfo is provided by NSApp (I think) and should be the
same as what I passed in when I started the sheet.
Thanks,
Jim
_______________________________________________
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.