Re: NSOutlineView selection questions
Re: NSOutlineView selection questions
- Subject: Re: NSOutlineView selection questions
- From: Olivier <email@hidden>
- Date: Fri, 15 Nov 2002 08:51:32 -0600
On Thursday, November 14, 2002, at 11:57 AM, Jim Hourihan wrote:
>
I've got a 3d app with a scene transformation hierarchy that I'm
>
displaying
>
in an NSOutlineView. You can select objects in the scene in the 3d
>
view as
>
well as in the NSOutlineView. So here are my questions:
>
>
* I appears that I cannot rely on NSOutlineView maintaining
>
selection
>
state of hidden items. If I have something selected in the
>
outline
>
and collapse its parent then expand its parent, the item is no
>
longer
>
selected and no notification occurs. Do I need to reselect
>
everything
>
in the outline when anything is expanded?
That would be considered a bug if you don't get a notification that the
selection was changed. I guess you can always try to subclass
NSOutlineView to change this behaviour, but i don't know where you
should begin.
>
>
* How do I detect when selection is being extended by the user and
>
when
>
its being replaced? The delegate gets
>
outlineViewSelectionDidChange:
>
message, but that doesn't seem to be enough information? Am I
>
missing
>
something? I can't simply replace the selection with the
>
selection in
>
the NSOutlineView because it doesn't include hidden items. So I
>
need
>
to know if the user intended to modify the selection or replace
>
it.
>
This only option i see is to save the selection in
selectionShouldChangeInOutlineView, and then in
outlineViewSelectionDidChange to compare the old and the new. I guess
you could then guess if it was modified or replaced.
>
-Jim
hope this help, olivier
>
_______________________________________________
>
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.
_______________________________________________
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.