3
任何想法爲什麼PreferenceScreen中有多個SwitchPreferences會產生一個問題,如果您選擇任何一個方框會導致其他方框更改?在運行4.2.2的Nexus 4上進行測試時發生此問題,但在運行4.0.4的Galaxy S3上未進行測試。感謝您提供的任何幫助。Android SwitchPreference在4.2.2中無法正常工作
<?xml version="1.0" encoding="utf-8"?>
<PreferenceCategory android:title="@string/description_photo_preference">
<SwitchPreference
android:key="use_gallery"
android:title="@string/title_use_gallery_preference"
android:summaryOff="@string/summary_dont_use_gallery_as_photo_source"
android:summaryOn="@string/summary_use_gallery_as_photo_source"
android:defaultValue="true"
/>
<SwitchPreference
android:key="use_camera"
android:title="@string/title_use_camera_preference"
android:summaryOff="@string/summary_dont_use_camera_as_photo_source"
android:summaryOn="@string/summary_use_camera_as_photo_source"
android:defaultValue="true"
/>
<SwitchPreference
android:key="show_last_vin"
android:title="@string/pref_string"
android:summaryOff="@string/pref_display__false"
android:summaryOn="@string/pref_display_true"
android:defaultValue="true"
/>
</PreferenceCategory>
<PreferenceCategory android:title="@string/description_photo_quality_settings">
<ListPreference
android:key="prefPhotoQuality"
android:entries="@array/photo_quality_settings"
android:summary="@string/pref_user_photo_quality_settings"
android:entryValues="@array/photo_quality_settings_values"
android:title="@string/description_photo_quality_settings" />
</PreferenceCategory>
可以確認我面臨這個問題上的Nexus 4.2.2 – AAP
我有我的Nexus 7上運行4.2.2 – Eric
這是HTC感覺與Android 4.0相同.3,同樣的問題。 – marczellm