로그인/로그아웃 처리 시 세션이 맞지 않는 문제로 인하여 초기화가 필요할 경우가 생김. CookieSyncManager cookieSyncManager = CookieSyncManager.createInstance(this);CookieManager cookieManager = CookieManager.getInstance();cookieManager.setAcceptCookie(true);cookieManager.removeSessionCookie();cookieSyncManager.sync(); //쿠키값 삭제 확인. Log.e("cc", "cookie " +CookieManager.getInstance().getCookie("도메인 URL")); 해당 코드를 실행 후 쿠키값을 찍어보면 null이 발..
public ArrayList mixRandomNumber(int mixCnt) {ArrayList list = new ArrayList();ArrayList mixAry = new ArrayList();Random random = new Random();for(int i = 0; i < mixCnt; ++i) {list.add(i);} for(int i = list.size(); i > 0; i--){int index = random.nextInt(i); int rNum = list.get(index); mixAry.add( rNum);list.remove(index); }list = null;Log.e("XXX","result"+mixAry.get(0)+"__"+mixAry.get(1)+"__"+mi..
http://www.bytefoundry.co.uk/blog/?p=140 알람 등록 및 삭제, 팝업까지 표출. activity를 투명하게 하고 싶다면. android:theme="@android:style/Theme.Translucent.NoTitleBar" 잠금 화면에서 알람이 울리지 않을 경우나 팝업이 뜨지않는다면http://aroundck.tistory.com/48 PendingIntent에 putExtra 로 값을 넘겼을 때 바뀌지 않는다면. PendingIntent alarmPI = PendingIntent.getBroadcast( this, i, alarmIntent, PendingIntent.FLAG_UPDATE_CURRENT); 마지막 Flag값 수정해 줄것.
android:gravity="center_horizontal|center_vertical" '|' 기호를 이용하여 속성을 중첩 시킬 수 있다. (공백이 있으면 안됨) center_horizontal 가로 방향 중앙정렬 center_vertical 세로 방향 중앙정렬 left 왼쪽 정렬 right 오른쪽 정렬 top 상단 정렬 bottom 하단 정렬 center 중앙정렬 fill 가로 세로로 가득 채움 fill_vertical 세로 방향으로 가득 채움 fill_horizontal 가로 방향으로 가득 채움 보다 자세한 내용은 래퍼런스 참조http://developer.android.com/reference/android/view/Gravity.html