Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

White background with no image on Chrome + Windows #115

Closed
costaprofunda opened this issue Apr 29, 2016 · 6 comments
Closed

White background with no image on Chrome + Windows #115

costaprofunda opened this issue Apr 29, 2016 · 6 comments

Comments

@costaprofunda
Copy link

costaprofunda commented Apr 29, 2016

Hi,
today I met the following problem:
there were no images, white background only for Chrome Windows remote server. Not every time, but in about 50% of reloading cases. Works for localhost, Chrome Mac and Firefox (Mac, Win).
In fact the image was loaded but the opacity was 0. The plugin was initiated, play process started, but no 'walk' triggered. After debugging vegas.js I found that the problem was in str. 509:
img.onload = go;.
I googled about weird behavior of onload method, and the decision to replace this string with:
go();
solved my problem.
Maybe there is a more elegant way to fix it.

@jaysalvat
Copy link
Owner

Hello,
Never had any complaint about this
Does this issue occurs on vegas website or just on yours?

Watch out, replacing ìmg.onload = go;bygo()` launch the slideshow even if the image is not loaded. This is not the expected behavior.

@costaprofunda
Copy link
Author

Hi,
the issue occurs on my website. I've deployed the version with initial code (img.onload = go). Check with Windows Chrome.

@Miguel-gh96
Copy link

Miguel-gh96 commented May 3, 2016

I had same problem and I have solved the same way. ( img.onload = go() )

@jaysalvat
Copy link
Owner

Thanks @costaprofunda but sorry, I have no window and it works perfectly on Chrome for Mac.

Please try to invert these lines.

img.onload = go;
img.src = src;

@costaprofunda
Copy link
Author

Tried: didn't solve the problem unfortunately.

@costaprofunda
Copy link
Author

Ok, seems I found the solution with onload.
According to latest comment here I've initialized img variable at str. 346.
img = new Image();
and have removed img init at str. 431.
Everything works.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants