Ver Mensaje Individual
  #4 (permalink)  
Antiguo 27/03/2013, 04:20
KatonSP
 
Fecha de Ingreso: abril-2009
Mensajes: 63
Antigüedad: 15 años
Puntos: 0
Respuesta: Evitar giro del navegador

Ya he resuelto mi problema, he creado un metodo de escucha para saber si cambia el tamaño de la pantalla.

Por si alguien lo necesita dejo el código.

Código HTML:
screenWidth = $(window).width();
screenHeight = $(window).height();
               
               setInterval(function () {
                           if ($(window).width() !== screenWidth || $(window).height() !== screenHeight) {
                           screenWidth = $(window).width();
                           screenHeight = $(window).height();
                           
                           alert('entra');                           
                           }
                }, 50);
Saludos!