Skip to content

Fix issue where editing an alarm would blank out the name and repeat days fields.

Howdy, This merge request fixes an issue where editing an existing alarm would cause the name, and repeat fields to be blanked. This should now allow them to be retained

Fixes Issue #30

Root Problem: When setting up the edit screen in the set_from_alarm function, the setting of the fields is triggering the 'notifies' of the corresponding gui object being messed with. Each notify used is set to apply all the current values to the alarm, and as they are null, it nulls the unset ones out.

I'm not sure this merge request is a good solution, as the real issue appears to be that it shouldn't be setting all of the alarm values each time a field updates (perhaps just the one that's modified)? This action is particularly concerning as the dialog with done and cancel buttons inplies that changes are not applied if one hits cancelled, when in fact they are updated as soon as a field changes.

I think that either the class should be changed to create a 'local' alarm that it sets all of these values to and, if done is clicked then apply them. Or the cancel button should be removed when the class is in edit mode. As this is not my project, and is my first merge request; I should get input before making any changes in that area.

Edited by Steve Stevens

Merge request reports