Join the AMA (Ask Me Anything) with the Firefox leadership team to celebrate Firefox 20th anniversary and discuss Firefox’s future on Mozilla Connect. Mark your calendar on Thursday, November 14, 18:00 - 20:00 UTC!

Este site está com funcionalidades limitadas enquanto realizamos manutenção para melhorar sua experiência de uso. Se nenhum artigo resolver seu problema e você quiser fazer uma pergunta, nossa comunidade de suporte pode te ajudar em @FirefoxSupport no Twitter e /r/firefox no Reddit.

Pesquisar no site de suporte

Evite golpes de suporte. Nunca pedimos que você ligue ou envie uma mensagem de texto para um número de telefone, ou compartilhe informações pessoais. Denuncie atividades suspeitas usando a opção “Denunciar abuso”.

Saiba mais

Esta discussão foi arquivada. Faça uma nova pergunta se precisa de ajuda.

Why ('ontouchstart' in window) is false on a touch tablet with Windows 8

  • 3 respostas
  • 3 têm este problema
  • 5 visualizações
  • Última resposta de RodiBenov

more options

I use Java Script to determine if my Web-Site is running on Tablet touch device The device is Assus tablet with windows 8

I use Java Script to determine if my Web-Site is running on Tablet touch device The device is Assus tablet with windows 8

Solução escolhida

Are you assuming that the return value is false because it is not true? According to this, null is sometimes returned instead of true. If false is actually returned, then I would think it is a fault with the tablet's browser. Either that or in the browser's settings there are options to pretend the device is something else (for testing purposes); there is no reason why these should be selected by default though.

If that's no help then please give us further details (such as the browser you are using).

Ler esta resposta 👍 0

Todas as respostas (3)

more options

Solução escolhida

Are you assuming that the return value is false because it is not true? According to this, null is sometimes returned instead of true. If false is actually returned, then I would think it is a fault with the tablet's browser. Either that or in the browser's settings there are options to pretend the device is something else (for testing purposes); there is no reason why these should be selected by default though.

If that's no help then please give us further details (such as the browser you are using).

more options

I solved my problem setting dom.w3c_touch_events.enabled to 0

more options

Sorry I mean setting dom.w3c_touch_events.enabled to 1