Closed Bug 1055826 Opened 10 years ago Closed 10 years ago

Suggested sites in distribution files load images from incorrect location

Categories

(Firefox for Android Graveyard :: General, defect)

x86
macOS
defect
Not set
normal

Tracking

(Not tracked)

RESOLVED INVALID

People

(Reporter: toonetown, Unassigned)

References

Details

User Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_9_4) AppleWebKit/537.78.2 (KHTML, like Gecko) Version/7.0.6 Safari/537.78.2

Steps to reproduce:

Created a set of distribution files, placing suggested sites resources within "distribution/suggestedsites/res/XXX/smile.png" as described at https://wiki.mozilla.org/Mobile/Distribution_Files


Actual results:

The default icon was displayed, instead of the desired image.  In logcat, multiple lines stating:

D/GeckoImageLoader( 3637): Trying to load image from distribution res/xhdpi/smile.png
D/GeckoDistribution( 3637): Getting file from distribution.
E/GeckoDistribution( 3637): Distribution directory exists, but no file named res/xhdpi/smile.png
D/GeckoImageLoader( 3637): Trying to load image from distribution res/xxhdpi/smile.png
D/GeckoDistribution( 3637): Getting file from distribution.
E/GeckoDistribution( 3637): Distribution directory exists, but no file named res/xxhdpi/smile.png
D/GeckoImageLoader( 3637): Trying to load image from distribution res/mdpi/smile.png
D/GeckoDistribution( 3637): Getting file from distribution.
E/GeckoDistribution( 3637): Distribution directory exists, but no file named res/mdpi/smile.png
 


Expected results:

The image should have been loaded from distribution/suggestedsites/res - but was trying to load from distribution/res (as a peer to suggestedsites).  Moving the res directory up a level within my distribution loaded correctly.

In speaking with margaret on IRC, it was decided this was a bug - and not just an error in documentation.
Blocks: 1012462
Duh!  I am stupid STUPID!

I had set the url in my json file as:
      imageurl: "gecko.distribution://res/smile",

Instead of:
      imageurl: "gecko.distribution://suggestedsites/res/smile",

Closing this bug
Status: UNCONFIRMED → RESOLVED
Closed: 10 years ago
Resolution: --- → INVALID
Product: Firefox for Android → Firefox for Android Graveyard
You need to log in before you can comment on or make changes to this bug.