반응형

http://www.saramin.co.kr/zf_user/career-information/professional-tip-view?category_cd=101&jikjong_bcode=&searchfield=&searchword=%BF%AC%BA%C0&page=1&doc_idx=17666


<개발 전문통> 연도별 IT 업계 인기 직업&연봉 大 공개!
연도별로 주목받은 IT 직업을 소개합니다!
직업의 연봉을 확인하시고 국내 유사 직업과 연봉을 비교해보세요!
(※ 정렬기준 : 연도 순)
연도별 주목받은 IT 직군의 연봉 정보!
연도직업군구분미국 연봉국내 유사직 연봉
20142015
1999네트워크 아키텍트
(network architects)
달러$109,250 - $156,500$115,000 - $165,2503,600만 원
(네트워크관리사)
1억 2천만 - 1억 7천만1억 3천만 - 1억 8천만
인터넷/인트라넷 개발자
(internet/
intranet developers)
달러$ 70,000 - $113,500$ 73,500 - $122,0003,000만 원
(웹프로그래머)
8천만 - 1억 2천만8천만 - 1억 3천만
2004데이터 보안 분석가
(data security analysts)
달러$100,500 - $137,250$106,250 - $149,0004,000만 원
(컴퓨터보안전문가)
1억 1천만 - 1억 5천만1억 2천만 - 1억 6천만
어플리케이션 설계자
(applications architects)
달러$109,750 - $148,750$115,750 - $159,500-
1억 2천만 - 1억 6천만1억 3천만 - 1억 7천만
고급 인터넷/
인트라넷 개발자
(senior Internet/
intranet developers)
달러$ 97,750 - $135,250$104,500 - $144,2503,000만 원
(웹엔지니어)
1억 1천만 - 1억 5천만1억 1천만 - 1억 6천만
2009웹 개발자
(web developers)
달러$ 70,000 - $113,500$ 73,500 - $122,0003,000만 원
(웹프로그래머)
8천만 - 1억 2천만8천만 - 1억 3천만
프로그램 분석가
(programmer analysts)
달러$ 69,250 - $122,250$ 74,250 - $129,0003,650만 원
(컴퓨터시스템
설계분석가)
8천만 - 1억 3천만8천만 - 1억 4천만
2014모바일 앱 개발자
(Mobile applications
developers)
달러$100,000 - $144,000$107,500 - $161,5002,500만 원
(스마트폰앱개발자)
1억 1천만 - 1억 6천만1억 2천만 - 1억 8천만
소프트웨어 개발자
(Software developers)
달러$ 80,250 - $127,250$ 85,500 - $136,2503,450만 원
(시스템
소프트웨어개발자)
9천만 - 1억 4천만9천만 - 1억 5천만
BI분석가
(Business intelligence
analysts)
달러$101,250 - $142,250$108,500 - $153,000-
1억 1천만 - 1억 6천만1억 2천만 - 1억 7천만
2015모바일 앱 개발자
(Mobile applications
developers)
달러$100,000 - $144,000$107,500 - $161,5002,500만 원
(스마트폰앱개발자)
1억 1천만 - 1억 6천만1억 2천만 - 1억 8천만
빅데이터 엔지니어
(Big data engineer)
달러$110,250 - $152,750$119,250 - $168,250-
1억 2천만 - 1억 7천만1억 3천만 - 1억 8천만
네트워크 아키텍트
(Network architect)
달러$109,250 - $156,500$115,000 - $165,2503,600만 원
(네트워크관리자)
1억 2천만 - 1억 7천만1억 3천만 - 1억 8천만
데이터 보안 분석가
(Data security analyst)
달러$100,500 - $137,250$106,250 - $149,0004,000만 원
(컴퓨터보안전문가)
1억 1천만 - 1억 5천만1억 2천만 - 1억 6천만
고급 웹 개발자
(Senior web developer)
달러$ 97,750 - $135,250$104,500 - $144,2503,000만 원
(웹프로그래머)
1억 1천만 - 1억 5천만1억 1천만 - 1억 6천만




해외 취업 하고 싶다 

학교 댕길때 영어좀 열심히 해둘껄 ㅠㅠ


반응형
반응형

 

gradle 을 정말 무식하게 필요할때 마다 검색해서 사용 ㅎㅎ

 

build.gradle 에서

 

defaultConfig {

..

..

          versionCode 5
            versionName "1.0.6"

 

}

