Contents

조회 수 19368 댓글 0
?

단축키

Prev이전 문서

Next다음 문서

크게 작게 위로 아래로 댓글로 가기 인쇄
?

단축키

Prev이전 문서

Next다음 문서

크게 작게 위로 아래로 댓글로 가기 인쇄
<!DOCTYPE html>  
<html>  
<head>  
<title>Orientation Checker</title>  
<meta name="viewport" content="width=device-width; initial-scale=1.0; maximumscale=1.0; user-scalable=0;" />  
<script type="text/javascript" src="/js/jquery-1.6.1.min.js"></script>   
<script type="text/javascript">  
/*  
 * ios, android 둘다 지원되는 스크립트   
 */   
var ori_status;   
  
$(document).ready(function() {    
    window.onorientationchange = changeOrientation;  
    window.setTimeout(changeOrientation, 0);          
});  
  
// event handler  
function changeOrientation(){  
    if(ori_status == detectOrientation())return;  
    ori_status = detectOrientation();         
    alert(ori_status);    
}  
  
function detectOrientation(){  
    var orientation = window.orientation;   
    var rtn;  
  
    switch(orientation) {    
        case 90: case -90:    
            rtn = 'landscape';    
            break;    
        default:    
            rtn = 'portrait';    
    }    
    return rtn;  
}  
</script>  
</head>  
<body>  
  
</body>  
</html>  

?

  1. [ios] 아이폰용 앱 오픈 소스들

  2. [ios] 언어, 지역, 국가 설정 가져오기

  3. 자주 쓰는 Docker 명령어 alias

  4. 베지어 곡선 (Bezier curve)

  5. [ios] Start developing your navigation app for CarPlay without enrollment

  6. [android] 만화 어플 소스코드

  7. 레고 마인드스톰 NXT 수도쿠, 큐브 소스코드..

  8. 디피헬만(Diffie-Hellman) 초간단 개념..

  9. [c#] Hashtable <-> Json (dll 포함)

  10. [C#] MD5, SHA1 해시 & 인코딩

  11. [android] 점심 해결 앱 소스 코드 ㅋㅋ

  12. [android] XML파서(XMLParser)의 종류와 성능 비교에 대한 발표 자료

Board Pagination Prev 1 2 3 4 5 6 7 8 9 10 ... 98 Next
/ 98