Keep remote form open during manual entry
ci / lint-test (push) Successful in 1m11s
ci / build (push) Successful in 2m32s

This commit is contained in:
Joe Julian
2026-04-06 07:13:12 -07:00
parent 0c6d707325
commit c361ec5ba3
2 changed files with 36 additions and 2 deletions
+7 -1
View File
@@ -432,6 +432,7 @@ type ui struct {
syncDialogOpen bool
syncMenuOpen bool
mainMenuOpen bool
selectedRemoteConnection bool
securityDialogOpen bool
remotePrefsDialogOpen bool
showSyncPassword bool
@@ -1779,7 +1780,7 @@ func (u *ui) hasSelectedLifecycleTarget() bool {
}
func (u *ui) hasSelectedRemoteTarget() bool {
return strings.TrimSpace(u.remoteBaseURL.Text()) != "" && strings.TrimSpace(u.remotePath.Text()) != ""
return u.selectedRemoteConnection
}
func (u *ui) latestRecentVault() (string, time.Time) {
@@ -1830,6 +1831,7 @@ func (u *ui) switchToLifecycleSelection(mode string) {
u.remoteUsername.SetText("")
u.remotePassword.SetText("")
u.rememberRemoteAuth.Value = false
u.selectedRemoteConnection = false
default:
u.vaultPath.SetText("")
u.remoteBaseURL.SetText("")
@@ -1837,6 +1839,7 @@ func (u *ui) switchToLifecycleSelection(mode string) {
u.remoteUsername.SetText("")
u.remotePassword.SetText("")
u.rememberRemoteAuth.Value = false
u.selectedRemoteConnection = false
}
u.requestMasterPassFocus = u.hasSelectedLifecycleTarget()
u.filter()
@@ -1885,6 +1888,7 @@ func (u *ui) applyRecentRemoteRecord(record recentRemoteRecord) {
u.remotePassword.SetText(record.Password)
u.remotePassword.Mask = '•'
u.rememberRemoteAuth.Value = strings.TrimSpace(record.Username) != "" || record.Password != ""
u.selectedRemoteConnection = true
}
func (u *ui) remotePreferencesCurrentSummary() string {
@@ -3050,6 +3054,7 @@ func (u *ui) layout(gtx layout.Context) layout.Dimensions {
continue
}
u.lifecycleMode = "remote"
u.selectedRemoteConnection = false
u.requestMasterPassFocus = true
}
for u.toggleLifecycleAdvanced.Clicked(gtx) {
@@ -3247,6 +3252,7 @@ func (u *ui) layout(gtx layout.Context) layout.Dimensions {
u.switchToLifecycleSelection("remote")
continue
}
u.selectedRemoteConnection = false
u.remoteBaseURL.SetText("")
u.remotePath.SetText("")
u.remoteUsername.SetText("")