aboutsummaryrefslogtreecommitdiffstats
path: root/src/org/connectbot/HostListActivity.java
diff options
context:
space:
mode:
authorKenny Root <kenny@the-b.org>2009-06-10 16:47:05 +0000
committerKenny Root <kenny@the-b.org>2009-06-10 16:47:05 +0000
commit58032b289fd6dddb8fcea4cceaf4ed7e29d7c9e8 (patch)
tree3acbe15f10487958e96c97b2931428f944e805d6 /src/org/connectbot/HostListActivity.java
parentc2646e8120c71d6bb0695da070547a193c485cb6 (diff)
downloadconnectbot-58032b289fd6dddb8fcea4cceaf4ed7e29d7c9e8.tar.gz
connectbot-58032b289fd6dddb8fcea4cceaf4ed7e29d7c9e8.tar.bz2
connectbot-58032b289fd6dddb8fcea4cceaf4ed7e29d7c9e8.zip
Reverted to r278; individual states are modified
git-svn-id: https://connectbot.googlecode.com/svn/trunk/connectbot@280 df292f66-193f-0410-a5fc-6d59da041ff2
Diffstat (limited to 'src/org/connectbot/HostListActivity.java')
-rw-r--r--src/org/connectbot/HostListActivity.java16
1 files changed, 5 insertions, 11 deletions
diff --git a/src/org/connectbot/HostListActivity.java b/src/org/connectbot/HostListActivity.java
index 7f36eb7..571780d 100644
--- a/src/org/connectbot/HostListActivity.java
+++ b/src/org/connectbot/HostListActivity.java
@@ -342,8 +342,10 @@ public class HostListActivity extends ListActivity {
help.setIntent(new Intent(HostListActivity.this, HelpActivity.class));
return true;
+
}
+
@Override
public void onCreateContextMenu(ContextMenu menu, View v, ContextMenu.ContextMenuInfo menuInfo) {
@@ -440,10 +442,6 @@ public class HostListActivity extends ListActivity {
public final static int STATE_UNKNOWN = 1, STATE_CONNECTED = 2, STATE_DISCONNECTED = 3;
- private final int[] stateChecked;
- private final int[] stateExpanded;
- private final int[] stateNone;
-
class ViewHolder {
public TextView nickname;
public TextView caption;
@@ -459,10 +457,6 @@ public class HostListActivity extends ListActivity {
red = context.getResources().getColorStateList(R.color.red);
green = context.getResources().getColorStateList(R.color.green);
blue = context.getResources().getColorStateList(R.color.blue);
-
- stateNone = new int[] { };
- stateChecked = new int[] { android.R.attr.state_checked };
- stateExpanded = new int[] { android.R.attr.state_expanded };
}
/**
@@ -513,13 +507,13 @@ public class HostListActivity extends ListActivity {
switch (this.getConnectedState(host)) {
case STATE_UNKNOWN:
- holder.icon.setImageState(stateNone, true);
+ holder.icon.setImageState(new int[] { }, true);
break;
case STATE_CONNECTED:
- holder.icon.setImageState(stateChecked, true);
+ holder.icon.setImageState(new int[] { android.R.attr.state_checked }, true);
break;
case STATE_DISCONNECTED:
- holder.icon.setImageState(stateExpanded, true);
+ holder.icon.setImageState(new int[] { android.R.attr.state_expanded }, true);
break;
}