• 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: How can I detect a mouse click outside a child window on Leopard?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: How can I detect a mouse click outside a child window on Leopard?


  • Subject: Re: How can I detect a mouse click outside a child window on Leopard?
  • From: Michael Crawford <email@hidden>
  • Date: Tue, 14 Feb 2012 08:39:07 -0500

I was just looking at the documentation for NSApplication and wondering if overriding sendEvent is the way to go?  I was thinking I could monitor events dispatched to my app and then, when one arrives that is not destined for the child window, dismiss the popover.  I can also dismiss the popover if the application loses focus.

I haven't tried these ideas out yet, but will do so later on today.  If you know these ideas will not work or you have alternates, please feel free speak up.

-Michael

On Feb 14, 2012, at 8:22 AM, Michael Crawford wrote:

> I've implemented something like NSPopover on Leopard (10.5).  I would like this popover to disappear if the user clicks anywhere outside of the popover but I'm not sure how to do this.  Theoretically, I should be able to make the child window modal but I'm not sure that would help.  Also, I assume there is a way to capture the mouse from a given window but I've never done that before either.
>
> Suggestions?
>
> -Michael
> _______________________________________________
>
> 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

_______________________________________________

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: How can I detect a mouse click outside a child window on Leopard?
      • From: Uli Kusterer <email@hidden>
References: 
 >How can I detect a mouse click outside a child window on Leopard? (From: Michael Crawford <email@hidden>)

  • Prev by Date: Re: Odd display of percent character
  • Next by Date: Re: Playing Music in Objective C
  • Previous by thread: How can I detect a mouse click outside a child window on Leopard?
  • Next by thread: Re: How can I detect a mouse click outside a child window on Leopard?
  • Index(es):
    • Date
    • Thread