fix ScriptDeleteTest

Layout has changed a bit and clicks on hardcoded positions seem to
trigger unintended events on some devices; if brick context menu is
displayed instead of bricklist, solo.goBack() is used to get back to the
listview
refactoring of method in UiTestUtils

getListItemYPositions is used in two different listviews with different
indices; add method with a listview index as parameter