Skip to content

Commit

Permalink
Remove 'unsynced' status from password list and edit password view if…
Browse files Browse the repository at this point in the history
… storage provider doesn't require syncing.
  • Loading branch information
tijme committed Jun 27, 2023
1 parent 009adb0 commit e02a346
Show file tree
Hide file tree
Showing 5 changed files with 17 additions and 22 deletions.
8 changes: 4 additions & 4 deletions Raivo.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -1649,7 +1649,7 @@
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
CODE_SIGN_ENTITLEMENTS = Raivo/Raivo.entitlements;
CODE_SIGN_STYLE = Automatic;
CURRENT_PROJECT_VERSION = 84;
CURRENT_PROJECT_VERSION = 85;
DEVELOPMENT_TEAM = 564B4ETY69;
INFOPLIST_FILE = "$(SRCROOT)/Raivo/Supporting/Info.plist";
INFOPLIST_KEY_LSApplicationCategoryType = "public.app-category.productivity";
Expand All @@ -1658,7 +1658,7 @@
"$(inherited)",
"@executable_path/Frameworks",
);
MARKETING_VERSION = 1.4.19;
MARKETING_VERSION = 1.4.20;
PRODUCT_BUNDLE_IDENTIFIER = com.finnwea.Raivo.Debug;
PRODUCT_NAME = "$(TARGET_NAME)";
SUPPORTED_PLATFORMS = "iphoneos iphonesimulator";
Expand All @@ -1676,7 +1676,7 @@
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
CODE_SIGN_ENTITLEMENTS = Raivo/Raivo.entitlements;
CODE_SIGN_STYLE = Automatic;
CURRENT_PROJECT_VERSION = 84;
CURRENT_PROJECT_VERSION = 85;
DEVELOPMENT_TEAM = 564B4ETY69;
INFOPLIST_FILE = "$(SRCROOT)/Raivo/Supporting/Info.plist";
INFOPLIST_KEY_LSApplicationCategoryType = "public.app-category.productivity";
Expand All @@ -1685,7 +1685,7 @@
"$(inherited)",
"@executable_path/Frameworks",
);
MARKETING_VERSION = 1.4.19;
MARKETING_VERSION = 1.4.20;
PRODUCT_NAME = "$(TARGET_NAME)";
SUPPORTED_PLATFORMS = "iphoneos iphonesimulator";
SUPPORTS_MACCATALYST = NO;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ class MainEditPasswordViewController: FormViewController {
passwordForm?.counterRow.value = password.counter
passwordForm?.timerRow.value = password.timer

if password.syncing {
if SyncerHelper.shared.getSyncer().recordsRequireSync && password.syncing {
passwordForm?.errorRow.title = "Syncing in progress, but not completed."
passwordForm?.synchronizationSection.hidden = false
passwordForm?.synchronizationSection.evaluateHidden()
Expand Down
5 changes: 0 additions & 5 deletions Raivo/Migrations/MigrationToBuild60.swift
Original file line number Diff line number Diff line change
Expand Up @@ -79,9 +79,4 @@ class MigrationToBuild60: MigrationProtocol {
// Not implemented
}

/// Migrate the Valet dependency one major version from v3 to v4.
private func migrateValetFromVersion3ToVersion4() {
// migrateObjectsFromAlwaysAccessibleValet(removeOnCompletion:)
}

}
Original file line number Diff line number Diff line change
Expand Up @@ -45,9 +45,9 @@ class CounterBasedPasswordCell: PasswordCell {
account.text = password.account.count > 0 ? "(" + password.account + ")" : ""
currentPassword.text = TokenHelper.shared.formatPassword(password.getToken())

notSyncedView.isHidden = password.synced || password.syncing
syncingView.isHidden = password.synced || !password.syncing
(!password.synced && password.syncing) ? syncingView.startAnimating() : syncingView.stopAnimating()
notSyncedView.isHidden = !SyncerHelper.shared.getSyncer().recordsRequireSync || (password.synced || password.syncing)
syncingView.isHidden = !SyncerHelper.shared.getSyncer().recordsRequireSync || (password.synced || !password.syncing)
syncingView.isHidden ? syncingView.stopAnimating() : syncingView.startAnimating()

traitCollectionDidChange(nil)
}
Expand All @@ -67,9 +67,9 @@ class CounterBasedPasswordCell: PasswordCell {

currentPassword.text = TokenHelper.shared.formatPassword(password.getToken())

notSyncedView.isHidden = password.synced || password.syncing
syncingView.isHidden = password.synced || !password.syncing
(!password.synced && password.syncing) ? syncingView.startAnimating() : syncingView.stopAnimating()
notSyncedView.isHidden = !SyncerHelper.shared.getSyncer().recordsRequireSync || (password.synced || password.syncing)
syncingView.isHidden = !SyncerHelper.shared.getSyncer().recordsRequireSync || (password.synced || !password.syncing)
syncingView.isHidden ? syncingView.stopAnimating() : syncingView.startAnimating()
}

}
Original file line number Diff line number Diff line change
Expand Up @@ -69,9 +69,9 @@ class TimeBasedPasswordCell: PasswordCell {
currentPassword.text = TokenHelper.shared.formatPassword(password.getToken())
updatePreviousPassword(password)

notSyncedView.isHidden = password.synced || password.syncing
syncingView.isHidden = password.synced || !password.syncing
(!password.synced && password.syncing) ? syncingView.startAnimating() : syncingView.stopAnimating()
notSyncedView.isHidden = !SyncerHelper.shared.getSyncer().recordsRequireSync || (password.synced || password.syncing)
syncingView.isHidden = !SyncerHelper.shared.getSyncer().recordsRequireSync || (password.synced || !password.syncing)
syncingView.isHidden ? syncingView.stopAnimating() : syncingView.startAnimating()

progressView.transform = CGAffineTransform(rotationAngle: CGFloat.pi)

Expand Down Expand Up @@ -105,9 +105,9 @@ class TimeBasedPasswordCell: PasswordCell {
currentPassword.text = TokenHelper.shared.formatPassword(password.getToken())
updatePreviousPassword(password)

notSyncedView.isHidden = password.synced || password.syncing
syncingView.isHidden = password.synced || !password.syncing
(!password.synced && password.syncing) ? syncingView.startAnimating() : syncingView.stopAnimating()
notSyncedView.isHidden = !SyncerHelper.shared.getSyncer().recordsRequireSync || (password.synced || password.syncing)
syncingView.isHidden = !SyncerHelper.shared.getSyncer().recordsRequireSync || (password.synced || !password.syncing)
syncingView.isHidden ? syncingView.stopAnimating() : syncingView.startAnimating()

let timer = TimeInterval(password.timer)
let epoch = Date().timeIntervalSince1970
Expand Down

0 comments on commit e02a346

Please sign in to comment.