위에 두개 변경하고

 

터미널에서 요것만 해주면 새로 업데이트 할수있다

 

gradlew aR

 

물론 아래 동영상 처림 기본 세팅은 해줘야 한다 ㅋㅋ

세팅후 몇달에 한번 업데이트 하는데 위 명령어가 항상 새롭다 ㅎㅎㅎ

 

 

기본세팅 출처 http://androidhuman.com/544

 

 

반응형
반응형



https://projectlombok.org/


class 파일 만들때

위 라이브러리 사용하면 get set 및 여러가지 기본 세팅을 자동으로 만들어준다

@Data 어노테이션을 이용하면 ~!!!


편리하다


스프링 부트 공부하면서 알게된 라이브러리 ㅎㅎ


다운받고 

cmd

해당 폴더에서 

java -jar lombok.jar


설치할 IDE 선택하라고 나온다 설치 후 재시작


잘된다 ㅋ 








반응형
반응형

인스톨 하는데 뭔가 자꾸 오류


앜~!!


폭풍서치


기본 설치 법

Http://subbangtown.tistory.com/28


설치중 오류 (Myly 빼고 설치)

에러의 내용은 녀ㅠ치ㅑㅔㄴㄷ 설치중에 ㅡㅛㅣㅛㅜ 3.ㅌ 통합하는걸 옵션으로 할 수 있는데 보통 통째로 설치하기때문에 이 옵션이 걸려 이녀석을 설치할 때 에러가 나는것이다. 그럼 해결법은 무엇일까? 나름 구글링을 많이 해봤지만 가장 쉽고 효율적인 방법은 이거였다.


그냥, 저거 빼고 설치해! 


어차피 선택사항이기에 뺀다고해서 ㄴ푸 이용에는 전혀 관련이 없다. (ㅡㅛㅣㅛㅜ은 ㅅㅁ나관리 플러그인으로 알고있다) 아래와 같이 설치시 ㅑㅜㅅㄷㅎㄱㅁ샤ㅐㅜ 랙 ㅡㅛㅣㅛㅜ 을 체크해제하고 진행하면 된다. 또한, 채ㅜㅅㅁㅊㅅ 미ㅣ ㅕㅔㅇㅁㅅㄷ 냣ㄷㄴ 여갸ㅜㅎ ㅑㅜㄴㅅ미ㅣ 새 랴ㅜㅇ ㄱㄷ벼ㅑㄱㄷㅇ 냀ㅈㅁㄱㄷ 를 체크해제해야 정상적으로 설치가 된다.


Http://dpug.tistory.com/21



반응형
반응형

에스오일 실적이 좋을것이란 이야기

하도 많이 봐서


소량 매수 100주 정도

9시 30분정도

61000원



실적 발표 오전 10시  난후 6% 오름

64900원



그후 오후 1시 다시 61000원 되었음


심리적으로 막 팔고 싶음

더러운 주식이라는 느낌 



하지만 조금 경험으로 지금 팔면 더 마음 아플것 같음

기록으로 남겨둠 ㅎㅎ

반응형
반응형


네이버 메모 앱 하단으로 스크롤 할때 마다 

하나씩 글을 불러오는 기능이 좋아보임..

키워드를 모르겠다.. 

안드로이드에서만 되는건지 웹에서도 가능한건지..



스크롤 하단에서 100px 정도 이동하면 아래에 append 로 붙이면 될꺼 같은데 소스 찾기가 쉽지 않음 ㅠㅠ



http://greensock.com/examples-showcases ( 시간차를 두면서 이용하는 스크립트)


http://jsfiddle.net/inspired_jw/KCC8V/1/ (하단에 왔을때 체크하는 소스)

반응형
반응형


HTML 은 그냥 xls로 확장자만 변환하여 다운받게 하였더니

액셀 에서 읽을때 오류가 발생... web페이지로 인식하는듯..


그래서 poi 이용 다운로드 찾아봄...


1. 서블릿 예제 입니다.

response.setContentType("application/vnd.ms-excel");
response.setHeader("Content-Disposition", "attachment; filename=filename.xls");
HSSFWorkbook workbook = new HSSFWorkbook();
// ...
// Now populate workbook the usual way.
// ...
workbook.write(response.getOutputStream()); // Write workbook to response.
workbook.close();


2. JSP 예제 입니다.

