Skip to content

Instantly share code, notes, and snippets.

View androhi's full-sized avatar
🏠
Working from home

Takahiro Shimokawa androhi

🏠
Working from home
View GitHub Profile
POST:https://api.zaim.net/v2/home/money/payment?currency_code=JPY&category_id=1386826&amount=250&date=2014-04-02&genre_id=6471825&place=xxxx
LOCAL_PATH := $(call my-dir)
include $(CLEAR_VARS)
LOCAL_MODULE_TAGS := tests
LOCAL_SRC_FILES := $(call all-java-files-under, src)
LOCAL_PACKAGE_NAME := HelloNDK
LOCAL_SDK_VERSION := 14
android {
...
defaultConfig {
...
ndk {
moduleName "xxxx"
ldLibs "dl", "log"
stl "gnustl_shared"
}
@androhi
androhi / gist:8931848
Created February 11, 2014 09:36
AndroidStudioでネイティブコードを組み込むフォルダ構成
[Project]
|-- src
|-- main
|-- java
|-- jni
|-- xxxx.c
|-- xxxx.h
|-- jniLibs
|-- armeabi
|-- xxxx.so
@androhi
androhi / file0.txt
Created September 10, 2012 05:19
Androidで画面サイズを取得する方法 ref: http://qiita.com/items/c1171b4904b312c9023a
Display display = getWindowManager().getDefaultDisplay();
Point size = new Point();
overrideGetSize(display, size);
void overrideGetSize(Display display, Point outSize) {
try {
// test for new method to trigger exception
Class pointClass = Class.forName("android.graphics.Point");
Method newGetSize = Display.class.getMethod("getSize", new Class[]{ pointClass });
@androhi
androhi / zipalign.sh
Created September 7, 2012 08:41
手動でZipalignを行う方法 ref: http://qiita.com/items/9c7340d709e856f9b71e
# アラインを設定する
zipalign -v 4 [infile.apk] [outfile.apk]
# アラインが正しく設定されたか確認する
zipalign -c -v 4 [outfile.apk]