Android Samples: add Fragment example (#796)
This commit is contained in:
12
vtm-android-example/res/layout/fragment_blank.xml
Normal file
12
vtm-android-example/res/layout/fragment_blank.xml
Normal file
@@ -0,0 +1,12 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:background="@android:color/white">
|
||||
|
||||
<TextView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:text="@string/empty_fragment_text" />
|
||||
|
||||
</RelativeLayout>
|
||||
@@ -1,9 +1,10 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:background="@android:color/white">
|
||||
|
||||
<org.oscim.android.MapView
|
||||
<RelativeLayout
|
||||
android:id="@+id/mapView"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent" />
|
||||
|
||||
9
vtm-android-example/res/menu/fragment_menu.xml
Normal file
9
vtm-android-example/res/menu/fragment_menu.xml
Normal file
@@ -0,0 +1,9 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<menu xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
|
||||
<item
|
||||
android:id="@+id/replace_fragment"
|
||||
android:showAsAction="never"
|
||||
android:title="@string/replace_fragment" />
|
||||
|
||||
</menu>
|
||||
@@ -28,5 +28,7 @@
|
||||
<string name="warning">Warning</string>
|
||||
<string name="startup_message_mbtiles">To run this sample activity, you need an MBTiles database installed on storage.\n\nadb push %s %s</string>
|
||||
<string name="exit">Exit</string>
|
||||
<string name="replace_fragment">Replace fragment</string>
|
||||
<string name="empty_fragment_text">This is a fragment to test the back stack behaviour of the map fragment.</string>
|
||||
|
||||
</resources>
|
||||
|
||||
Reference in New Issue
Block a user