1
0
Fork 0
mirror of https://github.com/syncthing/syncthing-android.git synced 2024-11-29 15:51:17 +00:00

Add "receiveonly" folder type to UI and model (fixes #1210) (#1211)

This commit is contained in:
Catfriend1 2018-08-07 14:14:21 +02:00 committed by Audrius Butkevicius
parent 6a04d640bd
commit 4b7024bf8a
30 changed files with 263 additions and 65 deletions

View file

@ -125,6 +125,14 @@
<action android:name="com.nutomic.syncthingandroid.action.STOP" />
</intent-filter>
</receiver>
<activity android:name=".activities.FolderTypeDialogActivity"
android:label="@string/folder_type"
android:theme="@style/Theme.Syncthing.Dialog"
android:parentActivityName=".activities.FolderActivity">
<meta-data
android:name="android.support.PARENT_ACTIVITY"
android:value="com.nutomic.syncthingandroid.activities.FolderActivity" />
</activity>
<activity android:name=".activities.PullOrderDialogActivity"
android:label="@string/pull_order"
android:theme="@style/Theme.Syncthing.Dialog"

View file

@ -77,6 +77,7 @@ public class FolderActivity extends SyncthingActivity
private static final int FILE_VERSIONING_DIALOG_REQUEST = 3454;
private static final int PULL_ORDER_DIALOG_REQUEST = 3455;
private static final int FOLDER_TYPE_DIALOG_REQUEST =3456;
private static final int CHOOSE_FOLDER_REQUEST = 3459;
private static final String FOLDER_MARKER_NAME = ".stfolder";
@ -85,12 +86,15 @@ public class FolderActivity extends SyncthingActivity
private Folder mFolder;
// Contains SAF readwrite access URI on API level >= Build.VERSION_CODES.LOLLIPOP (21)
private Uri mFolderUri = null;
// Indicates the result of the write test to mFolder.path on dialog init or after a path change.
Boolean mCanWriteToPath = false;
private EditText mLabelView;
private EditText mIdView;
private TextView mPathView;
private TextView mAccessExplanationView;
private SwitchCompat mFolderMasterView;
private TextView mFolderTypeView;
private TextView mFolderTypeDescriptionView;
private SwitchCompat mFolderFileWatcher;
private SwitchCompat mFolderPaused;
private ViewGroup mDevicesContainer;
@ -123,10 +127,6 @@ public class FolderActivity extends SyncthingActivity
@Override
public void onCheckedChanged(CompoundButton view, boolean isChecked) {
switch (view.getId()) {
case R.id.master:
mFolder.type = (isChecked) ? Constants.FOLDER_TYPE_SEND_ONLY : Constants.FOLDER_TYPE_SEND_RECEIVE;
mFolderNeedsToUpdate = true;
break;
case R.id.fileWatcher:
mFolder.fsWatcherEnabled = isChecked;
mFolderNeedsToUpdate = true;
@ -161,7 +161,8 @@ public class FolderActivity extends SyncthingActivity
mIdView = findViewById(R.id.id);
mPathView = findViewById(R.id.directoryTextView);
mAccessExplanationView = findViewById(R.id.accessExplanationView);
mFolderMasterView = findViewById(R.id.master);
mFolderTypeView = findViewById(R.id.folderType);
mFolderTypeDescriptionView = findViewById(R.id.folderTypeDescription);
mFolderFileWatcher = findViewById(R.id.fileWatcher);
mFolderPaused = findViewById(R.id.folderPause);
mPullOrderTypeView = findViewById(R.id.pullOrderType);
@ -173,6 +174,7 @@ public class FolderActivity extends SyncthingActivity
mPathView.setOnClickListener(view -> onPathViewClick());
findViewById(R.id.folderTypeContainer).setOnClickListener(v -> showFolderTypeDialog());
findViewById(R.id.pullOrderContainer).setOnClickListener(v -> showPullOrderDialog());
findViewById(R.id.versioningContainer).setOnClickListener(v -> showVersioningDialog());
mEditIgnores.setOnClickListener(v -> editIgnores());
@ -257,6 +259,28 @@ public class FolderActivity extends SyncthingActivity
}
}
private void showFolderTypeDialog() {
if (TextUtils.isEmpty(mFolder.path)) {
Toast.makeText(this, R.string.folder_path_required, Toast.LENGTH_LONG)
.show();
return;
}
if (!mCanWriteToPath) {
/**
* Do not handle the click as the children in the folder type layout are disabled
* and an explanation is already given on the UI why the only allowed folder type
* is "sendonly".
*/
Toast.makeText(this, R.string.folder_path_readonly, Toast.LENGTH_LONG)
.show();
return;
}
// The user selected folder path is writeable, offer to choose from all available folder types.
Intent intent = new Intent(this, FolderTypeDialogActivity.class);
intent.putExtra(FolderTypeDialogActivity.EXTRA_FOLDER_TYPE, mFolder.type);
startActivityForResult(intent, FOLDER_TYPE_DIALOG_REQUEST);
}
private void showPullOrderDialog() {
Intent intent = new Intent(this, PullOrderDialogActivity.class);
intent.putExtra(PullOrderDialogActivity.EXTRA_PULL_ORDER, mFolder.order);
@ -377,16 +401,15 @@ public class FolderActivity extends SyncthingActivity
private void updateViewsAndSetListeners() {
mLabelView.removeTextChangedListener(mTextWatcher);
mIdView.removeTextChangedListener(mTextWatcher);
mFolderMasterView.setOnCheckedChangeListener(null);
mFolderFileWatcher.setOnCheckedChangeListener(null);
mFolderPaused.setOnCheckedChangeListener(null);
// Update views
mLabelView.setText(mFolder.label);
mIdView.setText(mFolder.id);
updateFolderTypeDescription();
updatePullOrderDescription();
updateVersioningDescription();
mFolderMasterView.setChecked(Objects.equal(mFolder.type, Constants.FOLDER_TYPE_SEND_ONLY));
mFolderFileWatcher.setChecked(mFolder.fsWatcherEnabled);
mFolderPaused.setChecked(mFolder.paused);
List<Device> devicesList = getApi().getDevices(false);
@ -403,7 +426,6 @@ public class FolderActivity extends SyncthingActivity
// Keep state updated
mLabelView.addTextChangedListener(mTextWatcher);
mIdView.addTextChangedListener(mTextWatcher);
mFolderMasterView.setOnCheckedChangeListener(mCheckedListener);
mFolderFileWatcher.setOnCheckedChangeListener(mCheckedListener);
mFolderPaused.setOnCheckedChangeListener(mCheckedListener);
}
@ -517,6 +539,10 @@ public class FolderActivity extends SyncthingActivity
mFolderNeedsToUpdate = true;
} else if (resultCode == Activity.RESULT_OK && requestCode == FILE_VERSIONING_DIALOG_REQUEST) {
updateVersioning(data.getExtras());
} else if (resultCode == Activity.RESULT_OK && requestCode == FOLDER_TYPE_DIALOG_REQUEST) {
mFolder.type = data.getStringExtra(FolderTypeDialogActivity.EXTRA_RESULT_FOLDER_TYPE);
updateFolderTypeDescription();
mFolderNeedsToUpdate = true;
} else if (resultCode == Activity.RESULT_OK && requestCode == PULL_ORDER_DIALOG_REQUEST) {
mFolder.order = data.getStringExtra(PullOrderDialogActivity.EXTRA_RESULT_PULL_ORDER);
updatePullOrderDescription();
@ -538,24 +564,26 @@ public class FolderActivity extends SyncthingActivity
* Access level readonly: folder can only be configured "sendonly".
* Access level readwrite: folder can be configured "sendonly" or "sendreceive".
*/
Boolean canWrite = Util.nativeBinaryCanWriteToPath(FolderActivity.this, mFolder.path);
if (canWrite) {
mCanWriteToPath = Util.nativeBinaryCanWriteToPath(FolderActivity.this, mFolder.path);
if (mCanWriteToPath) {
mAccessExplanationView.setText(R.string.folder_path_readwrite);
mFolderTypeView.setEnabled(true);
mEditIgnores.setEnabled(true);
if (mIsCreateMode) {
/**
* Suggest FOLDER_TYPE_SEND_RECEIVE folder because the user most probably
* intentionally chose a special folder like
* Suggest folder type FOLDER_TYPE_SEND_RECEIVE for folders to be created
* because the user most probably intentionally chose a special folder like
* "[storage]/Android/data/com.nutomic.syncthingandroid/files"
* or enabled root mode thus having write access.
*/
mAccessExplanationView.setText(R.string.folder_path_readwrite);
mFolderMasterView.setChecked(false);
mFolderMasterView.setEnabled(true);
mEditIgnores.setEnabled(true);
mFolder.type = Constants.FOLDER_TYPE_SEND_RECEIVE;
}
} else {
// Force "sendonly" folder.
mAccessExplanationView.setText(R.string.folder_path_readonly);
mFolderMasterView.setChecked(true);
mFolderMasterView.setEnabled(false);
mFolderTypeView.setEnabled(false);
mEditIgnores.setEnabled(false);
mFolder.type = Constants.FOLDER_TYPE_SEND_ONLY;
}
}
@ -671,6 +699,32 @@ public class FolderActivity extends SyncthingActivity
mFolderNeedsToUpdate = true;
}
private void updateFolderTypeDescription() {
if (mFolder == null) {
return;
}
switch (mFolder.type) {
case Constants.FOLDER_TYPE_SEND_RECEIVE:
setFolderTypeDescription(getString(R.string.folder_type_sendreceive),
getString(R.string.folder_type_sendreceive_description));
break;
case Constants.FOLDER_TYPE_SEND_ONLY:
setFolderTypeDescription(getString(R.string.folder_type_sendonly),
getString(R.string.folder_type_sendonly_description));
break;
case Constants.FOLDER_TYPE_RECEIVE_ONLY:
setFolderTypeDescription(getString(R.string.folder_type_receiveonly),
getString(R.string.folder_type_receiveonly_description));
break;
}
}
private void setFolderTypeDescription(String type, String description) {
mFolderTypeView.setText(type);
mFolderTypeDescriptionView.setText(description);
}
private void updatePullOrderDescription() {
if (mFolder == null) {
return;

View file

@ -0,0 +1,78 @@
package com.nutomic.syncthingandroid.activities;
import android.app.Activity;
import android.content.Intent;
import android.os.Bundle;
import android.support.v7.app.AppCompatActivity;
import android.view.View;
import android.widget.AdapterView;
import android.widget.Button;
import android.widget.Spinner;
import com.nutomic.syncthingandroid.R;
import com.nutomic.syncthingandroid.service.Constants;
import java.util.Arrays;
import java.util.List;
public class FolderTypeDialogActivity extends AppCompatActivity {
public static final String EXTRA_FOLDER_TYPE = "com.nutomic.syncthinandroid.activities.FolderTypeDialogActivity.FOLDER_TYPE";
public static final String EXTRA_RESULT_FOLDER_TYPE = "com.nutomic.syncthinandroid.activities.FolderTypeDialogActivity.EXTRA_RESULT_FOLDER_TYPE";
private String selectedType;
private static final List<String> mTypes = Arrays.asList(
Constants.FOLDER_TYPE_SEND_RECEIVE,
Constants.FOLDER_TYPE_SEND_ONLY,
Constants.FOLDER_TYPE_RECEIVE_ONLY
);
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.fragment_foldertype_dialog);
if (savedInstanceState == null) {
selectedType = getIntent().getStringExtra(EXTRA_FOLDER_TYPE);
}
initiateFinishBtn();
initiateSpinner();
}
private void initiateFinishBtn() {
Button finishBtn = findViewById(R.id.finish_btn);
finishBtn.setOnClickListener(v -> {
saveConfiguration();
finish();
});
}
private void saveConfiguration() {
Intent intent = new Intent();
intent.putExtra(EXTRA_RESULT_FOLDER_TYPE, selectedType);
setResult(Activity.RESULT_OK, intent);
}
private void initiateSpinner() {
Spinner folderTypeSpinner = findViewById(R.id.folderTypeSpinner);
folderTypeSpinner.setSelection(mTypes.indexOf(selectedType));
folderTypeSpinner.setOnItemSelectedListener(new AdapterView.OnItemSelectedListener() {
@Override
public void onItemSelected(AdapterView<?> parent, View view, int position, long id) {
if (position != mTypes.indexOf(selectedType)) {
selectedType = mTypes.get(position);
}
}
@Override
public void onNothingSelected(AdapterView<?> parent) {
// This is not allowed.
}
});
}
@Override
public void onBackPressed() {
saveConfiguration();
super.onBackPressed();
}
}

View file

@ -2,6 +2,8 @@ package com.nutomic.syncthingandroid.model;
import android.text.TextUtils;
import com.nutomic.syncthingandroid.service.Constants;
import java.io.Serializable;
import java.util.ArrayList;
import java.util.HashMap;
@ -15,7 +17,7 @@ public class Folder {
public String label;
public String filesystemType = "basic";
public String path;
public String type;
public String type = Constants.FOLDER_TYPE_SEND_RECEIVE;
public boolean fsWatcherEnabled = true;
public int fsWatcherDelayS = 10;
private List<Device> devices = new ArrayList<>();

View file

@ -44,8 +44,7 @@ public class Constants {
*/
public static final String FOLDER_TYPE_SEND_ONLY = "sendonly";
public static final String FOLDER_TYPE_SEND_RECEIVE = "sendreceive";
// public static final String FOLDER_TYPE_RECEIVE_ONLY = "receiveonly"
public static final String FOLDER_TYPE_RECEIVE_ONLY = "receiveonly";
/**
* On Android 8.1, ACCESS_COARSE_LOCATION is required to access WiFi SSID.

View file

@ -70,15 +70,41 @@
</LinearLayout>
<android.support.v7.widget.SwitchCompat
android:id="@+id/master"
style="@style/Widget.Syncthing.TextView.Label.Details"
<LinearLayout
android:id="@+id/folderTypeContainer"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:background="?selectableItemBackground"
android:orientation="vertical"
android:gravity="center_vertical">
<TextView
style="@style/Widget.Syncthing.TextView.Label.Details"
android:layout_width="match_parent"
android:layout_height="0dp"
android:layout_weight="1"
android:background="@null"
android:checked="false"
android:drawableLeft="@drawable/ic_lock_black_24dp_active"
android:drawableStart="@drawable/ic_lock_black_24dp_active"
android:text="@string/folder_master" />
android:text="@string/folder_type" />
<TextView
android:id="@+id/folderType"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginLeft="75dp"
android:layout_marginStart="75dp"
android:layout_marginTop="-20dp"
android:textAppearance="@style/TextAppearance.AppCompat.Caption" />
<TextView
android:id="@+id/folderTypeDescription"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginLeft="75dp"
android:layout_marginStart="75dp"
android:textAppearance="@style/TextAppearance.AppCompat.Caption" />
<TextView
android:id="@+id/accessExplanationView"
@ -86,9 +112,9 @@
android:layout_height="wrap_content"
android:layout_marginLeft="75dp"
android:layout_marginStart="75dp"
android:layout_marginTop="-20dp"
android:textAppearance="@style/TextAppearance.AppCompat.Caption"
android:focusable="false"/>
android:textAppearance="@style/TextAppearance.AppCompat.Caption" />
</LinearLayout>
<android.support.v7.widget.SwitchCompat
android:id="@+id/fileWatcher"

View file

@ -0,0 +1,37 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:orientation="vertical" android:layout_width="match_parent"
android:layout_height="match_parent"
android:padding="?dialogPreferredPadding"
style="@style/Theme.Syncthing.Dialog">
<Spinner
android:id="@+id/folderTypeSpinner"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:entries="@array/folder_types"
style="@style/Widget.AppCompat.Spinner.Underlined" />
<ScrollView
android:layout_width="match_parent"
android:layout_height="match_parent">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="vertical">
<Button
android:id="@+id/finish_btn"
style="@style/Widget.AppCompat.Button.ButtonBar.AlertDialog"
android:layout_width="wrap_content"
android:layout_height="50dp"
android:layout_gravity="end"
android:text="@string/finish"
android:textColor="@color/primary_dark" />
</LinearLayout>
</ScrollView>
</LinearLayout>

View file

@ -87,7 +87,6 @@ Ens podeu informar dels problemes que trobeu a través de Github.</string>
<!--Setting title-->
<string name="directory">Directori</string>
<!--Setting title-->
<string name="folder_master">Només envia</string>
<!--Setting title and description-->
<string name="folder_fileWatcher">Vigila els canvis</string>
<string name="folder_fileWatcherDescription">Demana al sistema que notifiqui dels canvis als fitxers. Si es desactiva es faran comprovacions cada hora.</string>

View file

@ -87,7 +87,6 @@ Všechny zaznamenané chyby prosím hlašte přes Github.</string>
<!--Setting title-->
<string name="directory">Adresář</string>
<!--Setting title-->
<string name="folder_master">Pouze Odesílat</string>
<!--Setting title and description-->
<!--Setting title-->
<!--Setting title-->

View file

@ -83,7 +83,6 @@ Vær venlig at rapportere ethvert problem, du støder på, via Github. </string>
<!--Setting title-->
<string name="directory">Katalog</string>
<!--Setting title-->
<string name="folder_master">Send kun</string>
<!--Setting title and description-->
<!--Setting title-->
<!--Setting title-->

View file

@ -92,7 +92,6 @@ Bitte melden Sie auftretende Probleme via GitHub.</string>
<!--Setting title-->
<string name="directory">Verzeichnis</string>
<!--Setting title-->
<string name="folder_master">Nur senden</string>
<!--Setting title and description-->
<string name="folder_fileWatcher">Auf Änderungen achten</string>
<string name="folder_fileWatcherDescription">Fordert das Betriebssystem auf, über Änderungen an Dateien zu informieren. Falls deaktiviert erfolgt stattdessen stündliches Scannen.</string>

View file

@ -84,7 +84,6 @@
<!--Setting title-->
<string name="directory">Κατάλογος</string>
<!--Setting title-->
<string name="folder_master">Μόνο αποστολή</string>
<!--Setting title and description-->
<!--Setting title-->
<!--Setting title-->

View file

@ -76,7 +76,6 @@
<!--Setting title-->
<string name="directory">Directorio</string>
<!--Setting title-->
<string name="folder_master">Solamente enviar</string>
<!--Setting title and description-->
<!--Setting title-->
<!--Setting title-->

View file

@ -87,7 +87,6 @@ Ilmoitathan ystävällisesti kaikista havaitsemistasi ongelmista Githubin kautta
<!--Setting title-->
<string name="directory">Hakemisto</string>
<!--Setting title-->
<string name="folder_master">Vain lähetys</string>
<!--Setting title and description-->
<!--Setting title-->
<!--Setting title-->

View file

@ -88,7 +88,6 @@ S\'il vous plaît, soumettez les problèmes que vous rencontrez via Github.</str
<!--Setting title-->
<string name="directory">Répertoire</string>
<!--Setting title-->
<string name="folder_master">Envoyer uniquement</string>
<!--Setting title and description-->
<string name="folder_fileWatcher">Surveiller les changements</string>
<string name="folder_fileWatcherDescription">Demande au système d\'exploitation de signaler les modifications apportées aux fichiers. Si désactivé, revient aux analyses horaires périodiques.</string>

View file

@ -93,7 +93,6 @@ Néhány eszközön extra alkalmazás-leállító alkalmazást telepített fel a
<!--Setting title-->
<string name="directory">Mappa</string>
<!--Setting title-->
<string name="folder_master">Csak küldés</string>
<!--Setting title and description-->
<string name="folder_fileWatcher">Figyeli a változásokat</string>
<string name="folder_fileWatcherDescription">Megkéri az operációs rendszert, hogy értesítsen a fájlok módosításairól. Kikapcsolt állapotban, visszatér az időszakos óránkénti ellenőrzésekhez.</string>

View file

@ -81,7 +81,6 @@ Jika ada masalah silakan laporkan lewat Github.</string>
<!--Setting title-->
<string name="directory">Direktori</string>
<!--Setting title-->
<string name="folder_master">Kirim Saja</string>
<!--Setting title and description-->
<!--Setting title-->
<!--Setting title-->

View file

@ -88,7 +88,6 @@ Si prega di segnalare eventuali problemi che si incontrano via Github.</string>
<!--Setting title-->
<string name="directory">Cartella</string>
<!--Setting title-->
<string name="folder_master">Invia Soltanto</string>
<!--Setting title and description-->
<string name="folder_fileWatcher">Monitorare i cambiamenti</string>
<string name="folder_fileWatcherDescription">Chiede al sistema operativo di notificare le modifiche ai file. Se disabilitato, ritorna a scansioni orarie periodiche.</string>

View file

@ -84,7 +84,6 @@
<!--Setting title-->
<string name="directory">ディレクトリー</string>
<!--Setting title-->
<string name="folder_master">送信のみ</string>
<!--Setting title and description-->
<!--Setting title-->
<!--Setting title-->

View file

@ -83,7 +83,6 @@
<!--Setting title-->
<string name="directory">디렉토리</string>
<!--Setting title-->
<string name="folder_master">송신 전용</string>
<!--Setting title and description-->
<!--Setting title-->
<!--Setting title-->

View file

@ -88,7 +88,6 @@ Als je problemen tegenkomt, meld ze dan via GitHub.</string>
<!--Setting title-->
<string name="directory">Map</string>
<!--Setting title-->
<string name="folder_master">Enkel versturen</string>
<!--Setting title and description-->
<string name="folder_fileWatcher">Controleren op wijzigingen</string>
<string name="folder_fileWatcherDescription">Vraagt het besturingssysteem om meldingen over gewijzigde bestanden. Indien uitgeschakeld wordt elk uur gescand.</string>

View file

@ -87,7 +87,6 @@ Proszę zgłaszać napotkane błędy programu za pośrednictwem serwisu Github.<
<!--Setting title-->
<string name="directory">Katalog</string>
<!--Setting title-->
<string name="folder_master">Tylko wyślij</string>
<!--Setting title and description-->
<!--Setting title-->
<!--Setting title-->

View file

@ -88,7 +88,6 @@ Por favor, nos avise sobre quaisquer problemas que você encontrar via Github.</
<!--Setting title-->
<string name="directory">Pasta</string>
<!--Setting title-->
<string name="folder_master">Somente envio</string>
<!--Setting title and description-->
<string name="folder_fileWatcher">observe as mudanças</string>
<string name="folder_fileWatcherDescription">Pede ao sistema em operação para notificar sobre mudanças em arquivos. Se desabilitado cai para uma varredura periódica por hora.</string>

View file

@ -93,7 +93,6 @@ Vă rugăm să raportați orice problemă întâlniți, prin intermediul GitHub.
<!--Setting title-->
<string name="directory">Director</string>
<!--Setting title-->
<string name="folder_master">Doar trimitere</string>
<!--Setting title and description-->
<string name="folder_fileWatcher">Monitorizează schimbările</string>
<string name="folder_fileWatcherDescription">Se cere sistemului să notifice despre schimbarea fișierelor. Dacă este dezactivat se folosește scanarea o dată pe oră.</string>

View file

@ -90,7 +90,6 @@
<!--Setting title-->
<string name="directory">Папка</string>
<!--Setting title-->
<string name="folder_master">Только отправка</string>
<!--Setting title and description-->
<string name="folder_fileWatcher">Следить за изменениями</string>
<string name="folder_fileWatcherDescription">Запросить операционную систему сообщать об изменениях в файлах. Если отключено, сканирование будет происходить ежечасно.</string>

View file

@ -88,7 +88,6 @@ Vänligen rapportera eventuella problem du stöter på via Github.</string>
<!--Setting title-->
<string name="directory">Katalog</string>
<!--Setting title-->
<string name="folder_master">Skicka endast</string>
<!--Setting title and description-->
<string name="folder_fileWatcher">Håll utkik efter ändringar</string>
<string name="folder_fileWatcherDescription">Frågar operativsystemet att meddela om ändringar i filer. Om inaktiverad faller tillbaka på återkommande skanningar varje timme.</string>

View file

@ -64,7 +64,6 @@
<!--Setting title-->
<string name="directory">Каталог</string>
<!--Setting title-->
<string name="folder_master">Лише відправка</string>
<!--Setting title and description-->
<!--Setting title-->
<!--Setting title-->

View file

@ -86,7 +86,6 @@
<!--Setting title-->
<string name="directory">目录</string>
<!--Setting title-->
<string name="folder_master">仅发送</string>
<!--Setting title and description-->
<!--Setting title-->
<!--Setting title-->

View file

@ -83,7 +83,6 @@
<!--Setting title-->
<string name="directory">資料夾</string>
<!--Setting title-->
<string name="folder_master">僅傳送</string>
<!--Setting title and description-->
<!--Setting title-->
<!--Setting title-->

View file

@ -169,9 +169,6 @@ Please report any problems you encounter via Github.</string>
<!-- Setting title -->
<string name="directory">Directory</string>
<!-- Setting title -->
<string name="folder_master">Send Only</string>
<!-- Setting title and description -->
<string name="folder_fileWatcher">Watch for changes</string>
<string name="folder_fileWatcherDescription">Asks operating system to notify about changes to files. If disabled falls back to periodic hourly scans.</string>
@ -373,6 +370,12 @@ Please report any problems you encounter via Github.</string>
<string name="pref_language_default">Default Language</string>
<string-array name="folder_types">
<item>Send &amp; Receive</item>
<item>Send Only</item>
<item>Receive Only</item>
</string-array>
<string-array name="pull_order_types">
<item>Random</item>
<item>Alphabetic</item>
@ -712,6 +715,19 @@ Please report any problems you encounter via Github.</string>
<string name="appconfig_receiver_background_enabled">Stopping Syncthing is not supported when running in background is enabled.</string>
<!-- Titles used in the folder type dialog and folder type button in the folder activity -->
<string name="folder_type">Folder Type</string>
<!-- Displays the current folder type in the folder activity -->
<string name="folder_type_sendreceive">Send &amp; Receive</string>
<string name="folder_type_sendonly">Send Only</string>
<string name="folder_type_receiveonly">Receive Only</string>
<!-- Folder type dialog descriptions for folder types -->
<string name="folder_type_sendreceive_description">The folder will both send changes to and receive changes from remote devices.</string>
<string name="folder_type_sendonly_description">Files are protected from changes made on other devices, but changes made on this device will be sent to the rest of the cluster.</string>
<string name="folder_type_receiveonly_description">Files are synchronized from the cluster, but any changes made locally will not be sent to other devices.</string>
<!-- Titles used in the pull order dialog and pull order button in the folder activity -->
<string name="pull_order">File Pull Order</string>