INTERACT FORUM

Please login or register.

Login with username, password and session length
Advanced search  
Pages: [1]   Go Down

Author Topic: Unexpected value returned by TrackInfo_Insert(Rating) when rating is blank  (Read 342 times)

EnglishTiger

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 969

I thought I'd have a go at updating my TrackInfo Plugins to include the new tags that have been added since MC28 saw the light of day and add in handling of the Rating10 field/tag.

Like most TrackInfo Plugin Authors I was using images for the rating with a tooltip to display the numeric value of that rating.
However I thought I'd reduce the amount of code needed to display both the Rating and Rating10 fields/tags by displaying them as Numeric Values, but only if those fields/tags contained values.

When it comes to the Rating10 field/tag, which is set up as integer with an edit type of 10 stars and only accepts the values 1 thru 10, the field/tag was only being displayed if it contained a value (just like any other filed/tag that is defined as integer and empty)

But when it came to the Rating field/tag if it contained data the number of stars was displayed but for tracks that I'd deliberately removed the rating from not only was the field/tag name being displayed but also the phrase "? stars".

After spotting that, I got a bit curious and had a look at the MC supplied "Audio -- Task -- Not rated" smartlist and noticed that it was looking for files/tracks where the Rating is 0, the default value for an empty integer field/tag.

I then decided to remove the Rating from a track that had already been played and looked in the Tag Window  to see what was being reported in the General Section the RatingTag/Field was present but showing no value/image and there was no mention of the Rating Tag in the Tag Dump Section.
Logged
Win NUC - VENOEN 11Th NUC Mini PC Core i7 1165G7,Dual HDMI 2.0+Mini DP,Windows 11 Mini Desktop Computer,Thunderbolt 4.0,1 Lan, USB-C,Wifi,Bluetooth 5.0,32GB RAM Toshiba MQ04ABF100 ‎500Gb 5400 RPM ‎eSATA HD, Gigabyte GP-GSM2NE3512GNTD 1Tb NVMe SSD, Samsung 870 QVO 8 TB SATA 2.5 Inch SSD (MZ-77Q8T0) in Sabrent Ultra Slim USB 3.0 to 2.5-Inch SATA External Aluminium Hard Drive Enclosure (EC-UK30)

Apple 2020 Mac mini M1 Chip (8GB RAM, 512GB SSD)
Sabrent Thunderbolt 3 to Dual NVMe M.2 SSD Tool-Free Enclosure with Sabrent 2TB Rocket NVMe PCIe M.2 2280 High Performance SSD + Crucial P3 Plus 4TB M.2 PCIe

ET Skins & TrackInfo Plugins - https://englishtiger.uk/index.html
Pages: [1]   Go Up