Skip to content

Commit

Permalink
Reorder timer definition (#224)
Browse files Browse the repository at this point in the history
Kodi core adds the first defined timer to the setting types even when it fails attribute checks.  Backport from PR 223



Co-authored-by: Alfonso Cachero <[email protected]>
Translate-URL: https://kodi.weblate.cloud/projects/kodi-add-ons-pvr-clients/pvr-nextpvr/es_es/
Translation: Kodi add-ons: PVR clients/pvr.nextpvr

Co-authored-by: Alfonso Cachero <[email protected]>

Co-authored-by: Weblate (bot) <[email protected]>
Co-authored-by: Alfonso Cachero <[email protected]>
  • Loading branch information
3 people authored Dec 8, 2022
1 parent d80db32 commit 4fecb1e
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 10 deletions.
2 changes: 1 addition & 1 deletion pvr.nextpvr/addon.xml.in
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<addon
id="pvr.nextpvr"
version="19.0.5"
version="19.0.6"
name="NextPVR PVR Client"
provider-name="Graeme Blackley">
<requires>@ADDON_DEPENDS@
Expand Down
3 changes: 3 additions & 0 deletions pvr.nextpvr/changelog.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
v19.0.6
- Reorder timers so valid entry timer is default

v19.0.5
- Backport advanced recording title search from PR 220

Expand Down
18 changes: 9 additions & 9 deletions src/Timers.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -486,26 +486,26 @@ PVR_ERROR Timers::GetTimerTypes(std::vector<kodi::addon::PVRTimerType>& types)
PVR_TIMER_TYPE_SUPPORTS_START_END_MARGIN;

/* Timer types definition.*/
TimerType* t = t = new TimerType(
/* One-shot manual (time and channel based) */
TimerType* t = new TimerType(
/* Type id. */
TIMER_ONCE_EPG,
TIMER_ONCE_MANUAL,
/* Attributes. */
TIMER_EPG_ATTRIBS,
TIMER_MANUAL_ATTRIBS,
/* Description. */
kodi::GetLocalizedString(MSG_ONETIME_GUIDE), // "One time (guide)",
kodi::GetLocalizedString(MSG_ONETIME_MANUAL), // "One time (manual)",
/* Values definitions for attributes. */
recordingLimitValues, m_defaultLimit, showTypeValues, m_defaultShowType, recordingGroupValues, 0);
types.emplace_back(*t);
delete t;

t =new TimerType(
/* One-shot manual (time and channel based) */
t = new TimerType(
/* Type id. */
TIMER_ONCE_MANUAL,
TIMER_ONCE_EPG,
/* Attributes. */
TIMER_MANUAL_ATTRIBS,
TIMER_EPG_ATTRIBS,
/* Description. */
kodi::GetLocalizedString(MSG_ONETIME_MANUAL), // "One time (manual)",
kodi::GetLocalizedString(MSG_ONETIME_GUIDE), // "One time (guide)",
/* Values definitions for attributes. */
recordingLimitValues, m_defaultLimit, showTypeValues, m_defaultShowType, recordingGroupValues, 0);
types.emplace_back(*t);
Expand Down

0 comments on commit 4fecb1e

Please sign in to comment.