[fixed] EPG - Inconsistent behaviour when scrolling with page up/down (1 Viewer)

glenn 1990

Portal Pro
July 1, 2010
247
36
Home Country
Belgium Belgium
Small adjustment, delete the + 1 (marked red).

Code:
        private void OnPageUp()
        {
            int Steps;
            if (_singleChannelView)
                Steps = _channelCount; // all available rows
            else
            {
                if (_guideContinuousScroll)
                {
                    Steps = _channelCount; // all available rows
                }
                else
                {
                    // If we're on the first channel in the guide then allow one step to get back to the end of the guide.
                    if (_channelOffset == 0 && _cursorX == 0)
                    {
                        Steps = 1;
                    }
                    else
                    {
                        // only number of additional avail channels
                        Steps = Math.Min(_channelOffset + _cursorX [COLOR="Red"][B]+ 1[/B][/COLOR], _channelCount);
                    }
                }
            }

            UnFocus();
            for (int i = 0; i < Steps; ++i)
            {
                OnUp(true, true);
            }
            Correct();
            Update(false);
            SetFocus();
        }
 

Wbunaarf

Portal Pro
December 9, 2005
534
103
Sweden
Home Country
Sweden Sweden
Hi,

I don't think this is in mantis yet, and I don't want it forgotten. Looking at the code provided, I suspect it will be straightforward, to fix, but needs to be done in TV and radio EPG.

Should I try the different cases more (channel or program highlighted, channel 1-5 or >6) any further, or do you have enough information for now? Without having tested it more thoroughly, I have the feeling that for me it doesn't matter what's highlighted and only 6 and 7 stops on 1.
 
Last edited:

glenn 1990

Portal Pro
July 1, 2010
247
36
Home Country
Belgium Belgium
I'm running the 4TR tuner, not mp tv server. So it's difficult to create a patch for it.
Just replace OnPageUp() with this and it should work.

Code:
        private void OnPageUp()
        {
            int Steps;
            if (_singleChannelView)
                Steps = _channelCount; // all available rows
            else
            {
                if (_guideContinuousScroll)
                {
                    Steps = _channelCount; // all available rows
                }
                else
                {
                    // If we're on the first channel in the guide then allow one step to get back to the end of the guide.
                    if (_channelOffset == 0 && _cursorX == 0)
                    {
                        Steps = 1;
                    }
                    else
                    {
                        // only number of additional avail channels
                        Steps = Math.Min(_channelOffset + _cursorX /*+ 1*/, _channelCount);
                    }
                }
            }

            UnFocus();
            for (int i = 0; i < Steps; ++i)
            {
                OnUp(true, true);
            }
            Correct();
            Update(false);
            SetFocus();
        }
 

elliottmc

Retired Team Member
  • Premium Supporter
  • August 7, 2005
    14,927
    6,061
    Cardiff, UK
    Home Country
    United Kingdom United Kingdom
    Hi,

    Thanks. I made this change in TVGuideBase.cs and RadioGuideBase.cs, and can no-longer reproduce the problem. I guess it needs someone else to check.

    I am reluctant to post a binary here for testing, as it is based on latest SVN with other fixes, and has the wrong version number.

    Mark
     

    Seidelin

    Retired Team Member
  • Premium Supporter
  • August 14, 2006
    1,755
    652
    Kgs. Lyngby
    Home Country
    Denmark Denmark
    I tested the modified code, and it works for me as well.
    Patch attached if anyone else wants to test.
     

    Attachments

    • PageUp.patch
      2.3 KB

    Seidelin

    Retired Team Member
  • Premium Supporter
  • August 14, 2006
    1,755
    652
    Kgs. Lyngby
    Home Country
    Denmark Denmark
    It would be nice if someone could confirm this different issue, now we are discussing EPG issues:

    0. Configuration. TVClient -> Make sure loop guide seamlessly is not ticked.
    1. Go to TV guide.
    2. Scroll to one of the last channels in EPG (one of the last 8 channels if using default skins).
    3. Click the channel to start watching.
    4. Click Esc (back).
    5. Observe that the guide is looped. The first few channels are shown in bottom of guide (bug). This should not happen as seamless is OFF. When scrolling down it stops at the lowest channel (which is channel no. 2 in my testing) and waits for wrap around timeout to expire.
     

    elliottmc

    Retired Team Member
  • Premium Supporter
  • August 7, 2005
    14,927
    6,061
    Cardiff, UK
    Home Country
    United Kingdom United Kingdom
    It would be nice if someone could confirm this different issue, now we are discussing EPG issues:

    0. Configuration. TVClient -> Make sure loop guide seamlessly is not ticked.
    1. Go to TV guide.
    2. Scroll to one of the last channels in EPG (one of the last 8 channels if using default skins).
    3. Click the channel to start watching.
    4. Click Esc (back).
    5. Observe that the guide is looped. The first few channels are shown in bottom of guide (bug). This should not happen as seamless is OFF. When scrolling down it stops at the lowest channel (which is channel no. 2 in my testing) and waits for wrap around timeout to expire.

    Yes, confirmed as reported in the internal team forum.

    Mark
     

    elliottmc

    Retired Team Member
  • Premium Supporter
  • August 7, 2005
    14,927
    6,061
    Cardiff, UK
    Home Country
    United Kingdom United Kingdom
    I tested the modified code, and it works for me as well.
    Patch attached if anyone else wants to test.

    Since I have already tested this modification here, and you have now tested it, I guess we can consider it tested.

    :)

    Mark
     

    glenn 1990

    Portal Pro
    July 1, 2010
    247
    36
    Home Country
    Belgium Belgium
    There are even more bugs (in the 4TR guide anyway).
    1) Try navigating with (page) up/down in a channelgroup with less channels than the rows in the guide (10 for default wide If I'm right).
    2) Index can be out of range when switching from a larger to a smaller channel group.
     

    Users who are viewing this thread

    Top Bottom