Give references to study Xamarin
이번에 안드로이드에 올린 어플 중에, 광고를 제거한 버전을 올려달라는 요청을 받게 되었다. 이렇게 무료/유료 버전의 앱을 개발하여 마켓에 올릴 경우에 어떻게 해야 코딩의 중복을 제거하고 효과적인 코딩이 가능한지 하는 부분에 대해 확실히 공부하며 정리하는 차원에서 글을 써보고자 한다. 1. 어떻게…
2008년 부터 시작된 구글의 개발자 컨퍼런스인 ‘Google I/O 2011’ 의 막이 올랐다. 먼저, 키노트를 통해서 안드로이드의 현황과 나아갈 방향에 대해 알아보자. Remarkable Growth 현재 안드로이드는 다양한 휴대폰 제조업체, 통신사, 개발자의 지원으로 2011년 1억개 개통을 돌파 했으며, 하루 40만대 이상의 새로운…
The rules below are not guidelines or recommendations, but strict rules. Contributions to Android generally will not be accepted if they do not adhere to these rules. Not all existing code follows these rules, but all new code is expected to.…
[code lang=”java”] // Create empty bitmap Bitmap bitmap = Bitmap.createBitmap(width, height, Bitmap.Config.ARGB_8888); // Create canvas to draw drawable Canvas canvas = new Canvas(bitmap); // Set bounds d.setBounds(0, 0, 48, 48); // Draw drawable to canvas d.draw(canvas); // Save canvas canvas.save();…
API Level 9 이전 버전 [code lang=”java”] PackageManager pm = context.getPackageManager(); ApplicationInfo appInfo = pm.getApplicationInfo("app.package.name", 0); String appFile = appInfo.sourceDir; long installed = new File(appFile).lastModified(); [/code] API Level 9 이상 [code lang=”java”] long installed = context.getPackageManager().getPackageInfo("package.name", 0).firstInstallTime; [/code] Reference
The ability for your application to install on the external storage is a feature available only on devices running API Level 8 (Android 2.2) or greater. Existing applications that were built prior to API Level 8 will always install on…
사용자의 요청에 의해 외부 저장소에 설치가 되도록 하기 [code lang=”java”] <manifest xmlns:android="; android:installLocation="preferExternal"> [/code] 시스템이 알아서 자동으로 설치 되도록 하기 [code lang=”java”] <manifest xmlns:android="; android:installLocation="auto"> [/code]
[code lang=”java”] // 현재 설정된 언어의 코드를 리턴한다. (예, ko) Locale.getDefault().getDisplayLanguage(); // 현재 설정된 언어의 국가를 리턴한다. (예, KR) Locale.getDefault().getDisplayCountry(); // 현재 설정된 언어를 문자열로 반환한다. (예, ko_KR) Locale.getDefault().toString(); [/code]