Buttons 1/3 don't change the time scale correctly in Graphical EPG

Issue #442 resolved
prl created an issue

Using the number buttons 1/3 to adjust the time window size in the graphical EPG doesn't work properly. You can't decrease it below 1 hour less than your setting value, and you can't increase it above 1 hour more than your setting value, and the increase/decrease is always from the setting value, not from its previous value. It's supposed to be able to range between 1 and 5 hours.

It's also more volatile than it's intended to be: changed values don't survive exiting and re-entering the EPG, and the code is written with that intention.

The tests to limit the range of the changes using 1/3 are also incorrect if the user setting of EPG MENU>Time scale isn't evenly divisible by 60.

I have a fix for this.

Replication steps

Enter the EPG, set MENU>Time scale to 180 min, if it's not already that value, save setting and return to EPG.

Press 1 on the remote; the time scale reduces to 120 minutes. Press 1 again, the time scale doesn't change. Press 3 on the remote, the time scale changes to 240 min, not 180 min. The reverse also happens. Enter the EPG, press 3 for 240 min, then 1 gives 120 min, not 180 min.

Comments (1)

  1. Peter Urbanec

    Fix bug #442: Buttons 1/3 don't change the time scale correctly in Graphical EPG

    [EpgSelection] In EpgSelection.keyNumberGlobal():

    Save changes to config.epgselection.graph_prevtimeperiod as the expected string, rather than as an integer, so that the changes are accepted by the config variable,

    Use .value = instead of .setValue() when changing config.epgselection.graph_prevtimeperiod.

    Modify the tests on timeperiod so that pressing 1/3 doesn't take timeperiod out of the allowed range of config.epgselection.graph_prevtimeperiod.

    → <<cset b566a82b45f4>>

  2. Log in to comment