Skip to content

Commit

Permalink
Persistent=false should be repeated for all subpreferences, a global …
Browse files Browse the repository at this point in the history
…persistent flag would have been too easy... (fixes #256)
  • Loading branch information
Zillode committed Mar 20, 2015
1 parent 7b54ce5 commit 2b9a79b
Show file tree
Hide file tree
Showing 4 changed files with 30 additions and 8 deletions.
8 changes: 6 additions & 2 deletions src/main/res/xml/device_settings_create.xml
Original file line number Diff line number Diff line change
@@ -1,27 +1,31 @@
<?xml version="1.0" encoding="utf-8"?>
<PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android"
android:persistent="false">
<PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">

<EditTextPreference
android:persistent="false"
android:key="device_id"
android:title="@string/device_id"
android:widgetLayout="@layout/scan_qr_code_widget" />

<EditTextPreference
android:persistent="false"
android:key="name"
android:title="@string/name" />

<EditTextPreference
android:persistent="false"
android:key="addresses"
android:title="@string/addresses" />

<ListPreference
android:persistent="false"
android:key="compression"
android:entries="@array/compress_entries"
android:entryValues="@array/compress_values"
android:title="@string/compression" />

<CheckBoxPreference
android:persistent="false"
android:key="introducer"
android:title="@string/introducer" />

Expand Down
10 changes: 8 additions & 2 deletions src/main/res/xml/device_settings_edit.xml
Original file line number Diff line number Diff line change
@@ -1,35 +1,41 @@
<?xml version="1.0" encoding="utf-8"?>
<PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android"
android:persistent="false">
<PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">

<Preference
android:persistent="false"
android:key="device_id"
android:title="@string/device_id" />

<EditTextPreference
android:persistent="false"
android:key="name"
android:title="@string/name" />

<EditTextPreference
android:persistent="false"
android:key="addresses"
android:title="@string/addresses" />

<ListPreference
android:persistent="false"
android:key="compression"
android:entries="@array/compress_entries"
android:entryValues="@array/compress_values"
android:title="@string/compression" />

<CheckBoxPreference
android:persistent="false"
android:key="introducer"
android:title="@string/introducer" />

<Preference
android:persistent="false"
android:key="version"
android:title="@string/syncthing_version_title"
style="?android:preferenceInformationStyle" />

<Preference
android:persistent="false"
android:key="current_address"
android:title="@string/current_address"
style="?android:preferenceInformationStyle" />
Expand Down
10 changes: 8 additions & 2 deletions src/main/res/xml/folder_settings_create.xml
Original file line number Diff line number Diff line change
@@ -1,33 +1,39 @@
<?xml version="1.0" encoding="utf-8"?>
<PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android"
android:persistent="false">
<PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">

<EditTextPreference
android:persistent="false"
android:key="folder_id"
android:title="@string/folder_id" />

<Preference
android:persistent="false"
android:key="directory"
android:title="@string/directory" />

<EditTextPreference
android:persistent="false"
android:key="rescan_interval"
android:title="@string/rescan_interval"
android:inputType="numberDecimal" />

<CheckBoxPreference
android:persistent="false"
android:key="folder_master"
android:title="@string/folder_master" />

<PreferenceScreen
android:persistent="false"
android:key="devices"
android:title="@string/devices" />

<CheckBoxPreference
android:persistent="false"
android:key="versioning"
android:title="@string/file_versioning" />

<EditTextPreference
android:persistent="false"
android:key="versioning_keep"
android:title="@string/keep_versions"
android:inputType="numberDecimal" />
Expand Down
10 changes: 8 additions & 2 deletions src/main/res/xml/folder_settings_edit.xml
Original file line number Diff line number Diff line change
@@ -1,37 +1,43 @@
<?xml version="1.0" encoding="utf-8"?>
<PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android"
android:persistent="false">
<PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">

<EditTextPreference
android:persistent="false"
android:key="folder_id"
android:title="@string/folder_id"
android:enabled="false"
style="?android:preferenceInformationStyle" />

<Preference
android:persistent="false"
android:key="directory"
android:title="@string/directory"
android:enabled="false"
style="?android:preferenceInformationStyle" />

<EditTextPreference
android:persistent="false"
android:key="rescan_interval"
android:title="@string/rescan_interval"
android:inputType="numberDecimal" />

<CheckBoxPreference
android:persistent="false"
android:key="folder_master"
android:title="@string/folder_master" />

<PreferenceScreen
android:persistent="false"
android:key="devices"
android:title="@string/devices" />

<CheckBoxPreference
android:persistent="false"
android:key="versioning"
android:title="File Versioning" />

<EditTextPreference
android:persistent="false"
android:key="versioning_keep"
android:title="@string/keep_versions"
android:inputType="numberDecimal" />
Expand Down

4 comments on commit 2b9a79b

@SteffenTux
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

After patching app doesn't start at all.

@Zillode
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you provide a logcat?

@SteffenTux
Copy link

@SteffenTux SteffenTux commented on 2b9a79b Mar 20, 2015 via email

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Nutomic
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

See here.

Please sign in to comment.