Added a map mode button to the nav activity
This commit is contained in:
@@ -43,11 +43,19 @@
|
||||
android:textColor="#FF0000" />
|
||||
|
||||
<ImageButton
|
||||
android:id="@+id/mark_my_lcoation_button"
|
||||
android:id="@+id/map_button"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignParentBottom="true"
|
||||
android:layout_alignParentRight="true"
|
||||
android:src="@drawable/map_action_bar" />
|
||||
|
||||
<ImageButton
|
||||
android:id="@+id/mark_my_lcoation_button"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_above="@+id/map_button"
|
||||
android:layout_alignParentRight="true"
|
||||
android:src="@drawable/mark_my_location_action_bar" />
|
||||
|
||||
<ImageButton
|
||||
|
||||
@@ -156,6 +156,10 @@ public class NavigationActivity extends FragmentActivity implements CompassListe
|
||||
updateGoButton();
|
||||
break;
|
||||
|
||||
case R.id.map_button:
|
||||
mMap.changeMapMode();
|
||||
break;
|
||||
|
||||
case R.id.mark_my_lcoation_button:
|
||||
GeoPoint point = mMap.getUserLocation();
|
||||
|
||||
@@ -173,6 +177,7 @@ public class NavigationActivity extends FragmentActivity implements CompassListe
|
||||
} else
|
||||
|
||||
break;
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@@ -261,6 +266,7 @@ public class NavigationActivity extends FragmentActivity implements CompassListe
|
||||
mGoButton.setOnClickListener(this);
|
||||
findViewById(R.id.mark_my_lcoation_button).setOnClickListener(this);
|
||||
findViewById(R.id.my_location_button).setOnClickListener(this);
|
||||
findViewById(R.id.map_button).setOnClickListener(this);
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user