Updated dependencies (Anko 0.10.7, Kotlin 1.3.0, etc.)

This commit is contained in:
Erik C. Thauvin 2018-11-04 18:44:54 -08:00
parent 9d9d504b41
commit b0e5e4d62d
10 changed files with 63 additions and 34 deletions

1
.gitignore vendored
View file

@ -2,6 +2,7 @@
*.sublime-*
.DS_Store
.gradle
/.idea/caches
/.idea/libraries
/.idea/workspace.xml
/build

29
.idea/codeStyles/Project.xml generated Normal file
View file

@ -0,0 +1,29 @@
<component name="ProjectCodeStyleConfiguration">
<code_scheme name="Project" version="173">
<Objective-C-extensions>
<file>
<option name="com.jetbrains.cidr.lang.util.OCDeclarationKind" value="Import" />
<option name="com.jetbrains.cidr.lang.util.OCDeclarationKind" value="Macro" />
<option name="com.jetbrains.cidr.lang.util.OCDeclarationKind" value="Typedef" />
<option name="com.jetbrains.cidr.lang.util.OCDeclarationKind" value="Enum" />
<option name="com.jetbrains.cidr.lang.util.OCDeclarationKind" value="Constant" />
<option name="com.jetbrains.cidr.lang.util.OCDeclarationKind" value="Global" />
<option name="com.jetbrains.cidr.lang.util.OCDeclarationKind" value="Struct" />
<option name="com.jetbrains.cidr.lang.util.OCDeclarationKind" value="FunctionPredecl" />
<option name="com.jetbrains.cidr.lang.util.OCDeclarationKind" value="Function" />
</file>
<class>
<option name="com.jetbrains.cidr.lang.util.OCDeclarationKind" value="Property" />
<option name="com.jetbrains.cidr.lang.util.OCDeclarationKind" value="Synthesize" />
<option name="com.jetbrains.cidr.lang.util.OCDeclarationKind" value="InitMethod" />
<option name="com.jetbrains.cidr.lang.util.OCDeclarationKind" value="StaticMethod" />
<option name="com.jetbrains.cidr.lang.util.OCDeclarationKind" value="InstanceMethod" />
<option name="com.jetbrains.cidr.lang.util.OCDeclarationKind" value="DeallocMethod" />
</class>
<extensions>
<pair source="cpp" header="h" fileNamingConvention="NONE" />
<pair source="c" header="h" fileNamingConvention="NONE" />
</extensions>
</Objective-C-extensions>
</code_scheme>
</component>

2
.idea/misc.xml generated
View file

@ -24,7 +24,7 @@
</value>
</option>
</component>
<component name="ProjectRootManager" version="2" languageLevel="JDK_1_7" project-jdk-name="1.8" project-jdk-type="JavaSDK">
<component name="ProjectRootManager" version="2" languageLevel="JDK_1_8" project-jdk-name="1.8" project-jdk-type="JavaSDK">
<output url="file://$PROJECT_DIR$/build/classes" />
</component>
<component name="ProjectType">

View file

