I am creating a horizontal scrollable list which is also editable. The size of the container of this list is dynamic based on the width of the visible area of the browser. When I have a list of items which has filled up the screen, and I add a new Item, the container scrolls way past the newly added element, to a blank screen. If I scroll back using the "prev" button, I do see it. I've attached code which is used to dynamically add the new item.
I tried to use the .move and .seekTo functions to get to the correct location, but my "prev" button gets randomly disabled so I can't scroll back.
Any pointers from anyone?
var speed = 200;
var parent = $("#main-container").data("scrollable");
parent.end(speed);
var clone = $("#thumbnail-clone").clone(true, true);
var input = clone.find(".text-input");
clone.attr("id", newid);
parent.addItem(clone);
input.show();
clone.show();
input.focus();