summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--res/layout/on_screen_menu.xml3
-rw-r--r--res/layout/on_screen_menu_header.xml2
-rw-r--r--src/com/android/camera/OnScreenSettings.java9
3 files changed, 8 insertions, 6 deletions
diff --git a/res/layout/on_screen_menu.xml b/res/layout/on_screen_menu.xml
index 0aa4d48..3ae6b7a 100644
--- a/res/layout/on_screen_menu.xml
+++ b/res/layout/on_screen_menu.xml
@@ -20,15 +20,14 @@
android:layout_width="fill_parent"
android:layout_height="wrap_content">
<FrameLayout android:layout_width="fill_parent"
+ android:background="@android:color/black"
android:layout_height="fill_parent"
android:layout_toLeftOf="@+id/btn_gripper">
<ListView android:id="@+id/menu_view"
- android:cacheColorHint="#00000000"
android:layout_width="fill_parent"
android:layout_height="fill_parent" />
<ListView android:id="@+id/sub_menu"
android:visibility="invisible"
- android:cacheColorHint="#00000000"
android:layout_width="fill_parent"
android:layout_height="fill_parent" />
</FrameLayout>
diff --git a/res/layout/on_screen_menu_header.xml b/res/layout/on_screen_menu_header.xml
index d960419..f16f30e 100644
--- a/res/layout/on_screen_menu_header.xml
+++ b/res/layout/on_screen_menu_header.xml
@@ -15,7 +15,7 @@
-->
<TextView xmlns:android="http://schemas.android.com/apk/res/android"
android:id="@+id/title"
- android:background="#88111111"
+ android:background="#222"
android:paddingLeft="5dp"
android:paddingRight="5dp"
android:layout_width="fill_parent"
diff --git a/src/com/android/camera/OnScreenSettings.java b/src/com/android/camera/OnScreenSettings.java
index a152748..ffd309d 100644
--- a/src/com/android/camera/OnScreenSettings.java
+++ b/src/com/android/camera/OnScreenSettings.java
@@ -309,6 +309,11 @@ public class OnScreenSettings {
? ((ListPreference) preference).getEntry()
: override);
summary.setEnabled(override == null);
+
+ // A little trick here, making the view focusable will eat
+ // both touch/key events on the view and thus make it looks
+ // like disabled.
+ convertView.setFocusable(override != null);
}
return convertView;
}
@@ -321,9 +326,7 @@ public class OnScreenSettings {
@Override
public boolean isEnabled(int position) {
Preference preference = mPreferences.get(position);
- if (preference instanceof PreferenceGroup) return false;
-
- return mOverride.get(preference.getKey()) == null;
+ return !(preference instanceof PreferenceGroup);
}
public int getCount() {