Merge "More Detailed Report Names" into gingerbread
diff --git a/apps/CtsVerifier/res/layout/bt_main.xml b/apps/CtsVerifier/res/layout/pass_fail_list.xml
similarity index 77%
rename from apps/CtsVerifier/res/layout/bt_main.xml
rename to apps/CtsVerifier/res/layout/pass_fail_list.xml
index cb65412..3c1f9d0 100644
--- a/apps/CtsVerifier/res/layout/bt_main.xml
+++ b/apps/CtsVerifier/res/layout/pass_fail_list.xml
@@ -14,10 +14,10 @@
limitations under the License.
-->
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
- android:orientation="vertical"
- android:layout_width="match_parent"
- android:layout_height="match_parent"
- >
+ android:orientation="vertical"
+ android:layout_width="match_parent"
+ android:layout_height="match_parent"
+ >
<ListView android:id="@id/android:list"
android:layout_width="match_parent"
@@ -25,6 +25,11 @@
android:layout_weight="1"
/>
+ <TextView android:id="@id/android:empty"
+ android:layout_width="match_parent"
+ android:layout_height="match_parent"
+ />
+
<include layout="@layout/pass_fail_buttons" />
</LinearLayout>
diff --git a/apps/CtsVerifier/res/layout/sv_main.xml b/apps/CtsVerifier/res/layout/sv_main.xml
deleted file mode 100644
index 8402b42..0000000
--- a/apps/CtsVerifier/res/layout/sv_main.xml
+++ /dev/null
@@ -1,36 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2011 The Android Open Source Project
-
- Licensed under the Apache License, Version 2.0 (the "License");
- you may not use this file except in compliance with the License.
- You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
- Unless required by applicable law or agreed to in writing, software
- distributed under the License is distributed on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- See the License for the specific language governing permissions and
- limitations under the License.
--->
-<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
- android:orientation="vertical"
- android:layout_width="match_parent"
- android:layout_height="match_parent">
-
- <ListView android:id="@id/android:list"
- android:layout_width="match_parent"
- android:layout_height="match_parent"
- android:background="#000000"
- android:layout_weight="1"
- android:drawSelectorOnTop="false"/>
-
- <TextView android:id="@id/android:empty"
- android:layout_width="match_parent"
- android:layout_height="match_parent"
- android:background="#000000"
- android:text="@string/sv_no_data"/>
-
- <include layout="@layout/pass_fail_buttons" />
-
-</LinearLayout>
diff --git a/apps/CtsVerifier/src/com/android/cts/verifier/bluetooth/BluetoothTestActivity.java b/apps/CtsVerifier/src/com/android/cts/verifier/bluetooth/BluetoothTestActivity.java
index 4ddfa51..721a608 100644
--- a/apps/CtsVerifier/src/com/android/cts/verifier/bluetooth/BluetoothTestActivity.java
+++ b/apps/CtsVerifier/src/com/android/cts/verifier/bluetooth/BluetoothTestActivity.java
@@ -30,7 +30,7 @@
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
- setContentView(R.layout.bt_main);
+ setContentView(R.layout.pass_fail_list);
setPassFailButtonClickListeners();
setInfoResources(R.string.bluetooth_test, R.string.bluetooth_test_info, -1);
diff --git a/apps/CtsVerifier/src/com/android/cts/verifier/streamquality/StreamingVideoActivity.java b/apps/CtsVerifier/src/com/android/cts/verifier/streamquality/StreamingVideoActivity.java
index fa0cf29..cc74b6f 100644
--- a/apps/CtsVerifier/src/com/android/cts/verifier/streamquality/StreamingVideoActivity.java
+++ b/apps/CtsVerifier/src/com/android/cts/verifier/streamquality/StreamingVideoActivity.java
@@ -25,6 +25,7 @@
import android.content.Intent;
import android.database.DataSetObserver;
import android.os.Bundle;
+import android.widget.TextView;
import java.io.Serializable;
@@ -125,10 +126,13 @@
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
- setContentView(R.layout.sv_main);
+ setContentView(R.layout.pass_fail_list);
setPassFailButtonClickListeners();
setInfoResources(R.string.streaming_video, R.string.streaming_video_info, -1);
+ TextView empty = (TextView) findViewById(android.R.id.empty);
+ empty.setText(R.string.sv_no_data);
+
getPassButton().setEnabled(false);
setTestListAdapter(getStreamAdapter());
}
diff --git a/apps/CtsVerifier/src/com/android/cts/verifier/suid/SuidFilesActivity.java b/apps/CtsVerifier/src/com/android/cts/verifier/suid/SuidFilesActivity.java
index 826b82c..7d99c2d 100644
--- a/apps/CtsVerifier/src/com/android/cts/verifier/suid/SuidFilesActivity.java
+++ b/apps/CtsVerifier/src/com/android/cts/verifier/suid/SuidFilesActivity.java
@@ -16,6 +16,7 @@
package com.android.cts.verifier.suid;
+import com.android.cts.verifier.PassFailButtons;
import com.android.cts.verifier.R;
import com.android.cts.verifier.TestResult;
import com.android.cts.verifier.os.FileUtils;
@@ -23,7 +24,6 @@
import android.app.Activity;
import android.app.AlertDialog;
-import android.app.ListActivity;
import android.app.ProgressDialog;
import android.content.DialogInterface;
import android.content.DialogInterface.OnCancelListener;
@@ -45,7 +45,7 @@
import java.util.Set;
/** {@link Activity} that tries to find suid files. */
-public class SuidFilesActivity extends ListActivity {
+public class SuidFilesActivity extends PassFailButtons.ListActivity {
private static final String TAG = SuidFilesActivity.class.getSimpleName();
@@ -63,7 +63,9 @@
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
- setResult(RESULT_CANCELED);
+ setContentView(R.layout.pass_fail_list);
+ setPassFailButtonClickListeners();
+ getPassButton().setEnabled(false);
mAdapter = new SuidFilesAdapter();
setListAdapter(mAdapter);
@@ -256,7 +258,7 @@
// Alert the user that nothing was found rather than showing an empty list view.
if (passed) {
- TestResult.setPassedResult(SuidFilesActivity.this, getClass().getName());
+ getPassButton().setEnabled(true);
new AlertDialog.Builder(SuidFilesActivity.this)
.setTitle(R.string.congratulations)
.setMessage(R.string.no_suid_files)
@@ -267,8 +269,6 @@
}
})
.show();
- } else {
- TestResult.setFailedResult(SuidFilesActivity.this, getClass().getName());
}
}
}
diff --git a/tools/host/src/com/android/cts/Version.java b/tools/host/src/com/android/cts/Version.java
index b8838c7..243add2 100644
--- a/tools/host/src/com/android/cts/Version.java
+++ b/tools/host/src/com/android/cts/Version.java
@@ -18,7 +18,7 @@
public class Version {
// The CTS version string
- private static final String version = "2.3_r7";
+ private static final String version = "2.3_r8";
private Version() {
// no instances allowed