changeset 34:19c584b29679

Add gradle files, bump rev to bypass installer cache misfeature.
author David Barts <n5jrn@me.com>
date Thu, 11 Mar 2021 17:31:56 -0800
parents bead5d7e8c69
children 6607f675a5f7
files .hgignore app/build.gradle app/src/main/java/com/bartsent/simpleresizer/lib/getScaledInstance.kt build.gradle settings.gradle
diffstat 5 files changed, 82 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/.hgignore	Sat Feb 27 19:27:07 2021 -0800
+++ b/.hgignore	Thu Mar 11 17:31:56 2021 -0800
@@ -1,7 +1,7 @@
 ~$
 \.bak$
 \.iml$
-\.gradle
+^\.gradle
 local.properties
 .idea/caches
 .idea/libraries
@@ -10,6 +10,7 @@
 .idea/navEditor.xml
 .idea/assetWizardSettings.xml
 \.DS_Store
+app/release
 build
 captures
 \.externalNativeBuild
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/app/build.gradle	Thu Mar 11 17:31:56 2021 -0800
@@ -0,0 +1,50 @@
+plugins {
+    id 'com.android.application'
+    id 'kotlin-android'
+}
+
+android {
+    compileSdkVersion 30
+    buildToolsVersion "30.0.3"
+
+    defaultConfig {
+        applicationId "com.bartsent.simpleresizer"
+        minSdkVersion 23
+        targetSdkVersion 30
+        versionCode 2
+        versionName "1.01"
+
+        testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
+    }
+
+    buildTypes {
+        release {
+            minifyEnabled false
+            proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
+        }
+    }
+    buildFeatures {
+        dataBinding true
+        viewBinding true
+    }
+    compileOptions {
+        sourceCompatibility JavaVersion.VERSION_1_8
+        targetCompatibility JavaVersion.VERSION_1_8
+    }
+    kotlinOptions {
+        jvmTarget = '1.8'
+    }
+}
+
+dependencies {
+
+    implementation "org.jetbrains.kotlin:kotlin-stdlib:$kotlin_version"
+    implementation 'androidx.core:core-ktx:1.3.2'
+    implementation 'androidx.appcompat:appcompat:1.2.0'
+    implementation 'com.google.android.material:material:1.3.0'
+    implementation 'androidx.constraintlayout:constraintlayout:2.0.4'
+    implementation 'androidx.preference:preference:1.1.1'
+    testImplementation 'junit:junit:4.+'
+    androidTestImplementation 'androidx.test.ext:junit:1.1.2'
+    androidTestImplementation 'androidx.test.espresso:espresso-core:3.3.0'
+}
\ No newline at end of file
--- a/app/src/main/java/com/bartsent/simpleresizer/lib/getScaledInstance.kt	Sat Feb 27 19:27:07 2021 -0800
+++ b/app/src/main/java/com/bartsent/simpleresizer/lib/getScaledInstance.kt	Thu Mar 11 17:31:56 2021 -0800
@@ -3,8 +3,8 @@
 import android.graphics.Bitmap
 
 /**
- * A quality scaler, rather simpler than Image.getScaledInstance in that it has only
- * one (slow, high-quality) option.
+ * A quality scaler, rather simpler than Image.getScaledInstance in that it
+ * currently has only one (slow, high-quality) option.
  * @param       newWidth        Width of new bitmap
  * @param       newHeight       Height of new bitmap
  * @return                      New bitmap
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/build.gradle	Thu Mar 11 17:31:56 2021 -0800
@@ -0,0 +1,26 @@
+// Top-level build file where you can add configuration options common to all sub-projects/modules.
+buildscript {
+    ext.kotlin_version = "1.4.31"
+    repositories {
+        google()
+        jcenter()
+    }
+    dependencies {
+        classpath "com.android.tools.build:gradle:4.1.2"
+        classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
+
+        // NOTE: Do not place your application dependencies here; they belong
+        // in the individual module build.gradle files
+    }
+}
+
+allprojects {
+    repositories {
+        google()
+        jcenter()
+    }
+}
+
+task clean(type: Delete) {
+    delete rootProject.buildDir
+}
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/settings.gradle	Thu Mar 11 17:31:56 2021 -0800
@@ -0,0 +1,2 @@
+include ':app'
+rootProject.name = "Simple Resizer"
\ No newline at end of file