<%@page import="org.apache.poi.hssf.usermodel.*" %><%@page import="java.io.*" %><%

// create a small spreadsheet
HSSFWorkbook wb = new HSSFWorkbook();
HSSFSheet sheet = wb.createSheet();
HSSFRow row = sheet.createRow(0);
HSSFCell cell = row.createCell(0);
cell.setCellValue("Some text");

// write it as an excel attachment
ByteArrayOutputStream outByteStream = new ByteArrayOutputStream();
wb.write(outByteStream);
byte [] outArray = outByteStream.toByteArray();
response.setContentType("application/ms-excel");
response.setContentLength(outArray.length);
response.setHeader("Expires:", "0"); // eliminates browser caching
response.setHeader("Content-Disposition", "attachment; filename=testxls.xls");
OutputStream outStream = response.getOutputStream();
outStream.write(outArray);
outStream.flush();

%>

출처

http://okky.kr/article/279848

반응형
반응형

우선 weblogic 다운 받아 설치..


http://www.oracle.com/kr 여기가서 미들웨어 weblogic 포함 다운받는다


여기 자세한 설명 

http://roadrunner.tistory.com/415


그냥그냥 담담 설치 후


How to install and setup Oracle Weblogic + Eclipse - Part 1 of 2




굿 설명


다이내믹 웹 생성후 


servlet 테스트


내가 사용한  web.xml


<?xml version="1.0" encoding="UTF-8"?>

<web-app xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://java.sun.com/xml/ns/javaee" 

xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_3_0.xsd" 

id="WebApp_ID" version="3.0">


<servlet>
    <servlet-name>helloworld</servlet-name>
    <servlet-class>servlettest.HelloServlet</servlet-class>
</servlet>
<servlet-mapping>
    <servlet-name>helloworld</servlet-name>
    <url-pattern>/hello</url-pattern>
</servlet-mapping>
</web-app>



서블릿 테스트 참고한 곳

http://levin01.tistory.com/28



http://localhost:7001/com.youtube/  index.jsp 로딩 테스트


http://localhost:7001/com.youtube.hems/servlet  서블릿 호출 테스트


아오 이제 하나하나 붙이는 작업이 남았음  ㅠㅜ 기본 테스트는 완료 



반응형
반응형

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml">

<head>

<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />

<title>Flick Navigation</title>

<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0, user-scalable=no, target-densitydpi=medium-dpi" />


<style type="text/css">


/* Basic Style START (dohoons, 200803, 200908, 201011, 201106) */

html, body { height:100%; -webkit-text-size-adjust:none; }

