Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
146 commits
Select commit Hold shift + click to select a range
c3aedb9
# Conflicts:
BatPio Dec 20, 2022
0fd71a2
Delayed synchronization
BatPio Dec 20, 2022
3893d8c
master merge fixes
BatPio Dec 20, 2022
a93c3d7
master merge fixes
BatPio Dec 20, 2022
28766ef
Licences
BatPio Dec 20, 2022
a4d47ec
Fixes
BatPio Dec 20, 2022
e6dfc64
Fixes
BatPio Dec 20, 2022
078c9d4
Tuning
BatPio Jan 11, 2023
c09cd0d
Tuning
BatPio Jan 11, 2023
4709531
Merge fixes
BatPio Jan 19, 2023
3efff03
Rename .java to .kt
BatPio Jan 19, 2023
174b93a
New files converted to Kotlin
BatPio Jan 19, 2023
76a2964
CI hints fixes
BatPio Jan 19, 2023
d1b033f
CI Fixes
BatPio Jan 19, 2023
0572790
CI Fixes
BatPio Jan 19, 2023
31bcf88
Lint fixes
BatPio Jan 20, 2023
adca1d0
CI fixes
BatPio Jan 20, 2023
fde9dcf
Lint fixes
BatPio Jan 20, 2023
5dc55e0
Screenshot test fixes
BatPio Jan 21, 2023
afafa0c
CR fixes
BatPio Jan 26, 2023
367c940
Merge branch 'master' into feature/7815/delayed-synchronization-simpl…
BatPio Jan 26, 2023
c9b92be
master merge fixes
BatPio Jan 26, 2023
9308b11
master merge fixes
BatPio Jan 26, 2023
ff7a64d
Merge branch 'nextcloud:master' into feature/7815/delayed-synchroniza…
BatPio Jan 29, 2023
6b04ab5
Merge branch 'master' into feature/7815/delayed-synchronization-simpl…
BatPio Jan 29, 2023
3d40c3a
Merge remote-tracking branch 'origin/feature/7815/delayed-synchroniza…
BatPio Jan 29, 2023
501d1fe
Update app/src/main/java/com/nextcloud/client/database/entity/SyncedF…
BatPio Mar 8, 2023
a3c03c3
master merge fixes
BatPio Mar 8, 2023
b09ebba
Merge branch 'nextcloud:master' into feature/7815/delayed-synchroniza…
BatPio Mar 8, 2023
d0e2168
fixes
BatPio Mar 8, 2023
846794e
Merge branch 'master' into feature/7815/delayed-synchronization-simpl…
BatPio Apr 17, 2023
b6bbea7
synchronization fix
BatPio Apr 17, 2023
6e06c60
Merge branch 'master' into feature/7815/delayed-synchronization-simpl…
BatPio Apr 20, 2023
317ef6e
Merge branch 'master' into feature/7815/delayed-synchronization-simpl…
BatPio Apr 24, 2023
caf858f
Rename .java to .kt
BatPio Aug 4, 2024
4dab2bf
SyncedFolderPreferencesDialogFragment migration
BatPio Aug 4, 2024
3794f5c
SyncedFolderPreferencesDialogFragment moved dialog
BatPio Aug 4, 2024
94af1c7
Merge branch 'master' into feature/7815/delayed-synchronization-simpl…
BatPio Aug 4, 2024
847ef54
SyncedFolderPreferencesDialogFragment moved dialog
BatPio Aug 4, 2024
a501417
Licence update
BatPio Aug 4, 2024
0efe809
CI fixes
BatPio Aug 4, 2024
3a84661
Fixes
BatPio Aug 4, 2024
53ee162
Merge branch 'refs/heads/master' into feature/7815/delayed-synchroniz…
BatPio Aug 4, 2024
56a9002
@Suppress("TooManyFunctions")
BatPio Aug 5, 2024
cb417f0
Merge branch 'refs/heads/master' into feature/7815/delayed-synchroniz…
BatPio Aug 5, 2024
7b11a43
Merge branch 'refs/heads/master' into feature/7815/delayed-synchroniz…
BatPio Sep 3, 2024
eefb03e
Merged with main
BatPio Sep 3, 2024
6336f88
Merge branch 'refs/heads/master' into feature/7815/delayed-synchroniz…
BatPio Oct 27, 2024
bc83af2
Merged with main
BatPio Oct 27, 2024
954bfc0
Merge branch 'refs/heads/master' into feature/7815/delayed-synchroniz…
BatPio Dec 3, 2024
5f114c4
Merge branch 'master' into feature/7815/delayed-synchronization-simpl…
BatPio Dec 7, 2024
0f8f61e
Merge branch 'master' into feature/7815/delayed-synchronization-simpl…
BatPio Jan 6, 2025
6fda157
Merged with main
BatPio Jan 8, 2025
8547450
Merge branch 'master' into feature/7815/delayed-synchronization-simpl…
BatPio Jan 8, 2025
8adf6fd
Merge branch 'nextcloud:master' into feature/7815/delayed-synchroniza…
BatPio Jan 9, 2025
5252a7e
Merge branch 'master' into feature/7815/delayed-synchronization-simpl…
BatPio Jan 9, 2025
ff490d5
Merge remote-tracking branch 'origin/feature/7815/delayed-synchroniza…
BatPio Jan 9, 2025
190844e
Merge branch 'master' into feature/7815/delayed-synchronization-simpl…
BatPio Jan 10, 2025
fb2f319
# Conflicts:
BatPio Dec 20, 2022
0ddfb81
Delayed synchronization
BatPio Dec 20, 2022
4d34599
master merge fixes
BatPio Dec 20, 2022
31f12f7
Licences
BatPio Dec 20, 2022
6ad722a
Fixes
BatPio Dec 20, 2022
d0c2035
Fixes
BatPio Dec 20, 2022
73bd88c
Tuning
BatPio Jan 11, 2023
945b615
Tuning
BatPio Jan 11, 2023
d7f3d07
Merge fixes
BatPio Jan 19, 2023
8d15e6a
Rename .java to .kt
BatPio Jan 19, 2023
b88c974
New files converted to Kotlin
BatPio Jan 19, 2023
f846b29
CI hints fixes
BatPio Jan 19, 2023
345b2ae
CI Fixes
BatPio Jan 19, 2023
da817ff
CI Fixes
BatPio Jan 19, 2023
3ba21df
Lint fixes
BatPio Jan 20, 2023
cc16e85
CI fixes
BatPio Jan 20, 2023
d9345fd
Lint fixes
BatPio Jan 20, 2023
07c2300
Screenshot test fixes
BatPio Jan 21, 2023
212240a
CR fixes
BatPio Jan 26, 2023
dbf48f0
Update app/src/main/java/com/nextcloud/client/database/entity/SyncedF…
BatPio Mar 8, 2023
ed7397e
Licence update
BatPio Aug 4, 2024
60208db
Fixes
BatPio Aug 4, 2024
ee71275
@Suppress("TooManyFunctions")
BatPio Aug 5, 2024
c5d1853
Merged with main
BatPio Oct 27, 2024
17da386
Fix(l10n): Update translations from Transifex
nextcloud-bot Jan 9, 2025
077101e
Fix(l10n): Update translations from Transifex
nextcloud-bot Jan 9, 2025
1c7534e
Fix(l10n): Update translations from Transifex
nextcloud-bot Jan 9, 2025
c512805
Fix(l10n): Update translations from Transifex
nextcloud-bot Jan 10, 2025
c231a84
revert removing verification
tobiasKaminsky Jan 9, 2025
ea9663d
bump lib
tobiasKaminsky Jan 10, 2025
281bc60
re-add lint check for translation
tobiasKaminsky Jan 9, 2025
ac35fcf
fix(deps): update dependency com.android.tools.build:gradle to v8.8.0
renovate[bot] Jan 10, 2025
3b6eb91
Merge remote-tracking branch 'origin/feature/7815/delayed-synchroniza…
BatPio Jan 10, 2025
8e51872
Fixes after CR
BatPio Jan 10, 2025
4408147
DB automigration
BatPio Jan 10, 2025
0fb4570
Merge branch 'master' into feature/7815/delayed-synchronization-simpl…
BatPio Jan 13, 2025
7778a5c
Merge branch 'master' into feature/7815/delayed-synchronization-simpl…
BatPio Jan 15, 2025
5d0af28
Merge branch 'master' into feature/7815/delayed-synchronization-simpl…
BatPio Feb 3, 2025
017e6d1
Merge remote-tracking branch 'origin/feature/7815/delayed-synchroniza…
BatPio Feb 3, 2025
ccafc2b
Master merge fixes
BatPio Feb 5, 2025
831a557
Merge branch 'master' into feature/7815/delayed-synchronization-simpl…
BatPio Feb 5, 2025
c1e057a
Merge branch 'master' into feature/7815/delayed-synchronization-simpl…
BatPio Feb 6, 2025
0f23102
Merge branch 'master' into feature/7815/delayed-synchronization-simpl…
BatPio Feb 7, 2025
d5e22e8
Merge branch 'master' into feature/7815/delayed-synchronization-simpl…
BatPio Feb 11, 2025
d4090a5
Merge branch 'master' into feature/7815/delayed-synchronization-simpl…
BatPio Feb 14, 2025
72163ed
Update app/src/main/java/com/owncloud/android/ui/dialog/DurationPicke…
BatPio Feb 19, 2025
5eda49c
Update app/src/main/java/com/owncloud/android/ui/dialog/DurationPicke…
BatPio Feb 19, 2025
e5a71e1
Update app/src/main/res/layout/duration_picker.xml
BatPio Feb 19, 2025
09aa0e1
Update app/src/main/res/layout/duration_picker.xml
BatPio Feb 19, 2025
3f57658
Update app/src/main/res/layout/duration_picker.xml
BatPio Feb 19, 2025
dc792f6
Update app/src/main/java/com/owncloud/android/datamodel/FilesystemDat…
BatPio Feb 19, 2025
40470e3
Using kotlin Duration instead of TimeUtils
BatPio Feb 19, 2025
19c140c
Merge branch 'master' into feature/7815/delayed-synchronization-simpl…
BatPio Feb 19, 2025
aca4708
DurationPicker layout fixes
BatPio Feb 23, 2025
8e16f9a
Merge branch 'master' into feature/7815/delayed-synchronization-simpl…
BatPio Feb 23, 2025
71230f5
DurationPicker layout fixes
BatPio Feb 23, 2025
bae2736
DurationPicker labels
BatPio Feb 26, 2025
905f08b
DurationPicker labels
BatPio Feb 26, 2025
c587d47
Renamed to Min file age
BatPio Feb 26, 2025
56a11f5
Merge branch 'master' into feature/7815/delayed-synchronization-simpl…
BatPio Feb 26, 2025
f5797bb
Merge with master
BatPio Feb 26, 2025
cae6fc0
Renamed to Min file Age fixes
BatPio Feb 26, 2025
f91158e
Renamed to Min file Age fixes
BatPio Feb 26, 2025
f743734
DurationPicker replaced with singleChoiceItem dialog
BatPio Mar 19, 2025
cc60e52
Merge branch 'master' into feature/7815/delayed-synchronization-simpl…
BatPio Mar 19, 2025
16c1dbd
Duration singleChoiceItem dialog values tuning
BatPio Mar 23, 2025
3758f1d
Merge branch 'master' into feature/7815/delayed-synchronization-simpl…
BatPio Mar 23, 2025
3d1bf97
Merge branch 'master' into feature/7815/delayed-synchronization-simpl…
BatPio Mar 24, 2025
676524a
Merge branch 'master' into feature/7815/delayed-synchronization-simpl…
BatPio Mar 25, 2025
d462b6a
Merge branch 'master' into feature/7815/delayed-synchronization-simpl…
BatPio Apr 23, 2025
3d73c5e
Master merge fixes
BatPio Apr 23, 2025
1e38504
Merge branch 'master' into feature/7815/delayed-synchronization-simpl…
BatPio May 12, 2025
3fe67c9
Merge branch 'master' into feature/7815/delayed-synchronization-simpl…
BatPio May 13, 2025
2b84b20
Merge branch 'master' into feature/7815/delayed-synchronization-simpl…
BatPio May 22, 2025
886fbf1
Master merge fixes
BatPio May 22, 2025
839e942
Master merge fixes
BatPio May 22, 2025
7d1efc1
Merge branch 'master' into feature/7815/delayed-synchronization-fixes
BatPio Jun 22, 2025
c9b9614
Master merge fixes
BatPio Jun 22, 2025
79ff670
Merge branch 'master' into feature/7815/delayed-synchronization-fixes
BatPio Jul 26, 2025
153c4a1
Merge branch 'refs/heads/master' into feature/7815/delayed-synchroniz…
BatPio Aug 8, 2025
a5cae1b
ModificationDate fix
BatPio Aug 8, 2025
ac56636
Merge fixes
BatPio Aug 8, 2025
a9fc846
Merge fixes
BatPio Aug 8, 2025
4d393e7
Merge fixes
BatPio Aug 8, 2025
8d72c3b
Merge branch 'master' into feature/7815/delayed-synchronization-simpl…
BatPio Nov 4, 2025
ef89906
Merge branch 'refs/heads/master' into feature/7815/delayed-synchroniz…
BatPio Dec 20, 2025
17dad7e
Merge fixes
BatPio Dec 20, 2025
18c5c35
Merge fixes
BatPio Dec 20, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1,298 changes: 1,298 additions & 0 deletions app/schemas/com.nextcloud.client.database.NextcloudDatabase/97.json

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,7 @@ class SyncedFoldersActivityIT : AbstractIT() {
"test@https://nextcloud.localhost",
0,
0,
0,
true,
1000,
"Name",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -170,6 +170,7 @@ class SyncedFolderUtilsTest : AbstractIT() {
account.name,
1,
1,
0,
true,
0L,
MediaFolderType.IMAGE,
Expand All @@ -195,6 +196,7 @@ class SyncedFolderUtilsTest : AbstractIT() {
account.name,
1,
1,
0,
true,
0L,
MediaFolderType.IMAGE,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,8 @@ import com.owncloud.android.db.ProviderMeta
AutoMigration(from = 92, to = 93, spec = DatabaseMigrationUtil.ResetCapabilitiesPostMigration::class),
AutoMigration(from = 93, to = 94, spec = DatabaseMigrationUtil.ResetCapabilitiesPostMigration::class),
AutoMigration(from = 94, to = 95, spec = DatabaseMigrationUtil.ResetCapabilitiesPostMigration::class),
AutoMigration(from = 95, to = 96)
AutoMigration(from = 95, to = 96),
AutoMigration(from = 96, to = 97)
],
exportSchema = true
)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,11 +36,17 @@ interface FileSystemDao {
AND ${ProviderMeta.ProviderTableMeta.FILESYSTEM_FILE_SENT_FOR_UPLOAD} = 0
AND ${ProviderMeta.ProviderTableMeta.FILESYSTEM_FILE_IS_FOLDER} = 0
AND ${ProviderMeta.ProviderTableMeta._ID} > :lastId
AND ${ProviderMeta.ProviderTableMeta.FILESYSTEM_FILE_MODIFIED} <= :maxFileTimestamp
ORDER BY ${ProviderMeta.ProviderTableMeta._ID}
LIMIT :limit
"""
)
suspend fun getAutoUploadFilesEntities(syncedFolderId: String, limit: Int, lastId: Int): List<FilesystemEntity>
suspend fun getAutoUploadFilesEntities(
syncedFolderId: String,
limit: Int,
lastId: Int,
maxFileTimestamp: Long
): List<FilesystemEntity>

@Query(
"""
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,8 @@ data class SyncedFolderEntity(
val uploadAction: Int?,
@ColumnInfo(name = ProviderTableMeta.SYNCED_FOLDER_NAME_COLLISION_POLICY)
val nameCollisionPolicy: Int?,
@ColumnInfo(name = ProviderTableMeta.SYNCED_FOLDER_UPLOAD_MIN_FILE_AGE_MS)
val uploadMinFileAgeMs: Long?,
@ColumnInfo(name = ProviderTableMeta.SYNCED_FOLDER_TYPE)
val type: Int?,
@ColumnInfo(name = ProviderTableMeta.SYNCED_FOLDER_HIDDEN)
Expand Down Expand Up @@ -75,6 +77,8 @@ fun SyncedFolderEntity.toSyncedFolder(): SyncedFolder = SyncedFolder(
this.uploadAction ?: 0,
// nameCollisionPolicy
this.nameCollisionPolicy ?: 0,
// uploadMinFileAgeMs
this.uploadMinFileAgeMs ?: 0,
// enabled
this.enabled == 1,
// timestampMs
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,8 +35,11 @@ class FileSystemRepository(private val dao: FileSystemDao, private val context:
suspend fun getFilePathsWithIds(syncedFolder: SyncedFolder, lastId: Int): List<Pair<String, Int>> {
val syncedFolderId = syncedFolder.id.toString()
Log_OC.d(TAG, "Fetching candidate files for syncedFolderId = $syncedFolderId")

val entities = dao.getAutoUploadFilesEntities(syncedFolderId, BATCH_SIZE, lastId)
var maxFileTimestamp = Long.MAX_VALUE
if (syncedFolder.uploadMinFileAgeMs > 0) {
maxFileTimestamp = System.currentTimeMillis() - syncedFolder.uploadMinFileAgeMs
}
val entities = dao.getAutoUploadFilesEntities(syncedFolderId, BATCH_SIZE, lastId, maxFileTimestamp)
val filtered = mutableListOf<Pair<String, Int>>()

entities.forEach {
Expand Down
13 changes: 13 additions & 0 deletions app/src/main/java/com/owncloud/android/datamodel/SyncedFolder.java
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ public class SyncedFolder implements Serializable, Cloneable {
private boolean chargingOnly;
private boolean existing;
private boolean subfolderByDate;
private long uploadMinFileAgeMs;
private String account;
private int uploadAction;
private int nameCollisionPolicy;
Expand Down Expand Up @@ -77,6 +78,7 @@ public SyncedFolder(String localPath,
String account,
int uploadAction,
int nameCollisionPolicy,
long uploadMinFileAgeMs,
boolean enabled,
long timestampMs,
MediaFolderType type,
Expand All @@ -94,6 +96,7 @@ public SyncedFolder(String localPath,
account,
uploadAction,
nameCollisionPolicy,
uploadMinFileAgeMs,
enabled,
timestampMs,
type,
Expand All @@ -118,6 +121,7 @@ public SyncedFolder(long id,
String account,
int uploadAction,
int nameCollisionPolicy,
long uploadMinFileAgeMs,
boolean enabled,
long timestampMs,
MediaFolderType type,
Expand All @@ -135,6 +139,7 @@ public SyncedFolder(long id,
this.account = account;
this.uploadAction = uploadAction;
this.nameCollisionPolicy = nameCollisionPolicy;
this.uploadMinFileAgeMs = uploadMinFileAgeMs;
this.setEnabled(enabled, timestampMs);
this.type = type;
this.hidden = hidden;
Expand Down Expand Up @@ -225,6 +230,10 @@ public NameCollisionPolicy getNameCollisionPolicy() {
return NameCollisionPolicy.deserialize(nameCollisionPolicy);
}

public long getUploadMinFileAgeMs() {
return uploadMinFileAgeMs;
}

public boolean isEnabled() {
return this.enabled;
}
Expand Down Expand Up @@ -283,6 +292,10 @@ public void setNameCollisionPolicy(int nameCollisionPolicy) {
this.nameCollisionPolicy = nameCollisionPolicy;
}

public void setUploadMinFileAgeMs(long uploadMinFileAgeMs) {
this.uploadMinFileAgeMs = uploadMinFileAgeMs;
}

public void setType(MediaFolderType type) {
this.type = type;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,7 @@ public SyncedFolderDisplayItem(long id,
String account,
int uploadAction,
int nameCollisionPolicy,
long uploadMinFileAgeMs,
boolean enabled,
long timestampMs,
List<String> filePaths,
Expand All @@ -72,6 +73,7 @@ public SyncedFolderDisplayItem(long id,
account,
uploadAction,
nameCollisionPolicy,
uploadMinFileAgeMs,
enabled,
timestampMs,
type,
Expand All @@ -94,6 +96,7 @@ public SyncedFolderDisplayItem(long id,
String account,
int uploadAction,
int nameCollisionPolicy,
long uploadMinFileAgeMs,
boolean enabled,
long timestampMs,
String folderName,
Expand All @@ -112,6 +115,7 @@ public SyncedFolderDisplayItem(long id,
account,
uploadAction,
nameCollisionPolicy,
uploadMinFileAgeMs,
enabled,
timestampMs,
type,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -352,6 +352,8 @@ private SyncedFolder createSyncedFolderFromCursor(Cursor cursor) {
ProviderMeta.ProviderTableMeta.SYNCED_FOLDER_EXISTING)) == 1;
boolean subfolderByDate = cursor.getInt(cursor.getColumnIndexOrThrow(
ProviderMeta.ProviderTableMeta.SYNCED_FOLDER_SUBFOLDER_BY_DATE)) == 1;
long uploadMinFileAgeMs = cursor.getLong(cursor.getColumnIndexOrThrow(
ProviderMeta.ProviderTableMeta.SYNCED_FOLDER_UPLOAD_MIN_FILE_AGE_MS));
String accountName = cursor.getString(cursor.getColumnIndexOrThrow(
ProviderMeta.ProviderTableMeta.SYNCED_FOLDER_ACCOUNT));
int uploadAction = cursor.getInt(cursor.getColumnIndexOrThrow(
Expand Down Expand Up @@ -384,6 +386,7 @@ private SyncedFolder createSyncedFolderFromCursor(Cursor cursor) {
accountName,
uploadAction,
nameCollisionPolicy,
uploadMinFileAgeMs,
enabled,
enabledTimestampMs,
type,
Expand Down Expand Up @@ -412,6 +415,7 @@ private ContentValues createContentValuesFromSyncedFolder(SyncedFolder syncedFol
cv.put(ProviderMeta.ProviderTableMeta.SYNCED_FOLDER_ENABLED, syncedFolder.isEnabled());
cv.put(ProviderMeta.ProviderTableMeta.SYNCED_FOLDER_ENABLED_TIMESTAMP_MS, syncedFolder.getEnabledTimestampMs());
cv.put(ProviderMeta.ProviderTableMeta.SYNCED_FOLDER_SUBFOLDER_BY_DATE, syncedFolder.isSubfolderByDate());
cv.put(ProviderMeta.ProviderTableMeta.SYNCED_FOLDER_UPLOAD_MIN_FILE_AGE_MS, syncedFolder.getUploadMinFileAgeMs());
cv.put(ProviderMeta.ProviderTableMeta.SYNCED_FOLDER_ACCOUNT, syncedFolder.getAccount());
cv.put(ProviderMeta.ProviderTableMeta.SYNCED_FOLDER_UPLOAD_ACTION, syncedFolder.getUploadAction());
cv.put(ProviderMeta.ProviderTableMeta.SYNCED_FOLDER_NAME_COLLISION_POLICY,
Expand Down
3 changes: 2 additions & 1 deletion app/src/main/java/com/owncloud/android/db/ProviderMeta.java
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
*/
public class ProviderMeta {
public static final String DB_NAME = "filelist";
public static final int DB_VERSION = 96;
public static final int DB_VERSION = 97;

private ProviderMeta() {
// No instance
Expand Down Expand Up @@ -333,6 +333,7 @@ static public class ProviderTableMeta implements BaseColumns {
public static final String SYNCED_FOLDER_ACCOUNT = "account";
public static final String SYNCED_FOLDER_UPLOAD_ACTION = "upload_option";
public static final String SYNCED_FOLDER_NAME_COLLISION_POLICY = "name_collision_policy";
public static final String SYNCED_FOLDER_UPLOAD_MIN_FILE_AGE_MS = "upload_min_file_age_ms";
public static final String SYNCED_FOLDER_HIDDEN = "hidden";
public static final String SYNCED_FOLDER_SUBFOLDER_RULE = "sub_folder_rule";
public static final String SYNCED_FOLDER_EXCLUDE_HIDDEN = "exclude_hidden";
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -386,6 +386,7 @@ class SyncedFoldersActivity :
syncedFolder.account,
syncedFolder.uploadAction,
syncedFolder.nameCollisionPolicyInt,
syncedFolder.uploadMinFileAgeMs,
syncedFolder.isEnabled,
clock.currentTime,
filePaths,
Expand Down Expand Up @@ -418,6 +419,7 @@ class SyncedFoldersActivity :
syncedFolder.account,
syncedFolder.uploadAction,
syncedFolder.nameCollisionPolicyInt,
syncedFolder.uploadMinFileAgeMs,
syncedFolder.isEnabled,
clock.currentTime,
mediaFolder.filePaths,
Expand Down Expand Up @@ -448,6 +450,7 @@ class SyncedFoldersActivity :
account.name,
FileUploadWorker.LOCAL_BEHAVIOUR_FORGET,
NameCollisionPolicy.ASK_USER.serialize(),
0,
false,
clock.currentTime,
mediaFolder.filePaths,
Expand Down Expand Up @@ -541,6 +544,7 @@ class SyncedFoldersActivity :
account.name,
FileUploadWorker.LOCAL_BEHAVIOUR_FORGET,
NameCollisionPolicy.ASK_USER.serialize(),
0,
false,
clock.currentTime,
null,
Expand Down Expand Up @@ -677,6 +681,7 @@ class SyncedFoldersActivity :
syncedFolder.account,
syncedFolder.uploadAction,
syncedFolder.nameCollisionPolicy.serialize(),
syncedFolder.uploadMinFileAgeMs,
syncedFolder.isEnabled,
clock.currentTime,
File(syncedFolder.localPath).name,
Expand All @@ -701,6 +706,7 @@ class SyncedFoldersActivity :
syncedFolder.isSubfolderByDate,
syncedFolder.uploadAction,
syncedFolder.nameCollisionPolicy.serialize(),
syncedFolder.uploadMinFileAgeMs,
syncedFolder.isEnabled,
syncedFolder.subFolderRule,
syncedFolder.isExcludeHidden
Expand Down Expand Up @@ -789,6 +795,7 @@ class SyncedFoldersActivity :
* @param subfolderByDate created sub folders
* @param uploadAction upload action
* @param nameCollisionPolicy what to do on name collision
* @param uploadMinFileAgeMs minimal age of file to upload
* @param enabled is sync enabled
* @param excludeHidden exclude hidden file or folder, for {@link MediaFolderType#CUSTOM} only
*/
Expand All @@ -804,6 +811,7 @@ class SyncedFoldersActivity :
subfolderByDate: Boolean,
uploadAction: Int,
nameCollisionPolicy: Int,
uploadMinFileAgeMs: Long,
enabled: Boolean,
subFolderRule: SubFolderRule,
excludeHidden: Boolean
Expand All @@ -817,6 +825,7 @@ class SyncedFoldersActivity :
item.isSubfolderByDate = subfolderByDate
item.uploadAction = uploadAction
item.setNameCollisionPolicy(nameCollisionPolicy)
item.uploadMinFileAgeMs = uploadMinFileAgeMs
item.setEnabled(enabled, clock.currentTime)
item.setSubFolderRule(subFolderRule)
item.setExcludeHidden(excludeHidden)
Expand Down
Loading
Loading