Skip to content

An open-source cross-platform alternative to AirDrop

feat: add send mode prototype

Tien Do Nam45335a64715e
diff --git a/assets/i18n/_missing_translations_ar.json b/assets/i18n/_missing_translations_ar.json
index 341c48f8..4ed88023 100644
--- a/assets/i18n/_missing_translations_ar.json
+++ b/assets/i18n/_missing_translations_ar.json
@@ -6,6 +6,12 @@
"sendTab": {
"picker": {
"app": "App"
+ },
+ "sendMode": "Send mode",
+ "sendModes": {
+ "single": "Single recipient",
+ "multiple": "Multiple recipients",
+ "link": "Share via link"
}
},
"settingsTab": {
@@ -33,6 +39,8 @@
},
"receiveHistoryPage": {
"title": "History",
+ "openFolder": "Open folder",
+ "deleteHistory": "Delete history",
"empty": "The history is empty.",
"entryActions": {
"open": "Open file",
@@ -71,6 +79,10 @@
"size": "Size:",
"sender": "Sender:",
"time": "Time:"
+ },
+ "notAvailableOnPlatform": {
+ "title": "Not available",
+ "content": "This feature is only available on:"
}
}
}
diff --git a/assets/i18n/_missing_translations_bn.json b/assets/i18n/_missing_translations_bn.json
index 81efc78a..01049387 100644
--- a/assets/i18n/_missing_translations_bn.json
+++ b/assets/i18n/_missing_translations_bn.json
@@ -6,6 +6,12 @@
"sendTab": {
"picker": {
"app": "App"
+ },
+ "sendMode": "Send mode",
+ "sendModes": {
+ "single": "Single recipient",
+ "multiple": "Multiple recipients",
+ "link": "Share via link"
}
},
"settingsTab": {
@@ -31,6 +37,8 @@
},
"receiveHistoryPage": {
"title": "History",
+ "openFolder": "Open folder",
+ "deleteHistory": "Delete history",
"empty": "The history is empty.",
"entryActions": {
"open": "Open file",
@@ -65,6 +73,10 @@
"size": "Size:",
"sender": "Sender:",
"time": "Time:"
+ },
+ "notAvailableOnPlatform": {
+ "title": "Not available",
+ "content": "This feature is only available on:"
}
}
}
diff --git a/assets/i18n/_missing_translations_es_ES.json b/assets/i18n/_missing_translations_es_ES.json
index 54bd83d0..516c8414 100644
--- a/assets/i18n/_missing_translations_es_ES.json
+++ b/assets/i18n/_missing_translations_es_ES.json
@@ -6,6 +6,12 @@
"sendTab": {
"picker": {
"app": "App"
+ },
+ "sendMode": "Send mode",
+ "sendModes": {
+ "single": "Single recipient",
+ "multiple": "Multiple recipients",
+ "link": "Share via link"
}
},
"settingsTab": {
@@ -29,6 +35,10 @@
"solution": "The problem exists on both sides? Then you need to make sure that both devices are in the same wifi network and share the same configuration (port, multicast address, encryption). The wifi may not allow communication between participants. In this case, this option must be enabled on the router."
}
},
+ "receiveHistoryPage": {
+ "openFolder": "Open folder",
+ "deleteHistory": "Delete history"
+ },
"apkPickerPage": {
"title": "Apps (APK)",
"excludeSystemApps": "Exclude system apps",
@@ -41,6 +51,10 @@
"dialogs": {
"errorDialog": {
"title": "@:general.error"
+ },
+ "notAvailableOnPlatform": {
+ "title": "Not available",
+ "content": "This feature is only available on:"
}
}
}
diff --git a/assets/i18n/_missing_translations_fr_FR.json b/assets/i18n/_missing_translations_fr_FR.json
index 8a4dd038..a5521705 100644
--- a/assets/i18n/_missing_translations_fr_FR.json
+++ b/assets/i18n/_missing_translations_fr_FR.json
@@ -4,14 +4,21 @@
"After editing this file, you can run 'flutter pub run slang apply --locale=fr-FR' to quickly apply the newly added translations."
],
"sendTab": {
- "picker": {
- "app": "Application"
+ "sendMode": "Send mode",
+ "sendModes": {
+ "single": "Single recipient",
+ "multiple": "Multiple recipients",
+ "link": "Share via link"
}
},
- "apkPickerPage": {
- "title": "Application (APK)",
- "excludeSystemApps": "Exclure les applications système",
- "excludeAppsWithoutLaunchIntent": "Exclure les applications non-lançables",
- "apps": "{n} Applications"
+ "receiveHistoryPage": {
+ "openFolder": "Open folder",
+ "deleteHistory": "Delete history"
+ },
+ "dialogs": {
+ "notAvailableOnPlatform": {
+ "title": "Not available",
+ "content": "This feature is only available on:"
+ }
}
}
diff --git a/assets/i18n/_missing_translations_hu.json b/assets/i18n/_missing_translations_hu.json
index 308016d9..4d877156 100644
--- a/assets/i18n/_missing_translations_hu.json
+++ b/assets/i18n/_missing_translations_hu.json
@@ -6,12 +6,28 @@
"sendTab": {
"picker": {
"app": "App"
+ },
+ "sendMode": "Send mode",
+ "sendModes": {
+ "single": "Single recipient",
+ "multiple": "Multiple recipients",
+ "link": "Share via link"
}
},
+ "receiveHistoryPage": {
+ "openFolder": "Open folder",
+ "deleteHistory": "Delete history"
+ },
"apkPickerPage": {
- "title": "Appok (APK)",
- "excludeSystemApps": "Rendszerappok kivételével",
- "excludeAppsWithoutLaunchIntent": "Nem-indítható appok kivételével",
- "apps": "{n} App"
+ "title": "Apps (APK)",
+ "excludeSystemApps": "Exclude system apps",
+ "excludeAppsWithoutLaunchIntent": "Exclude non-launchable apps",
+ "apps": "{n} Apps"
+ },
+ "dialogs": {
+ "notAvailableOnPlatform": {
+ "title": "Not available",
+ "content": "This feature is only available on:"
+ }
}
}
diff --git a/assets/i18n/_missing_translations_in.json b/assets/i18n/_missing_translations_in.json
index 525076b9..e5a2fc48 100644
--- a/assets/i18n/_missing_translations_in.json
+++ b/assets/i18n/_missing_translations_in.json
@@ -6,6 +6,12 @@
"sendTab": {
"picker": {
"app": "App"
+ },
+ "sendMode": "Send mode",
+ "sendModes": {
+ "single": "Single recipient",
+ "multiple": "Multiple recipients",
+ "link": "Share via link"
}
},
"settingsTab": {
@@ -31,6 +37,8 @@
},
"receiveHistoryPage": {
"title": "History",
+ "openFolder": "Open folder",
+ "deleteHistory": "Delete history",
"empty": "The history is empty.",
"entryActions": {
"open": "Open file",
@@ -65,6 +73,10 @@
"size": "Size:",
"sender": "Sender:",
"time": "Time:"
+ },
+ "notAvailableOnPlatform": {
+ "title": "Not available",
+ "content": "This feature is only available on:"
}
}
}
diff --git a/assets/i18n/_missing_translations_it.json b/assets/i18n/_missing_translations_it.json
index 84ce8861..28a5f648 100644
--- a/assets/i18n/_missing_translations_it.json
+++ b/assets/i18n/_missing_translations_it.json
@@ -6,6 +6,12 @@
"sendTab": {
"picker": {
"app": "App"
+ },
+ "sendMode": "Send mode",
+ "sendModes": {
+ "single": "Single recipient",
+ "multiple": "Multiple recipients",
+ "link": "Share via link"
}
},
"settingsTab": {
@@ -31,6 +37,8 @@
},
"receiveHistoryPage": {
"title": "History",
+ "openFolder": "Open folder",
+ "deleteHistory": "Delete history",
"empty": "The history is empty.",
"entryActions": {
"open": "Open file",
@@ -65,6 +73,10 @@
"size": "Size:",
"sender": "Sender:",
"time": "Time:"
+ },
+ "notAvailableOnPlatform": {
+ "title": "Not available",
+ "content": "This feature is only available on:"
}
}
}
diff --git a/assets/i18n/_missing_translations_iw.json b/assets/i18n/_missing_translations_iw.json
index 890b9c79..51d07548 100644
--- a/assets/i18n/_missing_translations_iw.json
+++ b/assets/i18n/_missing_translations_iw.json
@@ -6,6 +6,12 @@
"sendTab": {
"picker": {
"app": "App"
+ },
+ "sendMode": "Send mode",
+ "sendModes": {
+ "single": "Single recipient",
+ "multiple": "Multiple recipients",
+ "link": "Share via link"
}
},
"settingsTab": {
@@ -33,6 +39,8 @@
},
"receiveHistoryPage": {
"title": "History",
+ "openFolder": "Open folder",
+ "deleteHistory": "Delete history",
"empty": "The history is empty.",
"entryActions": {
"open": "Open file",
@@ -71,6 +79,10 @@
"size": "Size:",
"sender": "Sender:",
"time": "Time:"
+ },
+ "notAvailableOnPlatform": {
+ "title": "Not available",
+ "content": "This feature is only available on:"
}
}
}
diff --git a/assets/i18n/_missing_translations_ja.json b/assets/i18n/_missing_translations_ja.json
index 8a63a012..68e81019 100644
--- a/assets/i18n/_missing_translations_ja.json
+++ b/assets/i18n/_missing_translations_ja.json
@@ -6,12 +6,28 @@
"sendTab": {
"picker": {
"app": "App"
+ },
+ "sendMode": "Send mode",
+ "sendModes": {
+ "single": "Single recipient",
+ "multiple": "Multiple recipients",
+ "link": "Share via link"
}
},
+ "receiveHistoryPage": {
+ "openFolder": "Open folder",
+ "deleteHistory": "Delete history"
+ },
"apkPickerPage": {
"title": "Apps (APK)",
"excludeSystemApps": "Exclude system apps",
"excludeAppsWithoutLaunchIntent": "Exclude non-launchable apps",
"apps": "{n} Apps"
+ },
+ "dialogs": {
+ "notAvailableOnPlatform": {
+ "title": "Not available",
+ "content": "This feature is only available on:"
+ }
}
}
diff --git a/assets/i18n/_missing_translations_ko.json b/assets/i18n/_missing_translations_ko.json
index 9ddc8853..629ee3d5 100644
--- a/assets/i18n/_missing_translations_ko.json
+++ b/assets/i18n/_missing_translations_ko.json
@@ -6,6 +6,12 @@
"sendTab": {
"picker": {
"app": "App"
+ },
+ "sendMode": "Send mode",
+ "sendModes": {
+ "single": "Single recipient",
+ "multiple": "Multiple recipients",
+ "link": "Share via link"
}
},
"settingsTab": {
@@ -31,6 +37,8 @@
},
"receiveHistoryPage": {
"title": "History",
+ "openFolder": "Open folder",
+ "deleteHistory": "Delete history",
"empty": "The history is empty.",
"entryActions": {
"open": "Open file",
@@ -65,6 +73,10 @@
"size": "Size:",
"sender": "Sender:",
"time": "Time:"
+ },
+ "notAvailableOnPlatform": {
+ "title": "Not available",
+ "content": "This feature is only available on:"
}
}
}
diff --git a/assets/i18n/_missing_translations_ne.json b/assets/i18n/_missing_translations_ne.json
index 3f461931..86548bdc 100644
--- a/assets/i18n/_missing_translations_ne.json
+++ b/assets/i18n/_missing_translations_ne.json
@@ -6,6 +6,12 @@
"sendTab": {
"picker": {
"app": "App"
+ },
+ "sendMode": "Send mode",
+ "sendModes": {
+ "single": "Single recipient",
+ "multiple": "Multiple recipients",
+ "link": "Share via link"
}
},
"settingsTab": {
@@ -33,6 +39,8 @@
},
"receiveHistoryPage": {
"title": "History",
+ "openFolder": "Open folder",
+ "deleteHistory": "Delete history",
"empty": "The history is empty.",
"entryActions": {
"open": "Open file",
@@ -71,6 +79,10 @@
"size": "Size:",
"sender": "Sender:",
"time": "Time:"
+ },
+ "notAvailableOnPlatform": {
+ "title": "Not available",
+ "content": "This feature is only available on:"
}
}
}
diff --git a/assets/i18n/_missing_translations_pl.json b/assets/i18n/_missing_translations_pl.json
index 957211f9..d00f38f7 100644
--- a/assets/i18n/_missing_translations_pl.json
+++ b/assets/i18n/_missing_translations_pl.json
@@ -6,6 +6,12 @@
"sendTab": {
"picker": {
"app": "App"
+ },
+ "sendMode": "Send mode",
+ "sendModes": {
+ "single": "Single recipient",
+ "multiple": "Multiple recipients",
+ "link": "Share via link"
}
},
"settingsTab": {
@@ -33,6 +39,8 @@
},
"receiveHistoryPage": {
"title": "History",
+ "openFolder": "Open folder",
+ "deleteHistory": "Delete history",
"empty": "The history is empty.",
"entryActions": {
"open": "Open file",
@@ -71,6 +79,10 @@
"size": "Size:",
"sender": "Sender:",
"time": "Time:"
+ },
+ "notAvailableOnPlatform": {
+ "title": "Not available",
+ "content": "This feature is only available on:"
}
}
}
diff --git a/assets/i18n/_missing_translations_pt_BR.json b/assets/i18n/_missing_translations_pt_BR.json
index f794772c..af95a6d3 100644
--- a/assets/i18n/_missing_translations_pt_BR.json
+++ b/assets/i18n/_missing_translations_pt_BR.json
@@ -6,6 +6,12 @@
"sendTab": {
"picker": {
"app": "App"
+ },
+ "sendMode": "Send mode",
+ "sendModes": {
+ "single": "Single recipient",
+ "multiple": "Multiple recipients",
+ "link": "Share via link"
}
},
"settingsTab": {
@@ -29,6 +35,10 @@
"solution": "The problem exists on both sides? Then you need to make sure that both devices are in the same wifi network and share the same configuration (port, multicast address, encryption). The wifi may not allow communication between participants. In this case, this option must be enabled on the router."
}
},
+ "receiveHistoryPage": {
+ "openFolder": "Open folder",
+ "deleteHistory": "Delete history"
+ },
"apkPickerPage": {
"title": "Apps (APK)",
"excludeSystemApps": "Exclude system apps",
@@ -52,6 +62,10 @@
"size": "Size:",
"sender": "Sender:",
"time": "Time:"
+ },
+ "notAvailableOnPlatform": {
+ "title": "Not available",
+ "content": "This feature is only available on:"
}
}
}
diff --git a/assets/i18n/_missing_translations_ru.json b/assets/i18n/_missing_translations_ru.json
index 2376e670..ad3b8cc6 100644
--- a/assets/i18n/_missing_translations_ru.json
+++ b/assets/i18n/_missing_translations_ru.json
@@ -6,6 +6,12 @@
"sendTab": {
"picker": {
"app": "App"
+ },
+ "sendMode": "Send mode",
+ "sendModes": {
+ "single": "Single recipient",
+ "multiple": "Multiple recipients",
+ "link": "Share via link"
}
},
"settingsTab": {
@@ -33,6 +39,8 @@
},
"receiveHistoryPage": {
"title": "History",
+ "openFolder": "Open folder",
+ "deleteHistory": "Delete history",
"empty": "The history is empty.",
"entryActions": {
"open": "Open file",
@@ -71,6 +79,10 @@
"size": "Size:",
"sender": "Sender:",
"time": "Time:"
+ },
+ "notAvailableOnPlatform": {
+ "title": "Not available",
+ "content": "This feature is only available on:"
}
}
}
diff --git a/assets/i18n/_missing_translations_sv.json b/assets/i18n/_missing_translations_sv.json
index fe0e8184..fcc27962 100644
--- a/assets/i18n/_missing_translations_sv.json
+++ b/assets/i18n/_missing_translations_sv.json
@@ -6,6 +6,12 @@
"sendTab": {
"picker": {
"app": "App"
+ },
+ "sendMode": "Send mode",
+ "sendModes": {
+ "single": "Single recipient",
+ "multiple": "Multiple recipients",
+ "link": "Share via link"
}
},
"settingsTab": {
@@ -33,6 +39,8 @@
},
"receiveHistoryPage": {
"title": "History",
+ "openFolder": "Open folder",
+ "deleteHistory": "Delete history",
"empty": "The history is empty.",
"entryActions": {
"open": "Open file",
@@ -71,6 +79,10 @@
"size": "Size:",
"sender": "Sender:",
"time": "Time:"
+ },
+ "notAvailableOnPlatform": {
+ "title": "Not available",
+ "content": "This feature is only available on:"
}
}
}
diff --git a/assets/i18n/_missing_translations_tr.json b/assets/i18n/_missing_translations_tr.json
index 234dcfda..ecc89fec 100644
--- a/assets/i18n/_missing_translations_tr.json
+++ b/assets/i18n/_missing_translations_tr.json
@@ -6,6 +6,12 @@
"sendTab": {
"picker": {
"app": "App"
+ },
+ "sendMode": "Send mode",
+ "sendModes": {
+ "single": "Single recipient",
+ "multiple": "Multiple recipients",
+ "link": "Share via link"
}
},
"settingsTab": {
@@ -29,10 +35,20 @@
"solution": "The problem exists on both sides? Then you need to make sure that both devices are in the same wifi network and share the same configuration (port, multicast address, encryption). The wifi may not allow communication between participants. In this case, this option must be enabled on the router."
}
},
+ "receiveHistoryPage": {
+ "openFolder": "Open folder",
+ "deleteHistory": "Delete history"
+ },
"apkPickerPage": {
"title": "Apps (APK)",
"excludeSystemApps": "Exclude system apps",
"excludeAppsWithoutLaunchIntent": "Exclude non-launchable apps",
"apps": "{n} Apps"
+ },
+ "dialogs": {
+ "notAvailableOnPlatform": {
+ "title": "Not available",
+ "content": "This feature is only available on:"
+ }
}
}
diff --git a/assets/i18n/_missing_translations_uk.json b/assets/i18n/_missing_translations_uk.json
index 94fadb3f..8206f137 100644
--- a/assets/i18n/_missing_translations_uk.json
+++ b/assets/i18n/_missing_translations_uk.json
@@ -6,6 +6,12 @@
"sendTab": {
"picker": {
"app": "App"
+ },
+ "sendMode": "Send mode",
+ "sendModes": {
+ "single": "Single recipient",
+ "multiple": "Multiple recipients",
+ "link": "Share via link"
}
},
"settingsTab": {
@@ -33,6 +39,8 @@
},
"receiveHistoryPage": {
"title": "History",
+ "openFolder": "Open folder",
+ "deleteHistory": "Delete history",
"empty": "The history is empty.",
"entryActions": {
"open": "Open file",
@@ -71,6 +79,10 @@
"size": "Size:",
"sender": "Sender:",
"time": "Time:"
+ },
+ "notAvailableOnPlatform": {
+ "title": "Not available",
+ "content": "This feature is only available on:"
}
}
}
diff --git a/assets/i18n/_missing_translations_zh_Hans.json b/assets/i18n/_missing_translations_zh_Hans.json
index e76443c3..0f12d5a1 100644
--- a/assets/i18n/_missing_translations_zh_Hans.json
+++ b/assets/i18n/_missing_translations_zh_Hans.json
@@ -1,7 +1,18 @@
{
"@@info": [
"Here are translations that exist in <en> but not in <zh-Hans>.",
- "After editing this file, you can run 'flutter pub run slang apply --locale=zh-Hans' to quickly apply the newly added translations.",
- "Congratulations! There are no missing translations! :)"
- ]
+ "After editing this file, you can run 'flutter pub run slang apply --locale=zh-Hans' to quickly apply the newly added translations."
+ ],
+ "sendTab": {
+ "sendMode": "Send mode",
+ "sendModes": {
+ "single": "Single recipient",
+ "multiple": "Multiple recipients",
+ "link": "Share via link"
+ }
+ },
+ "receiveHistoryPage": {
+ "openFolder": "Open folder",
+ "deleteHistory": "Delete history"
+ }
}
diff --git a/assets/i18n/_missing_translations_zh_Hant_HK.json b/assets/i18n/_missing_translations_zh_Hant_HK.json
index 0f72a761..6527d0a7 100644
--- a/assets/i18n/_missing_translations_zh_Hant_HK.json
+++ b/assets/i18n/_missing_translations_zh_Hant_HK.json
@@ -6,6 +6,12 @@
"sendTab": {
"picker": {
"app": "App"
+ },
+ "sendMode": "Send mode",
+ "sendModes": {
+ "single": "Single recipient",
+ "multiple": "Multiple recipients",
+ "link": "Share via link"
}
},
"settingsTab": {
@@ -33,6 +39,8 @@
},
"receiveHistoryPage": {
"title": "History",
+ "openFolder": "Open folder",
+ "deleteHistory": "Delete history",
"empty": "The history is empty.",
"entryActions": {
"open": "Open file",
@@ -71,6 +79,10 @@
"size": "Size:",
"sender": "Sender:",
"time": "Time:"
+ },
+ "notAvailableOnPlatform": {
+ "title": "Not available",
+ "content": "This feature is only available on:"
}
}
}
diff --git a/assets/i18n/_missing_translations_zh_Hant_TW.json b/assets/i18n/_missing_translations_zh_Hant_TW.json
index 9f9170d4..c9767836 100644
--- a/assets/i18n/_missing_translations_zh_Hant_TW.json
+++ b/assets/i18n/_missing_translations_zh_Hant_TW.json
@@ -6,12 +6,28 @@
"sendTab": {
"picker": {
"app": "App"
+ },
+ "sendMode": "Send mode",
+ "sendModes": {
+ "single": "Single recipient",
+ "multiple": "Multiple recipients",
+ "link": "Share via link"
}
},
+ "receiveHistoryPage": {
+ "openFolder": "Open folder",
+ "deleteHistory": "Delete history"
+ },
"apkPickerPage": {
"title": "Apps (APK)",
"excludeSystemApps": "Exclude system apps",
"excludeAppsWithoutLaunchIntent": "Exclude non-launchable apps",
"apps": "{n} Apps"
+ },
+ "dialogs": {
+ "notAvailableOnPlatform": {
+ "title": "Not available",
+ "content": "This feature is only available on:"
+ }
}
}
diff --git a/assets/i18n/_unused_translations.json b/assets/i18n/_unused_translations.json
index 24e79c5d..d42a0c79 100644
--- a/assets/i18n/_unused_translations.json
+++ b/assets/i18n/_unused_translations.json
@@ -8,6 +8,15 @@
"general": {
"online": "Online",
"save": "Save"
+ },
+ "sendTab": {
+ "sendModes": {
+ "link": "Share via link"
+ }
+ },
+ "receiveHistoryPage": {
+ "openFolder": "Open folder",
+ "deleteHistory": "Delete history"
}
},
"ar": {},
diff --git a/assets/i18n/strings.i18n.json b/assets/i18n/strings.i18n.json
index e7b3d358..c060d178 100644
--- a/assets/i18n/strings.i18n.json
+++ b/assets/i18n/strings.i18n.json
@@ -62,6 +62,12 @@
"nearbyDevices": "Nearby devices",
"thisDevice": "This Device",
"scan": "Look for devices",
+ "sendMode": "Send mode",
+ "sendModes": {
+ "single": "Single recipient",
+ "multiple": "Multiple recipients",
+ "link": "Share via link"
+ },
"help": "Please ensure that the desired target is also in the same wifi network.",
"placeItems": "Place items to share."
},
@@ -118,6 +124,8 @@
},
"receiveHistoryPage": {
"title": "History",
+ "openFolder": "Open folder",
+ "deleteHistory": "Delete history",
"empty": "The history is empty.",
"entryActions": {
"open": "Open file",
diff --git a/assets/i18n/strings_de.i18n.json b/assets/i18n/strings_de.i18n.json
index 069c8660..2dc66bed 100644
--- a/assets/i18n/strings_de.i18n.json
+++ b/assets/i18n/strings_de.i18n.json
@@ -62,6 +62,12 @@
"nearbyDevices": "Geräte in der Nähe",
"thisDevice": "Dieses Gerät",
"scan": "Geräte suchen",
+ "sendMode": "Sende-Modus",
+ "sendModes": {
+ "single": "Einzelner Empfänger",
+ "multiple": "Mehrere Empfänger",
+ "link": "Per Link teilen"
+ },
"help": "Bitte stelle sicher, dass sich das gewünschte Ziel auch im selben WLAN-Netzwerk befindet.",
"placeItems": "Dateien ablegen, um zu teilen."
},
@@ -118,6 +124,8 @@
},
"receiveHistoryPage": {
"title": "Verlauf",
+ "openFolder": "Ordner öffnen",
+ "deleteHistory": "Verlauf löschen",
"empty": "Der Verlauf ist leer.",
"entryActions": {
"open": "Datei öffnen",
diff --git a/assets/i18n/strings_fr-FR.i18n.json b/assets/i18n/strings_fr-FR.i18n.json
index 6d2aee93..d081f4d3 100644
--- a/assets/i18n/strings_fr-FR.i18n.json
+++ b/assets/i18n/strings_fr-FR.i18n.json
@@ -55,7 +55,8 @@
"picker": {
"file": "Fichier",
"media": "Média",
- "text": "Texte"
+ "text": "Texte",
+ "app": "Application"
},
"shareIntentInfo": "Vous pouvez également utiliser la fonction \"Partager\" de votre appareil pour sélectionner des fichiers plus facilement.",
"nearbyDevices": "Appareils à proximité",
@@ -124,6 +125,12 @@
"deleteFromHistory": "Supprimer de l'historique"
}
},
+ "apkPickerPage": {
+ "title": "Application (APK)",
+ "excludeSystemApps": "Exclure les applications système",
+ "excludeAppsWithoutLaunchIntent": "Exclure les applications non-lançables",
+ "apps": "{n} Applications"
+ },
"selectedFilesPage": {
"deleteAll": "Tout supprimer"
},
diff --git a/lib/pages/tabs/send_tab.dart b/lib/pages/tabs/send_tab.dart
index 43a7fd4b..49e97a22 100644
--- a/lib/pages/tabs/send_tab.dart
+++ b/lib/pages/tabs/send_tab.dart
@@ -23,7 +23,7 @@ import 'package:localsend_app/widget/file_thumbnail.dart';
import 'package:localsend_app/widget/list_tile/device_list_tile.dart';
import 'package:localsend_app/widget/responsive_builder.dart';
import 'package:localsend_app/widget/responsive_list_view.dart';
-import 'package:localsend_app/widget/scan_button.dart';
+import 'package:localsend_app/widget/rotating_widget.dart';
import 'package:routerino/routerino.dart';
const _horizontalPadding = 15.0;
@@ -176,7 +176,7 @@ class _SendTabState extends ConsumerState<SendTab> {
),
),
const SizedBox(width: 10),
- ScanButton(
+ _ScanButton(
ips: networkInfo.localIps,
onSelect: (ip) => ref.read(scanProvider).startLegacySubnetScan(ip),
),
@@ -203,6 +203,43 @@ class _SendTabState extends ConsumerState<SendTab> {
child: const Icon(Icons.ads_click),
),
),
+ Tooltip(
+ message: t.sendTab.sendMode,
+ child: _CircularPopupButton(
+ tooltip: t.sendTab.sendMode,
+ onSelected: (i) => print('SEL $i'),
+ itemBuilder: (_) => [
+ PopupMenuItem(
+ value: 0,
+ // padding: const EdgeInsets.only(left: 12, right: 2),
+ child: Row(
+ mainAxisSize: MainAxisSize.min,
+ children: [
+ const Icon(Icons.send),
+ const SizedBox(width: 10),
+ Text(t.sendTab.sendModes.single),
+ ],
+ ),
+ ),
+ PopupMenuItem(
+ value: 1,
+ // padding: const EdgeInsets.only(left: 12, right: 2),
+ child: Row(
+ mainAxisSize: MainAxisSize.min,
+ children: [
+ const Icon(Icons.share),
+ const SizedBox(width: 10),
+ Text(t.sendTab.sendModes.multiple),
+ ],
+ ),
+ ),
+ ],
+ child: const Padding(
+ padding: EdgeInsets.all(8),
+ child: Icon(Icons.settings),
+ ),
+ ),
+ ),
],
),
Padding(
@@ -275,3 +312,112 @@ class _SendTabState extends ConsumerState<SendTab> {
);
}
}
+
+class _CircularPopupButton<T> extends StatelessWidget {
+ final String tooltip;
+ final PopupMenuItemBuilder<T> itemBuilder;
+ final PopupMenuItemSelected<T>? onSelected;
+ final Widget child;
+
+ const _CircularPopupButton({
+ required this.tooltip,
+ required this.onSelected,
+ required this.itemBuilder,
+ required this.child,
+ super.key,
+ });
+
+ @override
+ Widget build(BuildContext context) {
+ return ClipRRect(
+ borderRadius: BorderRadius.circular(9999),
+ child: Material(
+ type: MaterialType.transparency,
+ child: PopupMenuButton(
+ offset: const Offset(60, 40),
+ onSelected: onSelected,
+ tooltip: tooltip,
+ itemBuilder: itemBuilder,
+ child: child,
+ ),
+ ),
+ );
+ }
+}
+
+class _ScanButton extends ConsumerWidget {
+ final List<String> ips;
+ final void Function(String ip) onSelect;
+
+ const _ScanButton({
+ required this.ips,
+ required this.onSelect,
+ });
+
+ @override
+ Widget build(BuildContext context, WidgetRef ref) {
+ final scanningIps = ref.watch(nearbyDevicesProvider.select((s) => s.runningIps));
+
+ if (ips.length <= 1) {
+ return RotatingWidget(
+ duration: const Duration(seconds: 2),
+ spinning: scanningIps.isNotEmpty,
+ reverse: true,
+ child: CustomIconButton(
+ onPressed: () => onSelect(ips.first),
+ child: const Icon(Icons.sync),
+ ),
+ );
+ }
+
+ return _CircularPopupButton(
+ tooltip: t.sendTab.scan,
+ onSelected: (ip) => onSelect(ip),
+ itemBuilder: (_) {
+ return [
+ ...ips.map(
+ (ip) => PopupMenuItem(
+ value: ip,
+ padding: const EdgeInsets.only(left: 12, right: 8),
+ child: Row(
+ mainAxisSize: MainAxisSize.min,
+ children: [
+ _RotatingSyncIcon(ip),
+ const SizedBox(width: 10),
+ Text(ip),
+ ],
+ ),
+ ),
+ ),
+ ];
+ },
+ child: RotatingWidget(
+ duration: const Duration(seconds: 2),
+ spinning: scanningIps.isNotEmpty,
+ reverse: true,
+ child: const Padding(
+ padding: EdgeInsets.all(8),
+ child: Icon(Icons.sync),
+ ),
+ ),
+ );
+ }
+}
+
+/// A separate widget, so it gets the latest data from provider.
+class _RotatingSyncIcon extends ConsumerWidget {
+ final String ip;
+
+ const _RotatingSyncIcon(this.ip);
+
+ @override
+ Widget build(BuildContext context, WidgetRef ref) {
+ final scanningIps = ref.watch(nearbyDevicesProvider.select((s) => s.runningIps));
+ return RotatingWidget(
+ duration: const Duration(seconds: 2),
+ spinning: scanningIps.contains(ip),
+ reverse: true,
+ child: const Icon(Icons.sync),
+ );
+ }
+}
diff --git a/lib/widget/scan_button.dart b/lib/widget/scan_button.dart
deleted file mode 100644
index 34f379d8..00000000
--- a/lib/widget/scan_button.dart
+++ /dev/null
@@ -1,90 +0,0 @@
-import 'package:flutter/material.dart';
-import 'package:flutter_riverpod/flutter_riverpod.dart';
-import 'package:localsend_app/gen/strings.g.dart';
-import 'package:localsend_app/provider/network/nearby_devices_provider.dart';
-import 'package:localsend_app/widget/custom_icon_button.dart';
-import 'package:localsend_app/widget/rotating_widget.dart';
-
-class ScanButton extends ConsumerWidget {
- final List<String> ips;
- final void Function(String ip) onSelect;
-
- const ScanButton({
- required this.ips,
- required this.onSelect,
- });
-
- @override
- Widget build(BuildContext context, WidgetRef ref) {
- final scanningIps = ref.watch(nearbyDevicesProvider.select((s) => s.runningIps));
-
- if (ips.length <= 1) {
- return RotatingWidget(
- duration: const Duration(seconds: 2),
- spinning: scanningIps.isNotEmpty,
- reverse: true,
- child: CustomIconButton(
- onPressed: () => onSelect(ips.first),
- child: const Icon(Icons.sync),
- ),
- );
- }
-
- return ClipRRect(
- borderRadius: BorderRadius.circular(9999),
- child: Material(
- type: MaterialType.transparency,
- child: PopupMenuButton(
- offset: const Offset(60, 40),
- onSelected: (ip) => onSelect(ip),
- tooltip: t.sendTab.scan,
- itemBuilder: (_) {
- return [
- ...ips.map(
- (ip) => PopupMenuItem(
- value: ip,
- padding: const EdgeInsets.only(left: 12, right: 8),
- child: Row(
- mainAxisSize: MainAxisSize.min,
- children: [
- _RotatingSyncIcon(ip),
- const SizedBox(width: 10),
- Text(ip),
- ],
- ),
- ),
- ),
- ];
- },
- child: RotatingWidget(
- duration: const Duration(seconds: 2),
- spinning: scanningIps.isNotEmpty,
- reverse: true,
- child: const Padding(
- padding: EdgeInsets.all(8),
- child: Icon(Icons.sync),
- ),
- ),
- ),
- ),
- );
- }
-}
-
-/// A separate widget, so it gets the latest data from provider.
-class _RotatingSyncIcon extends ConsumerWidget {
- final String ip;
-
- const _RotatingSyncIcon(this.ip);
-
- @override
- Widget build(BuildContext context, WidgetRef ref) {
- final scanningIps = ref.watch(nearbyDevicesProvider.select((s) => s.runningIps));
- return RotatingWidget(
- duration: const Duration(seconds: 2),
- spinning: scanningIps.contains(ip),
- reverse: true,
- child: const Icon(Icons.sync),
- );
- }
-}