單擊圖像。當我使用Robotium點擊圖片上這樣的可擴展列表視圖的第一項:可擴展列表視圖滾動到列表視圖中
ListView listview = getCurrentListView().getChildAt(1); //get feed listview.
for(ImageView view : solo.getCurrentImageViews(listview))
{
if(view.getId() == R.id.image) //all images in the feed listview shares the same ID.
{
solo.clickonview(view);
break; //get the first image then break the loop.
}
}
的擴張列表視圖滾動。 使用logcat,我相信,我已經得到了第一個圖像。但是當solo.clickonview,它不起作用,並且listview開始滾動到最後一個。 爲什麼會發生?
是否有一些方法來完成場景?
它的工作原理,感謝您的幫助。 – salomon