Skip to content

Commit

Permalink
Merge branch 'development'
Browse files Browse the repository at this point in the history
  • Loading branch information
aaronjwood committed Dec 31, 2017
2 parents 947d0c7 + 4b5d61f commit 0bc488f
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 20 deletions.
4 changes: 2 additions & 2 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@ jdk:
android:
components:
- tools
- build-tools-26.0.2
- android-26
- build-tools-27.0.2
- android-27
- extra-android-m2repository

env:
Expand Down
14 changes: 7 additions & 7 deletions app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -15,15 +15,15 @@ sonarqube {
}

android {
compileSdkVersion 26
buildToolsVersion '26.0.2'
compileSdkVersion 27
buildToolsVersion '27.0.2'
useLibrary 'org.apache.http.legacy'

defaultConfig {
minSdkVersion 14
targetSdkVersion 26
versionCode 51
versionName "2.2.1"
targetSdkVersion 27
versionCode 53
versionName "2.2.4"
applicationId "com.aaronjwood.portauthority"
setProperty("archivesBaseName", "PortAuthority-$versionName")
}
Expand Down Expand Up @@ -66,8 +66,8 @@ android {
}

dependencies {
compile 'com.android.support:support-v4:26.1.0'
compile 'com.android.support:appcompat-v7:26.1.0'
compile 'com.android.support:support-v4:27.0.2'
compile 'com.android.support:appcompat-v7:27.0.2'
compile 'jcifs:jcifs:1.3.17'
compile 'dnsjava:dnsjava:2.1.7'
//This does absolutely nothing
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,6 @@ public final class MainActivity extends AppCompatActivity implements MainAsyncRe
private ListView hostList;
private TextView internalIp;
private TextView externalIp;
private String cachedWanIp;
private TextView signalStrength;
private TextView ssid;
private TextView bssid;
Expand Down Expand Up @@ -463,14 +462,12 @@ public void run() {
return;
}


signalStrength.setText(String.format(getResources().getString(R.string.signalLink), signal, speed));
signalHandler.postDelayed(this, TIMER_INTERVAL);
}
}, 0);

getInternalIp();
getExternalIp();

String wifiSsid;
String wifiBssid;
Expand Down Expand Up @@ -593,10 +590,7 @@ private void getExternalIp() {
if (UserPreference.getFetchExternalIp(this)) {
label.setVisibility(View.VISIBLE);
ip.setVisibility(View.VISIBLE);

if (cachedWanIp == null) {
wifi.getExternalIpAddress(this);
}
wifi.getExternalIpAddress(this);
} else {
label.setVisibility(View.GONE);
ip.setVisibility(View.GONE);
Expand Down Expand Up @@ -668,7 +662,6 @@ public void onSaveInstanceState(Bundle savedState) {
adapterData.add(item);
}
savedState.putSerializable("hosts", adapterData);
savedState.putString("wanIp", cachedWanIp);
}
}

Expand All @@ -682,8 +675,6 @@ public void onSaveInstanceState(Bundle savedState) {
public void onRestoreInstanceState(Bundle savedState) {
super.onRestoreInstanceState(savedState);

cachedWanIp = savedState.getString("wanIp");
externalIp.setText(cachedWanIp);
hosts = (ArrayList<Host>) savedState.getSerializable("hosts");
if (hosts != null) {
setupHostsAdapter();
Expand Down Expand Up @@ -747,7 +738,6 @@ public void processFinish(int output) {
*/
@Override
public void processFinish(String output) {
cachedWanIp = output;
externalIp.setText(output);
}

Expand Down

0 comments on commit 0bc488f

Please sign in to comment.