Hi all,
The NSEvent locationInWindow docs say: "For non-mouse events the return value
of this method is undefined."
I've just been bitten by this. Seems it would be easy to detect at runtime and
assert, is there any magic environment variable or defaults value that can help
me catch such inco
On Feb 13, 2012, at 1:25 PM, Sean McBride wrote:
> The NSEvent locationInWindow docs say: "For non-mouse events the return value
> of this method is undefined."
>
> I've just been bitten by this. Seems it would be easy to detect at runtime
> and assert, is there any magic environment variable
> I've just been bitten by this. Seems it would be easy to detect at runtime
> and assert, is there any magic environment variable or defaults value that
> can help me catch such incorrect usage? I've searched but not found...
I don't know if there's any runtime/debug value, but this is one of
On 15 Feb, 2012, at 1:18 , cocoa-dev-requ...@lists.apple.com wrote:
> The NSEvent locationInWindow docs say: "For non-mouse events the return value
> of this method is undefined."
>
> I've just been bitten by this. Seems it would be easy to detect at runtime
> and assert, is there any magic e
On Feb 14, 2012, at 8:18 PM, Jim McGowan wrote:
> On 15 Feb, 2012, at 1:18 , cocoa-dev-requ...@lists.apple.com wrote:
>
>> I've just been bitten by this. Seems it would be easy to detect at runtime
>> and assert, is there any magic environment variable or defaults value that
>> can help me ca
On Tue, 14 Feb 2012 21:08:38 -0800, Kyle Sluder said:
>> Are you calling -type on the events you are receiving? Checking that
>value should make it clear whether the event you have received is a
>mouse event or not. If not, and you need the mouse location, you can
>get if from NSEvent's +mouseLoc
What it sounds like you're really asking in the latest part of this thread is
for every object in a given runtime to track the messages called upon it with a
time stamp in order to compare those for an exact ordering of calls conducive
to your needs.
That COULD be useful, but it would be really
On Wed, 15 Feb 2012 09:56:33 -0800, Gary L. Wade said:
>What it sounds like you're really asking in the latest part of this
>thread is for every object in a given runtime to track the messages
>called upon it with a time stamp in order to compare those for an exact
>ordering of calls conducive to
On Feb 15, 2012, at 08:12 , Sean McBride wrote:
> In the meantime, I'll create a category method that wraps locationInWindow
> and delegates to mouseLocation or similar otherwise.
Depending on how correct you want to be, you do have to be a bit cautious with
this. +[NSEvent mouseLocation] isn't