Closed richardscarrott closed 11 years ago
This would also be useful when a horizontal carousel contains images with different widths.
Actually, for some time, I did not notice that my carousel was not working properly with images with varying width. It was only when I added a very narrow first element that the carousel stopped working. Looking at the _setRunnerWidth() I understand why.
Modifying _getItemDim() to return the average width (instead of the first elements width) worked for me. But maybe I overlooked something.
Yeah, the _setRunnerWidth would need to be updated to check each item rather than just multiplying the width of the first by the number of items.
But for the carousel to properly support multiple widths the getItemsPerPage would have to take into account the fact that some pages might have less than others otherwise the carousel might end up skipping items.
I plan on looking into this when I get some time.
Added in 0.10.7 - https://github.com/richardscarrott/jquery-ui-carousel/tree/0.10.7
Useful when vertical carousel contains text