Bugzilla – Bug 5766
Slim::Web::HTTP::fixHttpPath doesn't look for content in the right order
Last modified: 2009-09-08 09:19:03 UTC
assigning to Michael for comment. I can try tackling the fix, but not today. There is a white-on-transparent html/images/cover.png in Default/ now, and a gray-on-transparent html/images/cover.png in EN/ The EN image is necessary for any skin that employs a white background (Handheld, Classic, Touch, Nokia770), because the white-on-transparent appears blank in these skins. If a resized request is sent for cover.png, for example http://localhost:9000/Classic/html/images/cover_50x50.png I would expect it to look in Classic/html/images followed by EN/html/images, but that's not how it works. Instead it looks through all skin folders until it finds a match, and uses the first match it finds. It's finding Default first, and we're getting the "blank" image in the skin. The data for cover.png is grabbed by Slim::Web::HTTP::getStaticContent('html/images/cover.png');, which in turn calls Slim::Web::HTTP::fixHtttpPath. fixHttpPath grabs all of the skindirs with my $skindirs = $template->context()->{'CONFIG'}->{'INCLUDE_PATH'}; what isn't clear to me here is how to sort $skindirs appropriately. Throw in the added complexity that some skins (e.g., Touch) are supposed to have an inheritance from other skins first. So, in the case of Touch, getStaticContent should try to find Touch/html/images/cover.png first, then Nokia770/html/images/cover.png, then EN/html/images/cover.png (and then, IMHO, give up and maybe return some kind of uber-default 1x1 image).
I should also note that if I copy EN's cover.png to the current skin's directory, fixHttpPath still hits on Default's cover.png first and not the current skin's.
Ben/Michael: how important is this for 7.0? Please target.
IMHO, this seems like a bug worth fixing for 7.0. Setting target as such, but I'm open-minded to targeting it for later.
Created attachment 2414 [details] pass along those params After a lot of backtracing I've come up with this rather simple patch: keep track of our params, or the skinOverride is lost. Please give it a try.
submitted in change 14778
This bug is being closed since it was resolved for a version which is now released! Please download the new version of SqueezeCenter (formerly SlimServer) at http://www.slimdevices.com/su_downloads.html If you are still seeing this bug, please re-open it and we will consider it for a future release.