diff options
author | Kyle Horimoto <khorimoto@gmail.com> | 2015-10-08 18:11:20 -0700 |
---|---|---|
committer | Kyle Horimoto <khorimoto@gmail.com> | 2015-10-08 18:11:20 -0700 |
commit | 9613c9a53173162744cc0225af8cb2f49f7ad156 (patch) | |
tree | 6f42eba3f39af08270a86d401c407c0b0746dc89 /app | |
parent | b4959c33480dd2f85323f26cf6db474a79fd6864 (diff) | |
download | connectbot-9613c9a53173162744cc0225af8cb2f49f7ad156.tar.gz connectbot-9613c9a53173162744cc0225af8cb2f49f7ad156.tar.bz2 connectbot-9613c9a53173162744cc0225af8cb2f49f7ad156.zip |
Lint fixes.
Diffstat (limited to 'app')
-rw-r--r-- | app/src/main/java/org/connectbot/EditHostActivity.java | 14 | ||||
-rw-r--r-- | app/src/main/res/menu/edit_host_activity_add_menu.xml | 6 | ||||
-rw-r--r-- | app/src/main/res/menu/edit_host_activity_edit_menu.xml | 6 |
3 files changed, 13 insertions, 13 deletions
diff --git a/app/src/main/java/org/connectbot/EditHostActivity.java b/app/src/main/java/org/connectbot/EditHostActivity.java index 4fcf64c..f61924f 100644 --- a/app/src/main/java/org/connectbot/EditHostActivity.java +++ b/app/src/main/java/org/connectbot/EditHostActivity.java @@ -19,10 +19,7 @@ package org.connectbot; import java.nio.charset.Charset; import java.util.ArrayList; -import java.util.Arrays; import java.util.HashMap; -import java.util.LinkedList; -import java.util.List; import java.util.Map; import android.content.ComponentName; @@ -32,7 +29,6 @@ import android.content.ServiceConnection; import android.content.res.TypedArray; import android.os.AsyncTask; import android.os.IBinder; -import android.support.annotation.Nullable; import android.support.v4.app.FragmentManager; import android.support.v7.app.AppCompatActivity; import android.os.Bundle; @@ -124,6 +120,9 @@ public class EditHostActivity extends AppCompatActivity implements HostEditorFra getSupportFragmentManager().beginTransaction() .add(R.id.fragment_container, fragment).commit(); } + + defaultPubkeyNames.recycle(); + defaultPubkeyValues.recycle(); } @Override @@ -173,7 +172,7 @@ public class EditHostActivity extends AppCompatActivity implements HostEditorFra } else { // If CharsetHolder is uninitialized, initialize it in an AsyncTask. This is necessary // because Charset must touch the disk, which cannot be performed on the UI thread. - new AsyncTask<Void, Void, Void>() { + AsyncTask<Void, Void, Void> charsetTask = new AsyncTask<Void, Void, Void>() { @Override protected Void doInBackground(Void... unused) { @@ -185,7 +184,8 @@ public class EditHostActivity extends AppCompatActivity implements HostEditorFra protected void onPostExecute(Void unused) { fragment.setCharsetData(CharsetHolder.getCharsetData()); } - }.execute(); + }; + charsetTask.execute(); } } @@ -219,7 +219,7 @@ public class EditHostActivity extends AppCompatActivity implements HostEditorFra private static Map<String, String> mData; public static Map<String, String> getCharsetData() { - if (mData== null) + if (mData == null) initialize(); return mData; diff --git a/app/src/main/res/menu/edit_host_activity_add_menu.xml b/app/src/main/res/menu/edit_host_activity_add_menu.xml index b433a09..e793cf4 100644 --- a/app/src/main/res/menu/edit_host_activity_add_menu.xml +++ b/app/src/main/res/menu/edit_host_activity_add_menu.xml @@ -18,13 +18,13 @@ <menu xmlns:android="http://schemas.android.com/apk/res/android" - xmlns:yourapp="http://schemas.android.com/apk/res-auto" + xmlns:connectbot="http://schemas.android.com/apk/res-auto" > <item android:id="@+id/save" android:icon="@drawable/ic_add" android:title="@string/hostpref_add_host" - yourapp:showAsAction="always|withText" + connectbot:showAsAction="always|withText" /> -</menu>
\ No newline at end of file +</menu> diff --git a/app/src/main/res/menu/edit_host_activity_edit_menu.xml b/app/src/main/res/menu/edit_host_activity_edit_menu.xml index ef9073c..564e211 100644 --- a/app/src/main/res/menu/edit_host_activity_edit_menu.xml +++ b/app/src/main/res/menu/edit_host_activity_edit_menu.xml @@ -18,13 +18,13 @@ <menu xmlns:android="http://schemas.android.com/apk/res/android" - xmlns:yourapp="http://schemas.android.com/apk/res-auto" + xmlns:connectbot="http://schemas.android.com/apk/res-auto" > <item android:id="@+id/save" android:icon="@drawable/ic_add" android:title="@string/hostpref_edit_host" - yourapp:showAsAction="always|withText" + connectbot:showAsAction="always|withText" /> -</menu>
\ No newline at end of file +</menu> |