android: remove the "continue in background" button for now
authorXeli
Sat, 26 Nov 2011 11:40:54 +0100
changeset 6434 bf8bfc6ceca0
parent 6433 c8e4b3f29e1e
child 6435 356fbb672f84
android: remove the "continue in background" button for now
project_files/Android-build/SDL-android-project/src/org/hedgewars/hedgeroid/Downloader/DownloadFragment.java
--- a/project_files/Android-build/SDL-android-project/src/org/hedgewars/hedgeroid/Downloader/DownloadFragment.java	Sat Nov 26 11:39:41 2011 +0100
+++ b/project_files/Android-build/SDL-android-project/src/org/hedgewars/hedgeroid/Downloader/DownloadFragment.java	Sat Nov 26 11:40:54 2011 +0100
@@ -52,7 +52,7 @@
 
 	private TextView progress_sub;
 	private ProgressBar progress;
-	private Button positive, negative;
+	private Button /*positive,*/ negative;
 
 	private DownloadPackage pack;
 
@@ -84,9 +84,9 @@
 		progress_sub = (TextView)v.findViewById(R.id.progressbar_sub);
 		progress = (ProgressBar)v.findViewById(R.id.progressbar);
 
-		positive = (Button) v.findViewById(R.id.background);
+		//positive = (Button) v.findViewById(R.id.background);
 		negative = (Button) v.findViewById(R.id.cancelDownload);
-		positive.setOnClickListener(backgroundClicker);
+		//positive.setOnClickListener(backgroundClicker);
 		negative.setOnClickListener(cancelClicker);
 
 		pack = getArguments().getParcelable(DownloadFragment.EXTRA_TASK);
@@ -107,7 +107,7 @@
 					messengerService.send(message);
 				} catch (RemoteException e) {}
 			}
-			getActivity().finish();
+			//getActivity().finish();
 		}
 	};
 	private OnClickListener doneClicker = new OnClickListener(){
@@ -181,8 +181,8 @@
 			case MSG_START:
 				progress.setMax(msg.arg1);
 				progress_sub.setText(String.format("%dkb/%dkb\n%s", 0, msg.arg1, ""));
-				positive.setText(R.string.download_background);
-				positive.setOnClickListener(backgroundClicker);
+				//positive.setText(R.string.download_background);
+				//positive.setOnClickListener(backgroundClicker);
 				negative.setText(R.string.download_cancel);
 				negative.setOnClickListener(cancelClicker);
 				break;
@@ -194,16 +194,16 @@
 				progress.setProgress(progress.getMax());
 				progress_sub.setText(R.string.download_done);
 
-				positive.setText(R.string.download_back);
-				positive.setOnClickListener(doneClicker);
+			//	positive.setText(R.string.download_back);
+			//	positive.setOnClickListener(doneClicker);
 
 				negative.setVisibility(View.INVISIBLE);
 				break;
 			case MSG_FAILED:
 				progress.setProgress(progress.getMax());
 				progress_sub.setText(R.string.download_failed);
-				positive.setText(R.string.download_back);
-				positive.setOnClickListener(doneClicker);
+			//	positive.setText(R.string.download_back);
+			//	positive.setOnClickListener(doneClicker);
 
 				negative.setText(R.string.download_tryagain);
 				negative.setOnClickListener(tryAgainClicker);