body, input, select, button, textarea, h1, h2, h3, h4, h5, h6, table { font:normal 12px/1.5 dotum,"돋움",Arial,AppleGothic,Sans-serif; color:#666; }

html, body, div, form, input, select, button, textarea, legend, fieldset, h1, h2, h3, h4, h5, h6, ul, ol, dl, li, dt, dd, blockquote, address, p, th, td, caption { margin:0; padding:0; }

ol, ul, li { list-style:none; }

img, fieldset { border:0 none; }

input, select, textarea { vertical-align:middle; resize:none; position:relative; }

input, textarea { -webkit-appearance:none; -webkit-border-radius:0; }

input[type="checkbox"] { -webkit-appearance:checkbox; }

input[type="radio"] { -webkit-appearance:radio; -webkit-border-radius:10px; }

button { border:0 none; background:transparent; cursor:pointer; }

hr { display:none; }

legend, .hide { width:0; height:0; visibility:hidden; font-size:0; line-height:0; position:absolute; top:0; left:0; overflow:hidden; }

table caption { width:0; height:0; visibility:hidden; text-indent:-9999px; font-size:0; line-height:0; }

table { border-collapse:collapse; border-spacing:0; }

header, footer, section, article, aside, nav, hgroup, details, menu, figure, figcaption { display:block; }


a:link, a:visited { text-decoration:none; color:#666; }

a:active, a:hover, a:focus { text-decoration:underline; }


input.basic { height:19px; line-height:19px; padding:0 5px; border:1px solid #cacaca; *margin-top:-1px; _margin-top:-2px; }

textarea.basic { border:1px solid #cacaca; padding:5px; overflow:scroll; overflow-x:hidden; *margin-top:-1px; _margin-top:-2px; }

select.basic { height:21px; }

/* Basic Style END */


#touchSlider6 { width:100%; height:150px; margin:0 auto; background:#ccc; position:relative; overflow:hidden; }

#touchSlider6 ul { width:99999px; height:150px; position:absolute; top:0; left:0; overflow:hidden; }

#touchSlider6 ul li { float:left; width:100%; height:150px; background:#9C9; font-size:14px; color:#fff; }



.btn_area { background:#f5f5f5; overflow:hidden; }

.btn_area button { display:block; width:100px; height:36px; background:#000; font-size:16px; color:#fff; font-weight:bold; }

.btn_area button.btn_prev { float:left; }

.btn_area button.btn_next { float:right; }

.btn_area .btn_page { display:inline-block; width:10px; height:10px; margin:3px; font-size:0px; line-height:0; text-indent:-9999px; background:#3399CC; }

.btn_area .btn_page.on { background:#ff0000; }



</style>

<script type="text/javascript" src="https://ajax.googleapis.com/ajax/libs/jquery/1.8.0/jquery.min.js"></script>

<script type="text/javascript" src="../js/jquery.event.drag-1.5.min.js"></script>

<script type="text/javascript" src="../js/jquery.touchSlider.js"></script>

<script type="text/javascript">


  $(document).ready(function() {



$("#touchSlider6").touchSlider({


flexible : true,

initComplete : function (e) {

$("#touchSlider6_paging").html("");

var num = 1;

$("#touchSlider6 ul li").each(function (i, el) {

if((i+1) % e._view == 0) {

$("#touchSlider6_paging").append('<button type="button" class="btn_page">page' + (num++) + '</button>');

}

});

$("#touchSlider6_paging .btn_page").bind("click", function (e) {

var i = $(this).index();

$("#touchSlider6").get(0).go_page(i);

});

},

counter : function (e) {

$("#touchSlider6_paging .btn_page").removeClass("on").eq(e.current-1).addClass("on");

}

});


});

</script>


 </head>


 <body>


  <h2>6 : flexible, rolling, paging, counter</h2>

<div id="touchSlider6">

<ul>

<li>

content 1

</li>

<li style="background:#396">

content 2

</li>

<li style="background:#39C">

content 3

</li>

<li style="background:#33C">

content 4

</li>

</ul>

</div>


<div id="touchSlider6_paging" class="btn_area" style="text-align:center;"></div>



 </body>

</html>



jquery.event.drag-1.5.min.js


/* 

jquery.event.drag.js ~ v1.5 ~ Copyright (c) 2008, Three Dub Media (http://threedubmedia.com)  

Liscensed under the MIT License ~ http://threedubmedia.googlecode.com/files/MIT-LICENSE.txt

*/

(function(E){E.fn.drag=function(L,K,J){if(K){this.bind("dragstart",L)}if(J){this.bind("dragend",J)}return !L?this.trigger("drag"):this.bind("drag",K?K:L)};var A=E.event,B=A.special,F=B.drag={not:":input",distance:0,which:1,dragging:false,setup:function(J){J=E.extend({distance:F.distance,which:F.which,not:F.not},J||{});J.distance=I(J.distance);A.add(this,"mousedown",H,J);if(this.attachEvent){this.attachEvent("ondragstart",D)}},teardown:function(){A.remove(this,"mousedown",H);if(this===F.dragging){F.dragging=F.proxy=false}G(this,true);if(this.detachEvent){this.detachEvent("ondragstart",D)}}};B.dragstart=B.dragend={setup:function(){},teardown:function(){}};function H(L){var K=this,J,M=L.data||{};if(M.elem){K=L.dragTarget=M.elem;L.dragProxy=F.proxy||K;L.cursorOffsetX=M.pageX-M.left;L.cursorOffsetY=M.pageY-M.top;L.offsetX=L.pageX-L.cursorOffsetX;L.offsetY=L.pageY-L.cursorOffsetY}else{if(F.dragging||(M.which>0&&L.which!=M.which)||E(L.target).is(M.not)){return }}switch(L.type){case"mousedown":E.extend(M,E(K).offset(),{elem:K,target:L.target,pageX:L.pageX,pageY:L.pageY});A.add(document,"mousemove mouseup",H,M);G(K,false);F.dragging=null;return false;case !F.dragging&&"mousemove":if(I(L.pageX-M.pageX)+I(L.pageY-M.pageY)<M.distance){break}L.target=M.target;J=C(L,"dragstart",K);if(J!==false){F.dragging=K;F.proxy=L.dragProxy=E(J||K)[0]}case"mousemove":if(F.dragging){J=C(L,"drag",K);if(B.drop){B.drop.allowed=(J!==false);B.drop.handler(L)}if(J!==false){break}L.type="mouseup"}case"mouseup":A.remove(document,"mousemove mouseup",H);if(F.dragging){if(B.drop){B.drop.handler(L)}C(L,"dragend",K)}G(K,true);F.dragging=F.proxy=M.elem=false;break}return true}function C(M,K,L){M.type=K;var J=E.event.handle.call(L,M);return J===false?false:J||M.result}function I(J){return Math.pow(J,2)}function D(){return(F.dragging===false)}function G(K,J){if(!K){return }K.unselectable=J?"off":"on";K.onselectstart=function(){return J};if(K.style){K.style.MozUserSelect=J?"":"none"}}})(jQuery);



jquery.touchSlider.js


/**

 * @name jQuery.touchSlider

 * @author dohoons ( http://dohoons.com/ )

 *

 * @version 201504

 * @since 201106

 *

 * @param Object settings 환경변수 오브젝트

 * roll - 순환 (default true)

 * flexible - 유동 레이아웃 (default false)

 * view - 다중 컬럼 (default 1)

 * speed - 애니메이션 속도 (default 75)

 * range - 넘김 판정 범위 (default 0.15)

 * page - 초기 페이지 (default 1)

 * transition - CSS3 transition 사용 (default true)

 * btn_prev - prev 버튼 (jQuery Object, default null)

 * btn_next - next 버튼 (jQuery Object, default null)

 * paging - page 버튼 (jQuery Object, default null)

 * initComplete - 초기화 콜백

 * counter - 슬라이드 콜백, 카운터

 *

 * @example

 

$("#target").touchSlider({

flexible : true

});


*/


(function ($) {

$.fn.touchSlider = function (settings) {

settings.supportsCssTransitions = (function (style) {

var prefixes = ['Webkit','Moz','Ms'];

for(var i=0, l=prefixes.length; i < l; i++ ) {

if( typeof style[prefixes[i] + 'Transition'] !== 'undefined') {

return true;

}

}

return false;

})(document.createElement('div').style);

settings = jQuery.extend({

roll : true,

flexible : false,

btn_prev : null,

btn_next : null,

paging : null,

speed : 75,

view : 1,

range : 0.15,

page : 1,

transition : true,

initComplete : null,

counter : null

}, settings);

var opts = [];

opts = $.extend({}, $.fn.touchSlider.defaults, settings);

return this.each(function () {

var _this = this;

$.fn.extend(this, touchSlider);

this.opts = opts;

this.init();

$(window).bind("orientationchange resize", function () {

_this.resize(_this);

});

});

};

var touchSlider = {

init : function () {

var _this = this;

this._view = this.opts.view;

this._speed = this.opts.speed;

this._tg = $(this);

this._list = this._tg.children().children();

this._width = parseInt(this._tg.css("width"));

this._item_w = parseInt(this._list.css("width"));

this._len = this._list.length;

this._range = this.opts.range * this._width;

this._pos = [];

this._start = [];

this._startX = 0;

this._startY = 0;

this._left = 0;

this._top = 0;

this._drag = false;

this._scroll = false;

this._btn_prev;

this._btn_next;

$(this)

.unbind("touchstart", this.touchstart)

.unbind("touchmove", this.touchmove)

.unbind("touchend", this.touchend)

.unbind("dragstart", this.touchstart)

.unbind("drag", this.touchmove)

.unbind("dragend", this.touchend)

.bind("touchstart", this.touchstart)

.bind("touchmove", this.touchmove)

.bind("touchend", this.touchend)

.bind("dragstart", this.touchstart)

.bind("drag", this.touchmove)

.bind("dragend", this.touchend)

$(this).children().css({

"width":this._width + "px",

"overflow":"visible"

});

if(this.opts.flexible) this._item_w = this._width / this._view;

if(this.opts.roll) {

if(this._len % this._view > 0) {

var blank = $(document.createElement(this._list.eq(0).eq(0).prop("tagName"))).hide();

var cnt = this._view - (this._len % this._view);

for(var i=0; i<cnt; ++i) {

this._list.parent().append(blank.clone());

}

}

this._list = this._tg.children().children();

this._len = this._list.length;

this._len = (this._len / this._view) * this._view;

}

var page_gap = (this.opts.page > 1 && this.opts.page <= this._len) ? (this.opts.page - 1) * this._item_w : 0;

for(var i=0; i<this._len; ++i) {

this._pos[i] = this._item_w * i - page_gap;

this._start[i] = this._pos[i];

this._list.eq(i).css({

"float" : "none",

"position" : "absolute",

"top" : "0",

"left" : this._pos[i] + "px",

"width" : this._item_w + "px"

});

if(this.opts.supportsCssTransitions && this.opts.transition) {

this._list.eq(i).css({

"-moz-transition" : "0ms",

"-moz-transform" : "",

"-ms-transition" : "0ms",

"-ms-transform" : "",

"-webkit-transition" : "0ms",

"-webkit-transform" : "",

"transition" : "0ms",

"transform" : ""

});

}

}

if(this.opts.btn_prev && this.opts.btn_next) {

this.opts.btn_prev.unbind("click").bind("click", function() {

_this.animate(1, true);

return false;

})

this.opts.btn_next.unbind("click").bind("click", function() {

_this.animate(-1, true);

return false;

});

}

if(this.opts.paging) {

$(this._list).each(function (i, el) {

var btn_page = _this.opts.paging.eq(0).clone();

_this.opts.paging.before(btn_page);

btn_page.bind("click", function(e) {

_this.go_page(i, e);

return false;

});

});

this.opts.paging.remove();

}

this.initComplete();

this.counter();

},

initComplete : function () {

if(typeof(this.opts.initComplete) == "function") {

this.opts.initComplete(this);

}

},

resize : function (e) {

if(e.opts.flexible) {

var tmp_w = e._item_w;

e._width = parseInt(e._tg.css("width"));

e._item_w = e._width / e._view;

e._range = e.opts.range * e._width;

for(var i=0; i<e._len; ++i) {

e._pos[i] = e._pos[i] / tmp_w * e._item_w;

e._start[i] = e._start[i] / tmp_w * e._item_w;

e._list.eq(i).css({

"left" : e._pos[i] + "px",

"width" : e._item_w + "px"

});

if(this.opts.supportsCssTransitions && this.opts.transition) {

e._list.eq(i).css({

"-moz-transition" : "0ms",

"-moz-transform" : "",

"-ms-transition" : "0ms",

"-ms-transform" : "",

"-webkit-transition" : "0ms",

"-webkit-transform" : "",

"transition" : "0ms",

"transform" : ""

});

}

}

}

this.counter();

},

touchstart : function (e) {

if((e.type == "touchstart" && e.originalEvent.touches.length <= 1) || e.type == "dragstart") {

this._startX = e.pageX || e.originalEvent.touches[0].pageX;

this._startY = e.pageY || e.originalEvent.touches[0].pageY;

this._scroll = false;

this._start = [];

for(var i=0; i<this._len; ++i) {

this._start[i] = this._pos[i];

}

}

},

touchmove : function (e) {

if((e.type == "touchmove" && e.originalEvent.touches.length <= 1) || e.type == "drag") {

this._left = (e.pageX || e.originalEvent.touches[0].pageX) - this._startX;

this._top = (e.pageY || e.originalEvent.touches[0].pageY) - this._startY;

var w = this._left < 0 ? this._left * -1 : this._left;

var h = this._top < 0 ? this._top * -1 : this._top;

if (w < h || this._scroll) {

this._left = 0;

this._drag = false;

this._scroll = true;

} else {

if ( navigator.userAgent.indexOf("android 4.1") > -1 ) {

e.stopPropagation();

} else {

e.preventDefault();

}

this._drag = true;

this._scroll = false;

this.position(e);

}

for(var i=0; i<this._len; ++i) {

var tmp = this._start[i] + this._left;

if(this.opts.supportsCssTransitions && this.opts.transition) {

var trans = "translate3d(" + tmp + "px,0,0)";

this._list.eq(i).css({

"left" : "",

"-moz-transition" : "0ms",

"-moz-transform" : trans,

"-ms-transition" : "0ms",

"-ms-transform" : trans,

"-webkit-transition" : "0ms",

"-webkit-transform" : trans,

"transition" : "0ms",

"transform" : trans

});

} else {

this._list.eq(i).css("left", tmp + "px");

}

this._pos[i] = tmp;

}

}

},

touchend : function (e) {

if((e.type == "touchend" && e.originalEvent.touches.length <= 1) || e.type == "dragend") {

if(this._scroll) {

this._drag = false;

this._scroll = false;

return false;

}

this.animate(this.direction());

this._drag = false;

this._scroll = true;

}

},

position : function (d) { 

var gap = this._view * this._item_w;

if(d == -1 || d == 1) {

this._startX = 0;

this._start = [];

for(var i=0; i<this._len; ++i) {

this._start[i] = this._pos[i];

}

this._left = d * gap;

} else {

if(this._left > gap) this._left = gap;

if(this._left < - gap) this._left = - gap;

}

if(this.opts.roll) {

var tmp_pos = [];

for(var i=0; i<this._len; ++i) {

tmp_pos[i] = this._pos[i];

}

tmp_pos.sort(function(a,b){return a-b;});

var max_chk = tmp_pos[this._len-this._view];

var p_min = $.inArray(tmp_pos[0], this._pos);

var p_max = $.inArray(max_chk, this._pos);

if(this._view <= 1) max_chk = this._len - 1;

if((d == 1 && tmp_pos[0] >= 0) || (this._drag && tmp_pos[0] > 0)) {

for(var i=0; i<this._view; ++i, ++p_min, ++p_max) {

this._start[p_max] = this._start[p_min] - gap;

this._list.eq(p_max).css("left", this._start[p_max] + "px");

}

} else if((d == -1 && tmp_pos[max_chk] <= 0) || (this._drag && tmp_pos[max_chk] <= 0)) {

for(var i=0; i<this._view; ++i, ++p_min, ++p_max) {

this._start[p_min] = this._start[p_max] + gap;

this._list.eq(p_min).css("left", this._start[p_min] + "px");

}

}

} else {

if(this.limit_chk()) this._left = this._left / 2;

}

},

animate : function (d, btn_click) {

if(this._drag || !this._scroll || btn_click) {

var _this = this;

var speed = this._speed;

if(btn_click) this.position(d);

var gap = d * (this._item_w * this._view);

if(this._left == 0 || (!this.opts.roll && this.limit_chk()) ) gap = 0;

this._list.each(function (i, el) {

_this._pos[i] = _this._start[i] + gap;

if(_this.opts.supportsCssTransitions && _this.opts.transition) {

var transition = speed + "ms";

var transform = "translate3d(" + _this._pos[i] + "px,0,0)";

if(btn_click) transition = "0ms";

$(this).css({

"left" : "",

"-moz-transition" : transition,

"-moz-transform" : transform,

"-ms-transition" : transition,

"-ms-transform" : transform,

"-webkit-transition" : transition,

"-webkit-transform" : transform,

"transition" : transition,

"transform" : transform

});

} else {

$(this).animate({"left": _this._pos[i] + "px"}, speed);

}

});

this.counter();

}

},

direction : function () { 

var r = 0;

if(this._left < -(this._range)) r = -1;

else if(this._left > this._range) r = 1;

if(!this._drag || this._scroll) r = 0;

return r;

},

limit_chk : function () {

var last_p = parseInt((this._len - 1) / this._view) * this._view;

return ( (this._start[0] == 0 && this._left > 0) || (this._start[last_p] == 0 && this._left < 0) );

},

go_page : function (i, e) {

var crt = ($.inArray(0, this._pos) / this._view) + 1;

var cal = crt - (i + 1);

while(cal != 0) {

if(cal < 0) {

this.animate(-1, true);

cal++;

} else if(cal > 0) {

this.animate(1, true);

cal--;

}

}

},

get_page : function () {

return {

total : Math.ceil(this._len / this._view),

current : ($.inArray(0, this._pos) / this._view) + 1

}

},

counter : function () {

if($.inArray(0, this._pos) < 0) {

this.init();

}

this.opts.page = this.get_page().current;

if(typeof(this.opts.counter) == "function") {

this.opts.counter(this.get_page());

}

}

};


})(jQuery);



출처 http://dohoons.com/test/flick/



반응형
반응형

아무래 해도 import 가 안되어서 


혹시 하고 폴더명 한글로 된걸 영문으로 하니 바로 불러온다 ...


아오 ㅠㅠ


폴더명 한글로 하지 마세용~

반응형

+ Recent posts