@ -2,6 +2,7 @@
[![License](https://img.shields.io/badge/license-Apache%20License%202.0-blue.svg)](https://opensource.org/licenses/Apache-2.0)
[![Build Status](https://travis-ci.org/ethauvin/TESRemoteProgrammer.svg?branch=master)](https://travis-ci.org/ethauvin/TESRemoteProgrammer)
[![Known Vulnerabilities](https://snyk.io/test/github/ethauvin/tesremoteprogrammer/badge.svg?targetFile=app%2Fbuild.gradle)](https://snyk.io/test/github/ethauvin/tesremoteprogrammer?targetFile=app%2Fbuild.gradle)
[![CircleCI](https://circleci.com/gh/ethauvin/TESRemoteProgrammer/tree/master.svg?style=shield)](https://circleci.com/gh/ethauvin/TESRemoteProgrammer/tree/master)
[![License](https://img.shields.io/badge/android-Privacy%20Policy-orange.svg)](https://thauv.in/apps-privacy)

View file

@ -1,16 +1,17 @@
//noinspection GradleCompatible
apply plugin: 'com.android.application'
apply plugin: 'kotlin-android'
apply plugin: 'kotlin-android-extensions'
apply plugin: 'kotlin-kapt'
android {
compileSdkVersion 26
buildToolsVersion "26.0.2"
compileSdkVersion 27
buildToolsVersion '28.0.3'
defaultConfig {
applicationId "net.thauvin.erik.android.tesremoteprogrammer"
minSdkVersion 21
targetSdkVersion 26
targetSdkVersion 27
versionCode 1
versionName "1.0"
buildConfigField "long", "TIMESTAMP", System.currentTimeMillis() + "L"
@ -31,15 +32,15 @@ dependencies {
testImplementation 'junit:junit:4.12'
implementation 'com.android.support:support-v13:26.1.0'
implementation 'com.android.support:appcompat-v7:26.1.0'
implementation 'com.android.support:support-v13:27.1.1'
implementation 'com.android.support:appcompat-v7:27.1.1'
implementation "org.jetbrains.kotlin:kotlin-stdlib:$kotlin_version"
implementation 'org.jetbrains.anko:anko-sdk23:0.10.2'
implementation 'org.jetbrains.anko:anko-appcompat-v7:0.10.2'
implementation 'org.jetbrains.anko:anko-support-v4:0.10.2'
implementation 'org.jetbrains.anko:anko-design:0.10.2'
implementation 'com.android.support:design:26.1.0'
implementation group: 'com.google.code.gson', name: 'gson', version: '2.8.2'
implementation "org.jetbrains.anko:anko-sdk23:$anko_version"
implementation "org.jetbrains.anko:anko-appcompat-v7:$anko_version"
implementation "org.jetbrains.anko:anko-support-v4:$anko_version"
implementation "org.jetbrains.anko:anko-design:$anko_version"
implementation 'com.android.support:design:27.1.1'
implementation group: 'com.google.code.gson', name: 'gson', version: '2.8.5'
// https://github.com/JakeWharton/ViewPagerIndicator
implementation 'fr.avianey.com.viewpagerindicator:library:2.4.1.1@aar'
@ -48,16 +49,17 @@ dependencies {
implementation 'com.github.AndroidDeveloperLB:AutoFitTextView:4'
// https://github.com/hotchemi/PermissionsDispatcher
implementation 'com.github.hotchemi:permissionsdispatcher:3.0.1'
kapt 'com.github.hotchemi:permissionsdispatcher-processor:3.0.1'
implementation "org.jetbrains.kotlin:kotlin-stdlib-jre7:$kotlin_version"
// Version 4.x does not work.
implementation 'com.github.hotchemi:permissionsdispatcher:3.3.1'
kapt 'com.github.hotchemi:permissionsdispatcher-processor:3.3.1'
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version"
// https://github.com/eggheadgames/android-about-box
implementation 'com.github.eggheadgames:android-about-box:1.3.1'
implementation 'com.github.eggheadgames:android-about-box:1.3.2'
//implementation(name: 'library-debug', ext: 'aar')
//implementation 'com.github.daniel-stoneuk:material-about-library:2.2.1'
implementation 'com.android.support:animated-vector-drawable:26.1.0'
implementation 'com.android.support:cardview-v7:26.1.0'
implementation 'com.android.support:animated-vector-drawable:27.1.1'
implementation 'com.android.support:cardview-v7:27.1.1'
// https://github.com/ACRA/acra
implementation 'ch.acra:acra:4.9.2'

View file

@ -26,13 +26,11 @@ import android.content.Intent
import android.graphics.Typeface
import android.os.Build
import android.os.Bundle
import android.support.design.widget.TextInputEditText
import android.support.v7.app.AppCompatActivity
import android.text.*
import android.util.TypedValue
import android.view.Menu
import android.view.MenuItem
import android.view.ViewManager
import android.view.inputmethod.EditorInfo
import android.view.inputmethod.InputMethodManager
import android.widget.AdapterView
@ -48,7 +46,7 @@ import net.thauvin.erik.android.tesremoteprogrammer.util.Dtmf
import net.thauvin.erik.android.tesremoteprogrammer.util.isDKS
import net.thauvin.erik.android.tesremoteprogrammer.util.isDigits
import org.jetbrains.anko.*
import org.jetbrains.anko.custom.ankoView
import org.jetbrains.anko.design.textInputEditText
import org.jetbrains.anko.design.textInputLayout
import permissions.dispatcher.NeedsPermission
import permissions.dispatcher.RuntimePermissions
@ -80,8 +78,6 @@ class MainActivity : AppCompatActivity(), AnkoLogger {
val QUOTE = "'"
}
inline fun ViewManager.textInputEditText(theme: Int = 0, init: TextInputEditText.() -> Unit) = ankoView(::TextInputEditText, theme, init)
fun fromHtml(s: String): Spanned {
if (Build.VERSION.SDK_INT >= 24) {
return Html.fromHtml(s, Html.FROM_HTML_MODE_LEGACY)
@ -219,7 +215,6 @@ class MainActivity : AppCompatActivity(), AnkoLogger {
textInputLayout {
horizontalPadding = dip(40)
val editText = textInputEditText {
lparams(width = matchParent)
inputType = InputType.TYPE_CLASS_PHONE
hint = getString(R.string.hint_phone_number)
@ -242,7 +237,6 @@ class MainActivity : AppCompatActivity(), AnkoLogger {
textInputLayout {
horizontalPadding = dip(40)
val editText = textInputEditText {
lparams(width = matchParent)
inputType = InputType.TYPE_CLASS_NUMBER or InputType.TYPE_NUMBER_VARIATION_PASSWORD
hint = getString(R.string.hint_master_code)
filters = arrayOf(InputFilter.LengthFilter(size))
@ -280,7 +274,7 @@ class MainActivity : AppCompatActivity(), AnkoLogger {
text = getString(R.string.programming_heading)
setTextSize(TypedValue.COMPLEX_UNIT_DIP, 18f)
typeface = Typeface.DEFAULT_BOLD
}.lparams(width = matchParent)
}
// options list
listView {
@ -301,7 +295,7 @@ class MainActivity : AppCompatActivity(), AnkoLogger {
"net.thauvin.erik.android.tesremoteprogrammer.models.Option" to opts[position])
}
}
}.lparams(width = matchParent)
}
}
}
}

View file

@ -50,6 +50,7 @@ import org.jetbrains.anko.*
import org.jetbrains.anko.custom.ankoView
import org.jetbrains.anko.design.coordinatorLayout
import org.jetbrains.anko.design.floatingActionButton
import org.jetbrains.anko.design.textInputEditText
import org.jetbrains.anko.design.textInputLayout
import org.jetbrains.anko.support.v4.nestedScrollView
import permissions.dispatcher.NeedsPermission
@ -61,7 +62,6 @@ class ProgrammingActivity : AppCompatActivity(), AnkoLogger {
val empty = ""
inline fun ViewManager.autofitTextView(theme: Int = 0, init: AutoResizeTextView.() -> Unit) = ankoView(::AutoResizeTextView, theme, init)
inline fun ViewManager.textInputEditText(theme: Int = 0, init: TextInputEditText.() -> Unit) = ankoView(::TextInputEditText, theme, init)
override fun onCreate(savedInstanceState: Bundle?) {
super.onCreate(savedInstanceState)

View file

@ -23,6 +23,7 @@
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="20dp"
android:labelFor="@android:id/input"
android:text="@string/crash_dialog_comment_prompt" />
<EditText

View file

@ -1,13 +1,14 @@
// Top-level build file where you can add configuration options common to all sub-projects/modules.
buildscript {
ext.kotlin_version = '1.1.51'
ext.kotlin_version = '1.3.0'
ext.anko_version = '0.10.7'
repositories {
jcenter()
google()
}
dependencies {
classpath 'com.android.tools.build:gradle:3.0.0'
classpath 'com.android.tools.build:gradle:3.2.1'
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
// NOTE: Do not place your application dependencies here; they belong

View file

@ -1,6 +1,6 @@
#Thu Oct 26 20:39:44 PDT 2017
#Sun Nov 04 14:30:01 PST 2018
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-4.1-all.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-4.6-all.zip