partially watched video/song/recorded tv show file text color + remember cursor in folders (1 Viewer)

CyberSimian

Test Group
  • Team MediaPortal
  • June 10, 2013
    1,999
    1,234
    Southampton
    United Kingdom United Kingdom
    Country flag
    <playingColor min="5" max="90">ff000000</playingColor>
    How does this interact with the existing <playedColor> tag with the existing played-threshhold defined in "MP Config"? I am not against an enhancement in this area, provided that:

    (1) Existing skins that are not changed will continue to work as intended by the skin author.

    (2) We do not end up with two schemes that are disjoint (i.e. mutually exclusive). I would prefer to see a scheme where the enhancement is a superset of the existing support (i.e. the existing support is simply a subset of the new support). Does your scheme provide this?

    Please describe clearly how the existing and new schemes relate to each other.

    -- from CyberSimian in the UK
     

    ajs

    Development Group
  • Team MediaPortal
  • February 29, 2008
    11,880
    6,725
    Kyiv
    Ukraine Ukraine
    Country flag
    How does this interact with the existing <playedColor> tag with the existing played-threshhold defined in "MP Config"? I am not against an enhancement in this area, provided that:
    If PlayingColor not defined then used PlayColor ... Those. Nothing should change ...
    Existing skins that are not changed will continue to work as intended by the skin author.
    Yes
    We do not end up with two schemes that are disjoint (i.e. mutually exclusive). I would prefer to see a scheme where the enhancement is a superset of the existing support (i.e. the existing support is simply a subset of the new support). Does your scheme provide this?
    I do not quite understand what it was about.
     

    CyberSimian

    Test Group
  • Team MediaPortal
  • June 10, 2013
    1,999
    1,234
    Southampton
    United Kingdom United Kingdom
    Country flag
    I think that this proposed change is a worthwhile enhancement, and I would probably use it myself. However, I am not so happy with the proposed implementation.

    Suggested design
    In my view we should offer this enhancement in a manner that is as consistent as possible with the existing support. We currently have a setting in "MP Config" that allows the user to specify the threshhold that separates unwatched recordings and videos from watched recordings and videos. The consistent approach is to add another setting to "MP Config" to separate unwatched from partly-watched. So "MP Config" might have something like this:

    Played time percentage needed to mark the video as partly watched (0-100%)
    Played time percentage needed to mark the video as fully watched (0-100%)


    In the skin, we introduce the new tag suggested by @ajs , namely <playingColor>, but without any attributes (no "min" or "max"). Then the logic that the skin engine would use for selecting the colour would be:
    Code:
    if (played_percent >= fully_watched_threshhold)
      color = <playedColor>;
    else if (played_percent >= partly_watched_threshhold)
      color = <playingColor>;
    else
      color = <textcolor>;
    Note that if partly_watched_threshhold >= fully_watched_threshhold, <playingColor> is never used.

    Compatibility
    In previous releases, if the played percent was less than the fully-watched threshhold, the item was displayed with <textcolor>. Skins which are moribund (or not updated with this change) will lack the <playingColor> tag, so defaults need to be such that there is no change in the appearance of those skins.

    No change in the appearance of moribund skins can be achieved by setting partly-watched threshhold equal to fully-watched threshhold in "MediaPortal.xml" when the user installs the new version of MP (this should be done automatically as part of the install process).

    In the window xml file, a control can omit tags where the default value is wanted. If a tag is omitted, the value is taken from the value specified by the default style in "references.xml". If the tag is also omitted from the style in "references.xml", the value specified by the hard-coded built-in defaults in the skin engine is used. A suitable hard-coded default needs to be chosen for <playingColor> for the skin engine. This should probably follow the existing convention used for the other numerous <xxxColor> tags.

    Where do we go from here
    If the modified DLL that @ajs has provided to the original poster works as intended, there is no reason why the original poster shouldn't continue using it until the next release (MP 1.21). However, I think that the implementation should be reworked as outlined above, before being made available in an MP build.

    -- from CyberSimian in the UK
     

    ajs

    Development Group
  • Team MediaPortal
  • February 29, 2008
    11,880
    6,725
    Kyiv
    Ukraine Ukraine
    Country flag
    settings are many, and can be located in different places. but. the facade is one and it's in the kernel and he does not know what module it called and what setting to read. I'm against setting up a lot of settings.

    --
    WBR, ajs :):whistle::coffee:
     

    ajs

    Development Group
  • Team MediaPortal
  • February 29, 2008
    11,880
    6,725
    Kyiv
    Ukraine Ukraine
    Country flag
    Then the logic that the skin engine would use for selecting the colour would be:
    C#:
        [XMLSkinElement("playingColor")] protected long _playingColor = -1;
        [XMLSkin("playingColor", "min")] protected int _playingPercentageMin = 5;
        [XMLSkin("playingColor", "max")] protected int _playingPercentageMax = 95;
    C#:
          if (_playingColor == -1)
          {
            _playingColor = _playedColor;
          }
    C#:
              // override text color if item is currently playing
              if (item.HasProgressBar && item.ProgressBarPercentage >= _playingPercentageMin && item.ProgressBarPercentage <= _playingPercentageMax)
              {
                color = _playingColor;
              }
     

    mathem

    Portal Pro
    May 20, 2018
    55
    16
    Germany Germany
    So the news are that I dont know which file to change :)
    btw, refresh rate broken again :)

    thx for the work!
    @ajs
     
    Last edited:

    Users Who Are Viewing This Thread (Users: 0, Guests: 1)

    OP Similar threads Forum Replies Date
    SpudR Custom filter for partially watched movies Moving Pictures 5
    Stubbie Recording TV series by partial title MediaPortal 1 Talk 1
    g0rsq Info box randomly popping up when watching TV or other video MediaPortal 2 Newcomers Forum 1
    SpudR Forum Duplicate lines in 'Watched' Website/Forum/Wiki Feedback 2
    TLD Can not watch tv from remote clients Television (MyTV frontend and TV-Server) 19
    R Visual status of watched TV programs MediaPortal 1 Talk 2
    M How to Watch my videos from my Media Portal to My TV without TV Tuner Newcomers Forum 1
    limpwhizkid 1.22.0 Stutter and or artifact problem when recording and watching the same live tv channel 1.22 2
    K sudden complication watching recorded TV Newcomers Forum 6
    R [solved] Watching a record during recording stops sometimes 2.2 Archive 30
    Scheibes Automatischer Serienimport fehlerhaft (Share Watch) Allgemeines Support- und Diskussionsforum 18
    doskabouter Black screen while watching some iptv streams General Support 2
    A Flag Mover: backup and restore watched flags Plugin Development 33
    zunixnuz TV recording is watched state 1.20 2
    A Plugin to transfer watched states between two MP2 installations Archive 47
    CyberSimian MP 1.20: Watched percent sometimes incorrect MediaPortal 1 47
    Alberto83 [no Bug] Watched status not retained when rewatching an episode and stopping. Archive 49
    doskabouter Notification mail for new posts on watched threads Website/Forum/Wiki Feedback 5
    M Recorded TV - Watched status is not updated 1.20 Pre Release 11
    N Can't Watch DVB-T2 Channels General Support 44
    mp2-ulrich [solved] MP2 W10 watching tv not possible General 3
    P Multiple clients - share resume/watched data General 1
    S Watched flag, strange behaviour My Films 0
    C Netflix My List & Continue Watching Blank OnlineVideos 4
    W Blu-ray chapter popups when watching from "Menu" - any way to disable them? watch/edit Videos 1
    Similar threads

























    Top Bottom