android: hopefully prevents a FC, I can't reproduce it though..
authorXeli
Sat, 03 Dec 2011 18:49:17 +0100
changeset 6485 7586c266b52e
parent 6484 617e9d606e28
child 6486 2a3ee24764bb
android: hopefully prevents a FC, I can't reproduce it though..
project_files/Android-build/SDL-android-project/src/org/hedgewars/hedgeroid/Downloader/DownloadAssets.java
project_files/Android-build/SDL-android-project/src/org/hedgewars/hedgeroid/Downloader/DownloadListActivity.java
project_files/Android-build/SDL-android-project/src/org/hedgewars/hedgeroid/Downloader/DownloadListFragment.java
--- a/project_files/Android-build/SDL-android-project/src/org/hedgewars/hedgeroid/Downloader/DownloadAssets.java	Sat Dec 03 15:22:07 2011 +0100
+++ b/project_files/Android-build/SDL-android-project/src/org/hedgewars/hedgeroid/Downloader/DownloadAssets.java	Sat Dec 03 18:49:17 2011 +0100
@@ -25,8 +25,6 @@
 		act = _act;
 	}
 	
-	
-	
 	public static Long copyFileOrDir(Context c, String path) {
 	    AssetManager assetManager = c.getAssets();
 	    String assets[] = null;
--- a/project_files/Android-build/SDL-android-project/src/org/hedgewars/hedgeroid/Downloader/DownloadListActivity.java	Sat Dec 03 15:22:07 2011 +0100
+++ b/project_files/Android-build/SDL-android-project/src/org/hedgewars/hedgeroid/Downloader/DownloadListActivity.java	Sat Dec 03 18:49:17 2011 +0100
@@ -37,11 +37,6 @@
 		layout = (FrameLayout)findViewById(R.id.downloadFrameLayout);
 		downloadQueueContainer = (LinearLayout) findViewById(R.id.downloadQueueContainer);
 	}
-
-	public void onDestroy(){
-		super.onDestroy();
-		Log.d("tag", "on destroy");
-	}
 	
 	public void onNewItemSelected(DownloadPackage _task, int x, int minX, int maxX, int size) {
 		if(layout != null){
--- a/project_files/Android-build/SDL-android-project/src/org/hedgewars/hedgeroid/Downloader/DownloadListFragment.java	Sat Dec 03 15:22:07 2011 +0100
+++ b/project_files/Android-build/SDL-android-project/src/org/hedgewars/hedgeroid/Downloader/DownloadListFragment.java	Sat Dec 03 18:49:17 2011 +0100
@@ -13,9 +13,6 @@
 
 import android.graphics.Color;
 import android.os.Bundle;
-import android.support.v4.app.DialogFragment;
-import android.support.v4.app.Fragment;
-import android.support.v4.app.FragmentTransaction;
 import android.support.v4.app.ListFragment;
 import android.util.Log;
 import android.view.View;
@@ -103,6 +100,8 @@
 	}
 
 	public void onItemClick(AdapterView<?> arg0, View arg1, int position, long arg3) {
+		DownloadPackage task = (DownloadPackage)arg0.getAdapter().getItem(position);
+		/*
 		FragmentTransaction ft = getFragmentManager().beginTransaction();
 		Fragment prev = getFragmentManager().findFragmentByTag("dialog");
 
@@ -111,12 +110,12 @@
 		ft.addToBackStack(null);
 
 		//create a new dialog based on this task
-		DownloadPackage task = (DownloadPackage)arg0.getAdapter().getItem(position);
+		
 		DialogFragment newFragment = DownloadDialogFragment.newInstance(task);
 
 		//show it
-		//newFragment.show(ft, "dialog");
-
+		newFragment.show(ft, "dialog");
+		 */
 		targetView = arg1;
 
 		//determine state