Skip to content

Commit

Permalink
Merge branch 'development'
Browse files Browse the repository at this point in the history
  • Loading branch information
aaronjwood committed Jan 6, 2021
2 parents 6b9d34c + b5e6636 commit 2e95719
Show file tree
Hide file tree
Showing 38 changed files with 646 additions and 253 deletions.
8 changes: 3 additions & 5 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,17 +3,15 @@ jdk:
- oraclejdk8
android:
components:
- tools
- build-tools-28.0.3
- android-29
- extra-android-m2repository
- build-tools-30.0.3
- android-30

env:
global:
- secure: "em+bEb3nWLV7f+Dt4y9/OH2Lpf6mscT9E52kXhSEm/PiFpTtzlx7BgHGlpsYVwsMf0e7x2AdF/yzq4c7ugoMqWmFXMthgFUKcLTXqW/IeARGz3smMXnyScRoaFElDm0Q33fxiqDlU7UVA4j1FysR5GqTU10MasJgGpoyTthRQvra0LU8zwI4IMiASfa8Tij5LclsbaTpcgB4TdXtBmbpKQAUzjvV/ZfLsYQ950C0rbVKk9T1xtc8d5BTbggwHWbMMqGn6RFvSCQioeI/Q6Daak6zDglUY+JE/1BnzlGzoba9C7TLZV4+TQkmB5kc6FtKqSXycjwJSKm3wQFYOzJrLMPqMtlmaAeTEs5yBIYtIIAiID+hbeUKvWTpoUxwUYz7s7XLikJRdxe7iBlhdy3qv+FdGOJjV9g/xeSVXISvXzcKp2sNdU+FABBBDAA2CKWrZOXuzPAh8iYxLnt649hQFAw99ylkn75+LpJgq7gRUO87Fde0Zw3vYhLIS8UH3OBtggV1yrYHuKXWUyfkiA/xcm+NSFgIXJzGvYlOZWS+uZvXeh7wJz5CF0t3m6emBoqX6JAXQ/t9SgwGX8lwbLPK3HiYBnTMEDxb6qpIiYa8E8tfudA1YNyeszG8mZtiErJf9YleagACuASwPFsLb8Bg9BNJX5X89+VrbzPbncZD9Tc="

before_install:
- yes | sdkmanager "platforms;android-27"
- yes | sdkmanager "platforms;android-30"
- echo -n | openssl s_client -connect scan.coverity.com:443 | sed -ne '/-BEGIN CERTIFICATE-/,/-END CERTIFICATE-/p' | sudo tee -a /etc/ssl/certs/ca-

addons:
Expand Down
21 changes: 10 additions & 11 deletions app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -5,25 +5,24 @@ sonarqube {
properties {
property "sonar.projectName", "Port Authority"
property "sonar.projectKey", "portauthority"
property "sonar.projectVersion", "1.0"
property "sonar.host.url", "http://192.168.1.3:9000"
property "sonar.sourceEncoding", "UTF-8"
property "sonar.sources", "."
property "sonar.exclusions", "build/**,**/*.png,**/*.psd"
property "sonar.import_unknown_files", true
property "sonar.android.lint.report", "./build/outputs/lint-results.xml"
property "sonar.android.lint.report", "./build/reports/lint-results.xml"
}
}

