diff --git a/.idea/kotlinc.xml b/.idea/kotlinc.xml new file mode 100644 index 0000000..5806fb3 --- /dev/null +++ b/.idea/kotlinc.xml @@ -0,0 +1,7 @@ + + + + + \ No newline at end of file diff --git a/app/build.gradle b/app/build.gradle index 365d769..3bd451f 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -1,17 +1,17 @@ apply plugin: 'com.android.application' android { - compileSdkVersion 26 + compileSdkVersion 27 defaultConfig { applicationId "com.tksls.yellowrectangle" - minSdkVersion 19 - targetSdkVersion 26 + minSdkVersion 23 + targetSdkVersion 27 versionCode 1 versionName "1.0" testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner" externalNativeBuild { cmake { - cppFlags "" + cppFlags "-std=c++11" } } } @@ -30,7 +30,7 @@ android { dependencies { implementation fileTree(dir: 'libs', include: ['*.jar']) - implementation 'com.android.support:appcompat-v7:26.1.0' + implementation 'com.android.support:appcompat-v7:27.1.0' implementation 'com.android.support.constraint:constraint-layout:1.0.2' testImplementation 'junit:junit:4.12' androidTestImplementation 'com.android.support.test:runner:1.0.1' diff --git a/app/src/main/cpp/native-lib.cpp b/app/src/main/cpp/native-lib.cpp index 5e4ff20..defe50f 100644 --- a/app/src/main/cpp/native-lib.cpp +++ b/app/src/main/cpp/native-lib.cpp @@ -10,7 +10,7 @@ int main(int argc, char **argv) { al_install_touch_input(); al_install_keyboard(); - auto display = al_create_display(0, 0); + auto display = al_create_display(640, 480); auto queue = al_create_event_queue(); auto redraw = true; auto done = false; diff --git a/app/src/main/java/com/tksls/yellowrectangle/DrawYellowRectangle.java b/app/src/main/java/com/tksls/yellowrectangle/DrawYellowRectangle.java index 8406eaa..c24bcf0 100644 --- a/app/src/main/java/com/tksls/yellowrectangle/DrawYellowRectangle.java +++ b/app/src/main/java/com/tksls/yellowrectangle/DrawYellowRectangle.java @@ -3,19 +3,23 @@ package com.tksls.yellowrectangle; +import android.util.Log; + import org.liballeg.android.AllegroActivity; public class DrawYellowRectangle extends AllegroActivity { + @Override + public void onStart() { + super.onStart(); + Log.i("DrawYellowRectangle", "On Start ....."); + } + static { System.loadLibrary("allegro"); System.loadLibrary("allegro_primitives"); - System.loadLibrary("allegro_image"); - System.loadLibrary("allegro_font"); - System.loadLibrary("allegro_ttf"); - System.loadLibrary("allegro_audio"); - System.loadLibrary("allegro_acodec"); System.loadLibrary("allegro_color"); } + public DrawYellowRectangle() { super("libnative-lib.so"); }