In article
,
p2 wrote:
> On Feb 11, 6:57 pm, Gregory Weston wrote:
> > In article
> > ,
> >
> > p2 wrote:
> > > Hi
> >
> > > By clicking outside the View area, How can we get mouseDown event in
> > > NSView?
> >
> > The question makes no sense. What are you really trying to do? NSEvent
> > and NSWindow both have methods to find out where the mouse is *right
> > now* but determining when to send those messages those really depends on
> > your goal. As does, for what it's worth, *if* you really need to do
> > that.
>
> Hi
> Thanks for viewing,
>
> I am trying like,
>
> I created one Panel. If i click outside the Panel then i want Panel
> will be closed.
> How can I achieve this ?
If you want your panel to hide when your application is not active,
either use NSPanel or use an NSWindow subclass that overrides
hidesOnDeactivate to return YES.
If you want your panel to hide just because it no longer has input
focus, my primary recommendation is that your rethink your design.
>> Stay informed about: to get mouseDown Event outside the View area