• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Getting mouse events in view placed in NSTableRowView
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Getting mouse events in view placed in NSTableRowView


  • Subject: Re: Getting mouse events in view placed in NSTableRowView
  • From: email@hidden
  • Date: Fri, 23 Nov 2012 17:26:17 -0700

Hi Kyle,

Thanks for the comments.

On Nov 23, 2012, at 3:32 PM, Kyle Sluder <email@hidden> wrote:

> Are you sure you don't want to make it a subview of the cell view instead?

Sorry, I should have mentioned; I want the cell view that I click to remain where it is, and the custom detail view will be rather large and span multiple columns, so it can't be a subview of any single cell view.

>> Stepping through the debugger, I see that my NSTableRowView subclass is indeed being used, that it contains no other subviews than all of the NSTableRowView instances for each column plus the one I manually added. I put an NSLog statement in the NSTableRowView's mouseDown method, but no mouse downs are being recorded in the open space created by updating the height of the table. I have called "noteHeightOfRowsWithIndexesChanged" when making these changes.
>
> You seem to be confusing NSTableCellView with NSTableRowView.

Typo above, I meant to say that the NSTableRowView contains only the expected NSTableCellView instances (one for each column) plus the custom view I added.

>> Where are the mouse clicks going!?? This is driving me batty.
>
> You could try breaking on -[NSTableView hitTest:] and see what return value it puts in %rax on return. Or just compute a point within your control's frame and call -hitTest: from the debugger.

I tried hit test in a point that should be in my custom view, and it returned the NSTableView. I don't understand why the event seems to pass through my custom view and the NSTableRowView.

Cheers,
Demitri

_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Follow-Ups:
    • Re: Getting mouse events in view placed in NSTableRowView
      • From: Kyle Sluder <email@hidden>
References: 
 >Getting mouse events in view placed in NSTableRowView (From: email@hidden)
 >Re: Getting mouse events in view placed in NSTableRowView (From: Kyle Sluder <email@hidden>)

  • Prev by Date: Re: Getting mouse events in view placed in NSTableRowView
  • Next by Date: Re: NSArrayController KVO question...
  • Previous by thread: Re: Getting mouse events in view placed in NSTableRowView
  • Next by thread: Re: Getting mouse events in view placed in NSTableRowView
  • Index(es):
    • Date
    • Thread