Commit 6ad5f61e authored by Sébastien Toque's avatar Sébastien Toque

clear ListActivities when exiting them

parent ff738b53
......@@ -54,6 +54,13 @@ public class BrowserActivity extends ListActivity {
openDir(file);
}
@Override
protected void onDestroy() {
mAdapter.clear();
mScollStates.clear();
super.onDestroy();
}
private void openDir(File file) {
mAdapter.clear();
mCurrentDir = file;
......
......@@ -24,6 +24,7 @@ import android.widget.TextView;
import android.widget.TextView.OnEditorActionListener;
public class SearchActivity extends ListActivity {
public final static String TAG = "VLC/SearchActivit";
private EditText mSearchText;
......@@ -57,7 +58,15 @@ public class SearchActivity extends ListActivity {
}
mSearchText.requestFocus();
}
@Override
protected void onDestroy() {
if (mHistoryAdapter != null)
mHistoryAdapter.clear();
mHistory.clear();
mResultAdapter.clear();
super.onDestroy();
}
private void search(CharSequence key, int type) {
......
......@@ -49,6 +49,8 @@ public class VideoListActivity extends ListActivity {
@Override
protected void onDestroy() {
mMediaLibrary.removeUpdateHandler(mHandler);
mThumbnailerManager.clearJobs();
mVideoAdapter.clear();
super.onDestroy();
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment