Skip to content

PasswordEntryRow: Do not handle password changed events during initialization (fixes #237)

Sebastian Spaeth requested to merge spaetz/PasswordSafe:issue237 into master

The problem is that during the initial popularization of the password entry field in (self._password_value_entry.props.text = pwd_value) the password entry field is changed and the callback _on_password_value_changed is invoked.

This callback assumes that the password was changed, marks the database as dirty and thereby invokes the save confirmation dialog when we quit.

So we need to do nothing in the cb during the initial initialization. Achieving this by manually connecting the "changed" signal to our callback function AFTER we populated the field. The Gtk.Template.Callback was doing that too early in the super().init phase.

Fixes: https://gitlab.gnome.org/World/PasswordSafe/-/issues/237

Edited by Sebastian Spaeth

Merge request reports