Correct typo DEFAULT_SKIP_TRESH -> DEFAULT_SKIP_THRESH

Change-Id: If8f7d11301a07a7f63adfac618f07cfed9516eef
This commit is contained in:
Aidan MacDonald 2022-10-02 19:45:20 +01:00
parent 46c3d1e030
commit e03bc66594
3 changed files with 9 additions and 9 deletions

View file

@ -565,12 +565,12 @@ bool curr_cuesheet_skip(struct cuesheet *cue, int direction, unsigned long curr_
if (!(direction <= 0 && track == 0))
{
/* If skipping forward, skip to next cuesheet segment. If skipping
backward before DEFAULT_SKIP_TRESH milliseconds have elapsed, skip
backward before DEFAULT_SKIP_THRESH milliseconds have elapsed, skip
to previous cuesheet segment. If skipping backward after
DEFAULT_SKIP_TRESH seconds have elapsed, skip to the start of the
DEFAULT_SKIP_THRESH seconds have elapsed, skip to the start of the
current cuesheet segment */
if (direction == 1 ||
((curr_pos - cue->tracks[track].offset) < DEFAULT_SKIP_TRESH))
((curr_pos - cue->tracks[track].offset) < DEFAULT_SKIP_THRESH))
{
track += direction;
}

View file

@ -443,26 +443,26 @@ static void play_hop(int direction)
{
if (direction < 0)
{
prev_track(DEFAULT_SKIP_TRESH);
prev_track(DEFAULT_SKIP_THRESH);
return;
}
else if (remaining < DEFAULT_SKIP_TRESH*2)
else if (remaining < DEFAULT_SKIP_THRESH*2)
{
next_track();
return;
}
else
elapsed += (remaining - DEFAULT_SKIP_TRESH*2);
elapsed += (remaining - DEFAULT_SKIP_THRESH*2);
}
else if (!global_settings.prevent_skip &&
(!step ||
(direction > 0 && step >= remaining) ||
(direction < 0 && elapsed < DEFAULT_SKIP_TRESH)))
(direction < 0 && elapsed < DEFAULT_SKIP_THRESH)))
{ /* Do normal track skipping */
if (direction > 0)
next_track();
else if (direction < 0)
prev_track(DEFAULT_SKIP_TRESH);
prev_track(DEFAULT_SKIP_THRESH);
return;
}
else if (direction == 1 && step >= remaining)

View file

@ -36,6 +36,6 @@ bool is_wps_fading(void);
#endif /* IPOD_ACCESSORY_PROTOCOL */
/* in milliseconds */
#define DEFAULT_SKIP_TRESH 3000l
#define DEFAULT_SKIP_THRESH 3000l
#endif /* _WPS_H_ */