scaron / prettyphoto

prettyPhoto is a jQuery based lightbox clone. Not only does it support images, it also add support for videos, flash, YouTube, iFrames. It’s a full blown media lightbox. The setup is easy and quick, plus the script is compatible in every major browser.
http://www.no-margin-for-errors.com/projects/prettyPhoto-jquery-lightbox-clone/
553 stars 280 forks source link

Rough fix for _fitToViewport recursion #110

Open iVariable opened 12 years ago

iVariable commented 12 years ago

In some cases (large picture title with show_title:true, small window size, long picture, etc) prettyPhoto falls into infinite recursion in _fitToViewport function. This is a quickfix for such situations.

Of course it'll be much better to detect such cases and fix them somehow, (for example - change the show_title template to absolute positioning) but it's a matter of design/markup and I'm not skill-enough for this :)

iVariable commented 12 years ago

@scaron ping