diff options
author | Romain Guy <romainguy@google.com> | 2010-08-24 17:20:20 -0700 |
---|---|---|
committer | Android (Google) Code Review <android-gerrit@google.com> | 2010-08-24 17:20:20 -0700 |
commit | a84e02ce3cc392ccf23bbe89cdfbef650047ffe7 (patch) | |
tree | 6ddb05a329a031522ccd45c477d11556dfdb5ee1 /tests | |
parent | 17b4d9ea826609f26a73077975c2399f91b5ca36 (diff) | |
parent | fb8b763f762ae21923c58d64caa729b012f40e05 (diff) | |
download | frameworks_base-a84e02ce3cc392ccf23bbe89cdfbef650047ffe7.zip frameworks_base-a84e02ce3cc392ccf23bbe89cdfbef650047ffe7.tar.gz frameworks_base-a84e02ce3cc392ccf23bbe89cdfbef650047ffe7.tar.bz2 |
Merge "Use only one GL context per process, share chaches."
Diffstat (limited to 'tests')
-rw-r--r-- | tests/HwAccelerationTest/src/com/google/android/test/hwui/ListActivity.java | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/tests/HwAccelerationTest/src/com/google/android/test/hwui/ListActivity.java b/tests/HwAccelerationTest/src/com/google/android/test/hwui/ListActivity.java index c638958..94b936b 100644 --- a/tests/HwAccelerationTest/src/com/google/android/test/hwui/ListActivity.java +++ b/tests/HwAccelerationTest/src/com/google/android/test/hwui/ListActivity.java @@ -21,6 +21,7 @@ import android.content.Context; import android.content.res.Resources; import android.os.Bundle; import android.util.DisplayMetrics; +import android.view.ContextMenu; import android.view.View; import android.view.ViewGroup; import android.widget.ArrayAdapter; @@ -83,6 +84,17 @@ public class ListActivity extends Activity { ListView list = (ListView) findViewById(R.id.list); list.setAdapter(adapter); + + registerForContextMenu(list); + } + + @Override + public void onCreateContextMenu(ContextMenu menu, View v, ContextMenu.ContextMenuInfo menuInfo) { + super.onCreateContextMenu(menu, v, menuInfo); + menu.setHeaderTitle("Context menu"); + menu.add("List item 1"); + menu.add("List item 2"); + menu.add("List item 3"); } private static class SimpleListAdapter extends ArrayAdapter<String> { |