I have a collectionview with infinite scroll.
scroll position jumps to the top of previous set or last or middle of the current set when new set items added to the collection view.
I want to keep the scroll position as the end of the previous set or the first of the current set.
Related
I try to click element that doesn't appear in page then I use "keyword Scroll Element Into View" but it doesn't scroll into view and Robot return element is not clickable at point.
I try these way: Nothing happen and cannot click
Scroll Element Into View &{quickLink}[sendDoc]
Set Focus To Element ${PRODUCT}
Click Element ${PRODUCT}
And these way: it scroll to the bottom of page and cannot click
Wait Until Element Is Visible ${PRODUCT} timeout=30s
${x}= Get Horizontal Position ${PRODUCT}
${y}= Get Vertical Position ${PRODUCT}
Execute Javascript window.scrollTo(${x}, ${y})
Set Focus To Element ${PRODUCT}
Click Element ${PRODUCT}
ElementClickInterceptedException: Message: Element is not clickable at point (453.75,186.5) because another element obscures it
Instead of scrolling, you have more options:
1) Resize your browser, so you dont need to scroll (use xvfb to create a screen with a specific size, then use Set Window Size)
2) I guess only using "Wait Until Element Is Visible" is enough. No need to scroll
In UITableView I can call tableView.contentOffset.y; in order to get where the user has scrolled. However, WatchKit's WKInterfaceTable doesn't support that. Is there any way to get the scrolling position in the WKInterfaceTable?
Use case why this is necessary:
user is in the middle of a table
table updates
table scroll jumps to top
user has to scroll down again
I am able to scroll down programmatically with self.messageTableOutlet.scrollToRow(at: (size-1) but the user doesn't always want to get thrown to the end of the table. He also doesn't want to get to the top, he just wants to stay there.
In QgraphicsWidget im adding new items (QGraphicsLayoutItem) using Drag/drop on the QGraphicsWidget and using QGraphicsLinearLayout.
If the user wants to move or create the item between the items already present in the layout , i have to animate the movement when the item is inserted between two items like top item moving upwards and the bottom item moving downwards with some time gap.
I'm trying to set the scroll vertical position of a spark dataGrid to show the items as I add them to the grid. I know you can set the scroll position like this:
dataGrid.scroller.viewport.verticalScrollPosition = itemPosition*rowHeight;
The problem is that the dataGrid have variableRowHeight, as each row word wraps their name labels, and I don't know how to get each row height. I though of getting the itemRenderer associated with every item as I add it to the grid, and keep the total row height value in a variable, but don't know how to achieve that.
Is there any way to set the scroll position of a dataGrid with variableRowHeight to show the last added item?
After you set your dataprovider, you could do something like
dg.validateNow();
dg.verticalScrollPosition=dg.grid.contentHeight+dg.grid.height;
I am using a horizontal tilelist in flex to display an image gallery with only one item in horiz. tilelist being shown at a time. I have next and previous buttons on both sides.
The problem is I want to display a particular item/image in that list when user clicks on a thumb image from another thumbimages tilelist at bottom.
I used someTilelist.selectedIndex property but it just selects that particular index in list, it does not show that particular item/image. I want the list to show that particular image, not just select it. Please take note that the horiz. tilelist shows only one image at time.
tilelist.scrollToIndex(index);