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

In some cases, clicking on thumbnail of currently displayed image removes image #20

Open
mallorn opened this issue May 31, 2012 · 2 comments

Comments

@mallorn
Copy link

mallorn commented May 31, 2012

In some configurations, clicking on a thumbnail for the already displayed image will remove the image, leaving only the background.

For example, in the demo page at

http://www.spaceforaname.com/galleryview/demo-position.html

If you click on one of the thumbnails, then click on it again you are left with a black background and no image.

@mallorn
Copy link
Author

mallorn commented May 31, 2012

No idea how to use github to post diffs. So here's an old-school diff.

*** jquery.galleryview-3.0-dev-original.js      2012-05-31 16:01:37.000000000 -0500
--- jquery.galleryview-3.0-dev.js       2012-05-31 16:02:20.000000000 -0500
***************
*** 546,551 ****
--- 546,552 ----
  
                showItem: function(i) {
                        if(isNaN(i)) { return; }
+                       if(this.iterator == i) { return; }
                        if(!this.opts.show_filmstrip) { i = i % this.numImages; }
  
                        var self = this,


@mallorn
Copy link
Author

mallorn commented Jun 7, 2012

This patch only fixes the issue if the filmstrip is <= the max number of displayed thumbnails. If the filmstrip rotates images in and out the problem is still there. Working on it...

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

1 participant