On Thu, May 31, 2012 at 3:42 PM, Scott Graham <
sco...@chromium.org> wrote:
> On Thu, May 31, 2012 at 1:35 PM, Raymond Camden <
raymon...@gmail.com> wrote:
>> Wow... so when I slowly merge in your code - I see a gamepad. It's
>> like the act of asking for webkitGamepads actually gets the gamepad.
>>
>> Is that... is that how it is meant to be?
What I meant is this. Imagine an HTML page with no content (ok,
minimal content). I'd imagine that if I go to console and do
console.dir(navigator.webkitGamepads);
I'd see my gamepad. Right? But if you go to my demo and try that it
doesn't work. I mean you get an array of 4 empty items. But you don't
get my gamepad. When you hit my demo - disregarding the Firefox event
based code which won't work in Chrome - you won't see your gamepad.
Right?
Then you take your code - which loops over the arrays and just gets
basic data out of it. That _does_ work.
That is what doesn't make sense to me.
>
> I'm not sure what you're asking.
>
> Reading webkitGamepads will get you the current values for the
> gamepads connected to the system.
>
>>
>> On Thu, May 31, 2012 at 3:31 PM, Raymond Camden <
raymon...@gmail.com> wrote:
>>> Ok - what I don't get is this. Assuming my code is 100% wrong. In
>>> console in your link, I can console.dir(navigator.webkitGamepads) and
>>> I see my gamepad. In my demo, I don't. Shouldn't it show in the DOM
>>> (after hitting a few buttons, moving things, etc) on both?
>>>
>>> On Thu, May 31, 2012 at 3:24 PM, Raymond Camden <
raymon...@gmail.com> wrote:
>>>> Wow - that did work. So what the heck... digging...
>>>>
>>>> On Thu, May 31, 2012 at 3:12 PM, Scott Graham <
sco...@chromium.org> wrote:
>>>>> On Thu, May 31, 2012 at 12:56 PM, Raymond Camden
>>>>> <
raymon...@gmail.com> wrote:
>>>>>> Hmm - I can't get anything to show up in navgiator.webkitGamepads[].