partially watched video/song/recorded tv show file text color + remember cursor in folders | Page 3

Discussion in 'other features (of release or svn versions)' started by mathem, August 6, 2018.

  1. CyberSimian
    • Team MediaPortal

    CyberSimian Test Group

    Joined:
    June 10, 2013
    Messages:
    1,181
    Likes Received:
    245
    Gender:
    Male
    Location:
    Southampton
    Ratings:
    +572 / 3
    Home Country:
    United Kingdom United Kingdom
    Show System Specs
    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


     
    • Like Like x 1
  2. Google AdSense Guest Advertisement



    to hide all adverts.
  3. ajs
    • Team MediaPortal

    ajs Development Group

    Joined:
    February 29, 2008
    Messages:
    7,781
    Likes Received:
    2,048
    Gender:
    Male
    Occupation:
    IT
    Location:
    Kyiv
    Ratings:
    +3,851 / 29
    Home Country:
    Ukraine Ukraine
    Show System Specs
    If PlayingColor not defined then used PlayColor ... Those. Nothing should change ...
    Yes
    I do not quite understand what it was about.
     
  4. ajs
    • Team MediaPortal

    ajs Development Group

    Joined:
    February 29, 2008
    Messages:
    7,781
    Likes Received:
    2,048
    Gender:
    Male
    Occupation:
    IT
    Location:
    Kyiv
    Ratings:
    +3,851 / 29
    Home Country:
    Ukraine Ukraine
    Show System Specs
    Any news? :):whistle::coffee:
     
  5. CyberSimian
    • Team MediaPortal

    CyberSimian Test Group

    Joined:
    June 10, 2013
    Messages:
    1,181
    Likes Received:
    245
    Gender:
    Male
    Location:
    Southampton
    Ratings:
    +572 / 3
    Home Country:
    United Kingdom United Kingdom
    Show System Specs
    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 (Text):
    1. if (played_percent >= fully_watched_threshhold)
    2.   color = <playedColor>;
    3. else if (played_percent >= partly_watched_threshhold)
    4.   color = <playingColor>;
    5. else
    6.   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
     
  6. ajs
    • Team MediaPortal

    ajs Development Group

    Joined:
    February 29, 2008
    Messages:
    7,781
    Likes Received:
    2,048
    Gender:
    Male
    Occupation:
    IT
    Location:
    Kyiv
    Ratings:
    +3,851 / 29
    Home Country:
    Ukraine Ukraine
    Show System Specs
    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:
     
  7. ajs
    • Team MediaPortal

    ajs Development Group

    Joined:
    February 29, 2008
    Messages:
    7,781
    Likes Received:
    2,048
    Gender:
    Male
    Occupation:
    IT
    Location:
    Kyiv
    Ratings:
    +3,851 / 29
    Home Country:
    Ukraine Ukraine
    Show System Specs
    Code (C#):
    1.     [XMLSkinElement("playingColor")] protected long _playingColor = -1;
    2.     [XMLSkin("playingColor", "min")] protected int _playingPercentageMin = 5;
    3.     [XMLSkin("playingColor", "max")] protected int _playingPercentageMax = 95;
    Code (C#):
    1.       if (_playingColor == -1)
    2.       {
    3.         _playingColor = _playedColor;
    4.       }
    Code (C#):
    1.           // override text color if item is currently playing
    2.           if (item.HasProgressBar && item.ProgressBarPercentage >= _playingPercentageMin && item.ProgressBarPercentage <= _playingPercentageMax)
    3.           {
    4.             color = _playingColor;
    5.           }
     
  8. ajs
    • Team MediaPortal

    ajs Development Group

    Joined:
    February 29, 2008
    Messages:
    7,781
    Likes Received:
    2,048
    Gender:
    Male
    Occupation:
    IT
    Location:
    Kyiv
    Ratings:
    +3,851 / 29
    Home Country:
    Ukraine Ukraine
    Show System Specs
    The Core does not know anything about this. And there is no such information for negais.
     
  9. ajs
    • Team MediaPortal

    ajs Development Group

    Joined:
    February 29, 2008
    Messages:
    7,781
    Likes Received:
    2,048
    Gender:
    Male
    Occupation:
    IT
    Location:
    Kyiv
    Ratings:
    +3,851 / 29
    Home Country:
    Ukraine Ukraine
    Show System Specs
    Any news?
     
Loading...

Users Viewing Thread (Users: 0, Guests: 0)

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice
  • About The Project

    The vision of the MediaPortal project is to create a free open source media centre application, which supports all advanced media centre functions, and is accessible to all Windows users.

    In reaching this goal we are working every day to make sure our software is one of the best.

             

  • Support MediaPortal!

    The team works very hard to make sure the community is running the best HTPC-software. We give away MediaPortal for free but hosting and software is not for us.

    Care to support our work with a few bucks? We'd really appreciate it!