I met a small problem. My MainActivity has a Fragment which includes a ListView. There are some items showing on the ListView. After Clicking one item, another Activity will be opened. When I click the "UP" button and return to the MainActivity, everything is displayed properly except the ListView which is disappearing. I realized that I needed to trigger the ListView repaint. But so far, I only find one way:
listAdapter.clear();
listAdapter.addAll(...);
It was a little conter-intuitive because the content of the ListView wasn't changed and I just wanted to show them again. So does anyone know any simple way to implement it?
Thanks!