1
0
Fork 0
mirror of https://github.com/syncthing/syncthing-android.git synced 2024-11-26 22:31:16 +00:00

Remove the rescan interval setting from the GUI

This commit is contained in:
Lode Hoste 2015-03-31 19:02:53 +02:00
parent 396a46ad12
commit 87bf40b6a1
18 changed files with 1 additions and 60 deletions

View file

@ -57,8 +57,6 @@ public class FolderSettingsFragment extends PreferenceFragment
private Preference mDirectory; private Preference mDirectory;
private EditTextPreference mRescanInterval;
private CheckBoxPreference mFolderMaster; private CheckBoxPreference mFolderMaster;
private PreferenceScreen mDevices; private PreferenceScreen mDevices;
@ -88,8 +86,6 @@ public class FolderSettingsFragment extends PreferenceFragment
mFolderId.setOnPreferenceChangeListener(this); mFolderId.setOnPreferenceChangeListener(this);
mDirectory = findPreference("directory"); mDirectory = findPreference("directory");
mDirectory.setOnPreferenceClickListener(this); mDirectory.setOnPreferenceClickListener(this);
mRescanInterval = (EditTextPreference) findPreference("rescan_interval");
mRescanInterval.setOnPreferenceChangeListener(this);
mFolderMaster = (CheckBoxPreference) findPreference("folder_master"); mFolderMaster = (CheckBoxPreference) findPreference("folder_master");
mFolderMaster.setOnPreferenceChangeListener(this); mFolderMaster.setOnPreferenceChangeListener(this);
mDevices = (PreferenceScreen) findPreference("devices"); mDevices = (PreferenceScreen) findPreference("devices");
@ -107,7 +103,7 @@ public class FolderSettingsFragment extends PreferenceFragment
mFolder = new RestApi.Folder(); mFolder = new RestApi.Folder();
mFolder.ID = ""; mFolder.ID = "";
mFolder.Path = ""; mFolder.Path = "";
mFolder.RescanIntervalS = 0; mFolder.RescanIntervalS = 259200; // Scan every 3 days (in case inotify dropped some changes)
mFolder.DeviceIds = new ArrayList<>(); mFolder.DeviceIds = new ArrayList<>();
mFolder.Versioning = new RestApi.Versioning(); mFolder.Versioning = new RestApi.Versioning();
} }
@ -157,8 +153,6 @@ public class FolderSettingsFragment extends PreferenceFragment
mFolderId.setText(mFolder.ID); mFolderId.setText(mFolder.ID);
mFolderId.setSummary(mFolder.ID); mFolderId.setSummary(mFolder.ID);
mDirectory.setSummary(mFolder.Path); mDirectory.setSummary(mFolder.Path);
mRescanInterval.setText(Integer.toString(mFolder.RescanIntervalS));
mRescanInterval.setSummary(Integer.toString(mFolder.RescanIntervalS));
mFolderMaster.setChecked(mFolder.ReadOnly); mFolderMaster.setChecked(mFolder.ReadOnly);
List<RestApi.Device> devicesList = mSyncthingService.getApi().getDevices(false); List<RestApi.Device> devicesList = mSyncthingService.getApi().getDevices(false);
for (RestApi.Device n : devicesList) { for (RestApi.Device n : devicesList) {
@ -262,16 +256,6 @@ public class FolderSettingsFragment extends PreferenceFragment
mFolder.Path = (String) o; mFolder.Path = (String) o;
folderUpdated(); folderUpdated();
return true; return true;
} else if (preference.equals(mRescanInterval)) {
try {
mFolder.RescanIntervalS = Integer.parseInt((String) o);
mRescanInterval.setSummary((String) o);
folderUpdated();
return true;
} catch (NumberFormatException e) {
Log.w(TAG, "Invalid rescan interval: "+ o);
}
return false;
} else if (preference.equals(mFolderMaster)) { } else if (preference.equals(mFolderMaster)) {
mFolder.ReadOnly = (Boolean) o; mFolder.ReadOnly = (Boolean) o;
folderUpdated(); folderUpdated();

View file

@ -52,8 +52,6 @@
<!--Setting title--> <!--Setting title-->
<string name="directory">Adresář</string> <string name="directory">Adresář</string>
<!--Setting title--> <!--Setting title-->
<string name="rescan_interval">Interval opakování skenování</string>
<!--Setting title-->
<string name="folder_master">Master adresář</string> <string name="folder_master">Master adresář</string>
<!--Setting title--> <!--Setting title-->
<string name="devices">Přístroje</string> <string name="devices">Přístroje</string>

View file

@ -52,8 +52,6 @@
<!--Setting title--> <!--Setting title-->
<string name="directory">Verzeichnis</string> <string name="directory">Verzeichnis</string>
<!--Setting title--> <!--Setting title-->
<string name="rescan_interval">Suchintervall</string>
<!--Setting title-->
<string name="folder_master">Originalverzeichnis</string> <string name="folder_master">Originalverzeichnis</string>
<!--Setting title--> <!--Setting title-->
<string name="devices">Geräte</string> <string name="devices">Geräte</string>

View file

@ -51,8 +51,6 @@
<!--Setting title--> <!--Setting title-->
<string name="directory">Directorio</string> <string name="directory">Directorio</string>
<!--Setting title--> <!--Setting title-->
<string name="rescan_interval">Intervalo de Reescanéo</string>
<!--Setting title-->
<string name="folder_master">Carpeta Maestra</string> <string name="folder_master">Carpeta Maestra</string>
<!--Setting title--> <!--Setting title-->
<string name="devices">Dispositivos</string> <string name="devices">Dispositivos</string>

View file

@ -52,8 +52,6 @@
<!--Setting title--> <!--Setting title-->
<string name="directory">Dossier</string> <string name="directory">Dossier</string>
<!--Setting title--> <!--Setting title-->
<string name="rescan_interval">Intervalle d\'analyse</string>
<!--Setting title-->
<string name="folder_master">Dossier maitre</string> <string name="folder_master">Dossier maitre</string>
<!--Setting title--> <!--Setting title-->
<string name="devices">Machines</string> <string name="devices">Machines</string>

View file

@ -50,8 +50,6 @@
<!--Setting title--> <!--Setting title-->
<string name="directory">Cartella</string> <string name="directory">Cartella</string>
<!--Setting title--> <!--Setting title-->
<string name="rescan_interval">Intervallo Scansione</string>
<!--Setting title-->
<string name="folder_master">Cartella Principale</string> <string name="folder_master">Cartella Principale</string>
<!--Setting title--> <!--Setting title-->
<string name="devices">Dispositivi</string> <string name="devices">Dispositivi</string>

View file

@ -52,8 +52,6 @@
<!--Setting title--> <!--Setting title-->
<string name="directory">ディレクトリー</string> <string name="directory">ディレクトリー</string>
<!--Setting title--> <!--Setting title-->
<string name="rescan_interval">再スキャン間隔</string>
<!--Setting title-->
<string name="folder_master">フォルダーマスター</string> <string name="folder_master">フォルダーマスター</string>
<!--Setting title--> <!--Setting title-->
<string name="devices">デバイス</string> <string name="devices">デバイス</string>

View file

@ -52,8 +52,6 @@
<!--Setting title--> <!--Setting title-->
<string name="directory">Map</string> <string name="directory">Map</string>
<!--Setting title--> <!--Setting title-->
<string name="rescan_interval">Herscanningstussenpose</string>
<!--Setting title-->
<string name="folder_master">Maphoofd</string> <string name="folder_master">Maphoofd</string>
<!--Setting title--> <!--Setting title-->
<string name="devices">Apparaten</string> <string name="devices">Apparaten</string>

View file

@ -51,8 +51,6 @@
<!--Setting title--> <!--Setting title-->
<string name="directory">Katalog</string> <string name="directory">Katalog</string>
<!--Setting title--> <!--Setting title-->
<string name="rescan_interval">Czas między skanowaniem</string>
<!--Setting title-->
<string name="folder_master">Folder nadrzędny</string> <string name="folder_master">Folder nadrzędny</string>
<!--Setting title--> <!--Setting title-->
<string name="devices">Urządzenia</string> <string name="devices">Urządzenia</string>

View file

@ -52,8 +52,6 @@
<!--Setting title--> <!--Setting title-->
<string name="directory">Pasta</string> <string name="directory">Pasta</string>
<!--Setting title--> <!--Setting title-->
<string name="rescan_interval">Intervalo entre verificações</string>
<!--Setting title-->
<string name="folder_master">Pasta Mestre</string> <string name="folder_master">Pasta Mestre</string>
<!--Setting title--> <!--Setting title-->
<string name="devices">Dispositivos</string> <string name="devices">Dispositivos</string>

View file

@ -52,8 +52,6 @@
<!--Setting title--> <!--Setting title-->
<string name="directory">Pasta</string> <string name="directory">Pasta</string>
<!--Setting title--> <!--Setting title-->
<string name="rescan_interval">Intervalo entre verificações</string>
<!--Setting title-->
<string name="folder_master">Pasta Mestre</string> <string name="folder_master">Pasta Mestre</string>
<!--Setting title--> <!--Setting title-->
<string name="devices">Dispositivos</string> <string name="devices">Dispositivos</string>

View file

@ -51,8 +51,6 @@
<!--Setting title--> <!--Setting title-->
<string name="directory">Папка</string> <string name="directory">Папка</string>
<!--Setting title--> <!--Setting title-->
<string name="rescan_interval">Интервал Сканирования</string>
<!--Setting title-->
<string name="folder_master">Главная папка</string> <string name="folder_master">Главная папка</string>
<!--Setting title--> <!--Setting title-->
<string name="devices">Устройства</string> <string name="devices">Устройства</string>

View file

@ -52,8 +52,6 @@
<!--Setting title--> <!--Setting title-->
<string name="directory">Dizin</string> <string name="directory">Dizin</string>
<!--Setting title--> <!--Setting title-->
<string name="rescan_interval">Yeniden Tarama Aralığı</string>
<!--Setting title-->
<string name="folder_master">Ana Klasör</string> <string name="folder_master">Ana Klasör</string>
<!--Setting title--> <!--Setting title-->
<string name="devices">Cihazlar</string> <string name="devices">Cihazlar</string>

View file

@ -52,8 +52,6 @@
<!--Setting title--> <!--Setting title-->
<string name="directory">目录</string> <string name="directory">目录</string>
<!--Setting title--> <!--Setting title-->
<string name="rescan_interval">扫描间隔</string>
<!--Setting title-->
<string name="folder_master">主文件夹</string> <string name="folder_master">主文件夹</string>
<!--Setting title--> <!--Setting title-->
<string name="devices">设备</string> <string name="devices">设备</string>

View file

@ -51,8 +51,6 @@
<!--Setting title--> <!--Setting title-->
<string name="directory">資料夾</string> <string name="directory">資料夾</string>
<!--Setting title--> <!--Setting title-->
<string name="rescan_interval">重新掃描間隔</string>
<!--Setting title-->
<string name="folder_master">主資料夾</string> <string name="folder_master">主資料夾</string>
<!--Setting title--> <!--Setting title-->
<string name="devices">裝置</string> <string name="devices">裝置</string>

View file

@ -89,9 +89,6 @@
<!-- Setting title --> <!-- Setting title -->
<string name="directory">Directory</string> <string name="directory">Directory</string>
<!-- Setting title -->
<string name="rescan_interval">Rescan Interval</string>
<!-- Setting title --> <!-- Setting title -->
<string name="folder_master">Folder Master</string> <string name="folder_master">Folder Master</string>

View file

@ -11,12 +11,6 @@
android:key="directory" android:key="directory"
android:title="@string/directory" /> android:title="@string/directory" />
<EditTextPreference
android:persistent="false"
android:key="rescan_interval"
android:title="@string/rescan_interval"
android:inputType="numberDecimal" />
<CheckBoxPreference <CheckBoxPreference
android:persistent="false" android:persistent="false"
android:key="folder_master" android:key="folder_master"

View file

@ -15,12 +15,6 @@
android:enabled="false" android:enabled="false"
style="?android:preferenceInformationStyle" /> style="?android:preferenceInformationStyle" />
<EditTextPreference
android:persistent="false"
android:key="rescan_interval"
android:title="@string/rescan_interval"
android:inputType="numberDecimal" />
<CheckBoxPreference <CheckBoxPreference
android:persistent="false" android:persistent="false"
android:key="folder_master" android:key="folder_master"