Merge "Update BiDiTest app for adding more unit tests"
This commit is contained in:
committed by
Android (Google) Code Review
commit
8fbe6786a1
@@ -30,5 +30,6 @@
|
||||
</activity>
|
||||
|
||||
</application>
|
||||
|
||||
<uses-sdk android:minSdkVersion="10"
|
||||
android:targetSdkVersion="10"/>
|
||||
</manifest>
|
||||
|
||||
@@ -20,7 +20,8 @@
|
||||
android:layout_height="fill_parent">
|
||||
|
||||
<FrameLayout android:layout_width="match_parent"
|
||||
android:layout_height="match_parent">
|
||||
android:layout_height="match_parent"
|
||||
android:background="#FFFFFFFF">
|
||||
|
||||
<FrameLayout
|
||||
android:layout_width="300dp"
|
||||
@@ -76,6 +77,28 @@
|
||||
</FrameLayout>
|
||||
</FrameLayout>
|
||||
|
||||
<FrameLayout
|
||||
android:layout_width="300dp"
|
||||
android:layout_height="300dp"
|
||||
android:layout_gravity="top|right"
|
||||
android:background="@*android:drawable/dialog_full_holo_dark"
|
||||
android:layoutDirection="ltr">
|
||||
|
||||
<FrameLayout
|
||||
android:layout_width="100dp"
|
||||
android:layout_height="100dp"
|
||||
android:layout_gravity="top|left"
|
||||
android:background="#FF0000FF">
|
||||
</FrameLayout>
|
||||
|
||||
<FrameLayout
|
||||
android:layout_width="100dp"
|
||||
android:layout_height="100dp"
|
||||
android:layout_gravity="bottom|right"
|
||||
android:background="#FFFFFFFF">
|
||||
</FrameLayout>
|
||||
</FrameLayout>
|
||||
|
||||
<FrameLayout
|
||||
android:layout_width="300dp"
|
||||
android:layout_height="300dp"
|
||||
@@ -130,6 +153,28 @@
|
||||
</FrameLayout>
|
||||
</FrameLayout>
|
||||
|
||||
<FrameLayout
|
||||
android:layout_width="300dp"
|
||||
android:layout_height="300dp"
|
||||
android:layout_gravity="bottom|right"
|
||||
android:background="@*android:drawable/menu_background_fill_parent_width"
|
||||
android:layoutDirection="ltr">
|
||||
|
||||
<FrameLayout
|
||||
android:layout_width="100dp"
|
||||
android:layout_height="100dp"
|
||||
android:layout_gravity="top|left"
|
||||
android:background="#FF0000FF">
|
||||
</FrameLayout>
|
||||
|
||||
<FrameLayout
|
||||
android:layout_width="100dp"
|
||||
android:layout_height="100dp"
|
||||
android:layout_gravity="bottom|right"
|
||||
android:background="#FFFFFFFF">
|
||||
</FrameLayout>
|
||||
</FrameLayout>
|
||||
|
||||
</FrameLayout>
|
||||
|
||||
</FrameLayout>
|
||||
|
||||
28
tests/BiDiTests/res/menu/main_menu.xml
Normal file
28
tests/BiDiTests/res/menu/main_menu.xml
Normal file
@@ -0,0 +1,28 @@
|
||||
<?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.
|
||||
-->
|
||||
|
||||
<menu xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:id="@+id/main_menu">
|
||||
|
||||
<item android:id="@+id/menu_add"
|
||||
android:icon="@android:drawable/ic_menu_add"
|
||||
android:title="@string/menu_add" />
|
||||
|
||||
<item android:id="@+id/menu_delete"
|
||||
android:icon="@android:drawable/ic_menu_delete"
|
||||
android:title="@string/menu_delete" />
|
||||
|
||||
</menu>
|
||||
@@ -36,4 +36,6 @@
|
||||
<string name="bold_italic_text">Bold Italic String</string>
|
||||
<string name="mixed_text_1">he said in Arabic: لا. Wow this is cool</string>
|
||||
<string name="hebrew_text">םמ</string>
|
||||
<string name="menu_add">Add</string>
|
||||
<string name="menu_delete">Delete</string>
|
||||
</resources>
|
||||
@@ -25,6 +25,8 @@ import android.app.Activity;
|
||||
import android.app.Fragment;
|
||||
import android.app.FragmentTransaction;
|
||||
import android.os.Bundle;
|
||||
import android.view.Menu;
|
||||
import android.view.MenuInflater;
|
||||
import android.view.View;
|
||||
import android.widget.AdapterView;
|
||||
import android.widget.ListView;
|
||||
@@ -124,4 +126,11 @@ public class BiDiTestActivity extends Activity {
|
||||
|
||||
return result;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean onCreateOptionsMenu(Menu menu) {
|
||||
MenuInflater inflater = getMenuInflater();
|
||||
inflater.inflate(R.menu.main_menu, menu);
|
||||
return true;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user