1
0
Fork 0
mirror of https://git.jami.net/savoirfairelinux/jami-client-qt.git synced 2025-07-24 09:25:33 +02:00

account_archive: unify archive file type

When creating an account archive, there would be no default
suffix. Then, when importing the archives, we would filter
for .gz files by name. The goal is to implement a .jami
file extension for archives across all platforms.

Todo: implement custom MIME type for custom icons.

GitLab: #1256
Change-Id: I202ae5670c928f35b0eaf711abf7249ec3f304b9
This commit is contained in:
Andreas Hatziiliou 2024-10-21 09:58:59 -04:00
parent 7424227f00
commit a1c2b8adef
4 changed files with 7 additions and 5 deletions

View file

@ -119,7 +119,8 @@ Item {
"title": JamiStrings.backupAccountHere,
"fileMode": JamiFileDialog.SaveFile,
"folder": StandardPaths.writableLocation(StandardPaths.HomeLocation) + "/Desktop",
"nameFilters": [JamiStrings.jamiArchiveFiles, JamiStrings.allFiles]
"nameFilters": [JamiStrings.jamiAccountFiles, JamiStrings.allFiles],
"defaultSuffix": ".jac"
});
dlg.fileAccepted.connect(function (file) {
// Is there password? If so, go to password dialog, else, go to following directly

View file

@ -216,7 +216,7 @@ Item {
property string backupAccountBtn: qsTr("Back up account")
property string success: qsTr("Success")
property string error: qsTr("Error")
property string jamiArchiveFiles: qsTr("Jami archive files (*.gz)")
property string jamiAccountFiles: qsTr("Jami account (*.jac)")
property string allFiles: qsTr("All files (*)")
// ContactItemDelegate

View file

@ -349,8 +349,9 @@ SettingsPageBase {
"title": JamiStrings.backupAccountHere,
"fileMode": FileDialog.SaveFile,
"folder": StandardPaths.writableLocation(StandardPaths.DesktopLocation),
"nameFilters": [JamiStrings.jamiArchiveFiles, JamiStrings.allFiles]
});
"nameFilters": [JamiStrings.jamiAccountFiles, JamiStrings.allFiles],
"defaultSuffix": ".jac"
})
dlg.fileAccepted.connect(function (file) {
// is there password? If so, go to password dialog, else, go to following directly
var exportPath = UtilsAdapter.getAbsPath(file.toString());

View file

@ -133,7 +133,7 @@ Rectangle {
"title": JamiStrings.openFile,
"fileMode": JamiFileDialog.OpenFile,
"folder": StandardPaths.writableLocation(StandardPaths.HomeLocation) + "/Desktop",
"nameFilters": [JamiStrings.jamiArchiveFiles, JamiStrings.allFiles]
"nameFilters": [JamiStrings.jamiAccountFiles, JamiStrings.allFiles]
});
dlg.fileAccepted.connect(function (file) {
filePath = file;