android {
viewBinding.enabled = true
compileSdkVersion 29
buildToolsVersion '28.0.3'
compileSdkVersion 30
buildToolsVersion '30.0.3'

defaultConfig {
minSdkVersion 14
targetSdkVersion 29
versionCode 61
versionName "2.3.3"
targetSdkVersion 30
versionCode 62
versionName "2.4.0"
applicationId "com.aaronjwood.portauthority"
setProperty("archivesBaseName", "PortAuthority-$versionName")
}
Expand Down Expand Up @@ -67,12 +66,12 @@ android {
}

dependencies {
implementation 'com.android.support:support-v4:28.0.0'
implementation 'com.android.support:appcompat-v7:28.0.0'
implementation 'androidx.legacy:legacy-support-v4:1.0.0'
implementation 'androidx.appcompat:appcompat:1.2.0'
implementation 'com.squareup.okhttp3:okhttp:3.12.9' // Anything past 3.12.x will break our Android 4 support!
implementation 'jcifs:jcifs:1.3.17'
implementation 'org.minidns:minidns-hla:0.3.2'
debugImplementation 'com.squareup.leakcanary:leakcanary-android:2.2'
testImplementation 'junit:junit:4.12'
testImplementation 'junit:junit:4.13'
testImplementation 'org.mockito:mockito-core:1.10.19'
}
Original file line number Diff line number Diff line change
@@ -1,15 +1,17 @@
package com.aaronjwood.portauthority.activity;

import android.os.AsyncTask;
import android.os.Bundle;
import android.support.annotation.NonNull;
import android.support.v7.app.AppCompatActivity;
import android.view.View;
import android.widget.Button;
import android.widget.EditText;
import android.widget.Spinner;
import android.widget.TextView;
import android.widget.Toast;

import androidx.annotation.NonNull;
import androidx.appcompat.app.AppCompatActivity;

import com.aaronjwood.portauthority.R;
import com.aaronjwood.portauthority.async.DnsLookupAsyncTask;
import com.aaronjwood.portauthority.response.DnsAsyncResponse;
Expand Down Expand Up @@ -41,7 +43,7 @@ protected void onCreate(Bundle savedInstanceState) {
}

@Override
protected void onSaveInstanceState(Bundle savedState) {
protected void onSaveInstanceState(@NonNull Bundle savedState) {
super.onSaveInstanceState(savedState);

String recordData = dnsAnswer.getText().toString();
Expand Down Expand Up @@ -92,7 +94,7 @@ public void onClick(View view) {
if (recordType != null) {
String recordName = recordType.toString();
Toast.makeText(getApplicationContext(), getResources().getString(R.string.startingDnsLookup), Toast.LENGTH_SHORT).show();
new DnsLookupAsyncTask(DnsActivity.this).execute(domain, recordName);
new DnsLookupAsyncTask(DnsActivity.this).executeOnExecutor(AsyncTask.THREAD_POOL_EXECUTOR, domain, recordName);
}
}
});
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@
import android.os.Bundle;
import android.os.Handler;
import android.os.Looper;
import android.support.v7.app.AppCompatActivity;
import android.util.SparseArray;
import android.view.View;
import android.view.animation.AnimationUtils;
Expand All @@ -20,6 +19,9 @@
import android.widget.NumberPicker;
import android.widget.Toast;

import androidx.annotation.NonNull;
import androidx.appcompat.app.AppCompatActivity;

import com.aaronjwood.portauthority.R;
import com.aaronjwood.portauthority.db.Database;
import com.aaronjwood.portauthority.listener.ScanPortsListener;
Expand Down Expand Up @@ -96,21 +98,13 @@ public void onPause() {
portRangeDialog = null;
}

/**
* Clean up
*/
@Override
protected void onDestroy() {
super.onDestroy();
}

/**
* Save the state of the activity
*
* @param savedState Data to save
*/
@Override
public void onSaveInstanceState(Bundle savedState) {
public void onSaveInstanceState(@NonNull Bundle savedState) {
super.onSaveInstanceState(savedState);

String[] savedList = ports.toArray(new String[0]);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@
import android.widget.TextView;
import android.widget.Toast;

import androidx.annotation.NonNull;

import com.aaronjwood.portauthority.R;
import com.aaronjwood.portauthority.listener.ScanPortsListener;
import com.aaronjwood.portauthority.network.Host;
Expand Down Expand Up @@ -61,7 +63,7 @@ protected void onCreate(Bundle savedInstanceState) {
* @param savedState Data to save
*/
@Override
public void onSaveInstanceState(Bundle savedState) {
public void onSaveInstanceState(@NonNull Bundle savedState) {
super.onSaveInstanceState(savedState);

savedState.putSerializable("host", host);
Expand Down
Loading

0 comments on commit 2e95719

Please sign in to comment.