From f3af9daa55aaafc63989046b549964d623bb08a2 Mon Sep 17 00:00:00 2001 From: arrase Date: Tue, 6 Dec 2016 00:52:24 +0100 Subject: [PATCH] fix: focusable --- .../android/ui/hiddenservices/adapters/OnionListAdapter.java | 1 + app/src/main/res/layout/layout_hs_list_item.xml | 4 +++- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/app/src/main/java/org/torproject/android/ui/hiddenservices/adapters/OnionListAdapter.java b/app/src/main/java/org/torproject/android/ui/hiddenservices/adapters/OnionListAdapter.java index b9f750ac..9824c773 100644 --- a/app/src/main/java/org/torproject/android/ui/hiddenservices/adapters/OnionListAdapter.java +++ b/app/src/main/java/org/torproject/android/ui/hiddenservices/adapters/OnionListAdapter.java @@ -38,6 +38,7 @@ public class OnionListAdapter extends CursorAdapter { name.setText(cursor.getString(cursor.getColumnIndex(HSContentProvider.HiddenService.NAME))); TextView domain = (TextView) view.findViewById(R.id.hs_onion); domain.setText(cursor.getString(cursor.getColumnIndex(HSContentProvider.HiddenService.DOMAIN))); + Switch enabled = (Switch) view.findViewById(R.id.hs_switch); enabled.setChecked( cursor.getInt(cursor.getColumnIndex(HSContentProvider.HiddenService.ENABLED)) == 1 diff --git a/app/src/main/res/layout/layout_hs_list_item.xml b/app/src/main/res/layout/layout_hs_list_item.xml index c8878b0e..44e60570 100644 --- a/app/src/main/res/layout/layout_hs_list_item.xml +++ b/app/src/main/res/layout/layout_hs_list_item.xml @@ -49,7 +49,9 @@ + android:layout_height="wrap_content" + android:focusable="false" + android:focusableInTouchMode="false" />