jaysalvat/vegas — pull request #48 by GiancarloGomez (2013-12-26 22:37:39+00:00)
Title: Apply to Element and Slideshow initial settings

Hello,

First off, this is an amazing plugin, thank you so much for creating and sharing. This is the second time I use it and I needed to have the image within an element rather than the entire body so I have made some edits and thought you would like to check out and if you like, maybe even merge into your master. Also, on this push I added a $.vegas.defaults.init variable that stores the initial settings called when someone sets up a slideshow. The reason for this was, for example if I set up a slideshow with valign top (that was not being passed in - I applied a fix for that as well) and then I called next(), jump() or previous() all my original settings would not stick. So if my first slide was aligned to the top the one called by me executing the next() call would then get the default valign center.

To apply to an element you only have to pass the id value to a new setting called container. By default this is set to 'body'.