Fixed a focus bug with locate button and added Exit menu option.
This commit is contained in:
parent
7e2087da63
commit
d064e17c06
@ -85,10 +85,16 @@
|
||||
<item
|
||||
android:id="@+id/cache_clear"
|
||||
android:icon="@drawable/content_remove"
|
||||
android:orderInCategory="200"
|
||||
android:orderInCategory="150"
|
||||
android:showAsAction="never"
|
||||
android:title="@string/cache_clear">
|
||||
</item>
|
||||
<item
|
||||
android:id="@+id/menu_exit"
|
||||
android:orderInCategory="200"
|
||||
android:showAsAction="never"
|
||||
android:title="@string/menu_exit">
|
||||
</item>
|
||||
</menu>
|
||||
</item>
|
||||
|
||||
|
@ -53,4 +53,5 @@
|
||||
<string name="menu_public">Public</string>
|
||||
<string name="menu_faction">Faction</string>
|
||||
<string name="menu_info">Info</string>
|
||||
<string name="menu_exit">Exit</string>
|
||||
</resources>
|
@ -281,6 +281,7 @@ public class IITC_Mobile extends Activity {
|
||||
return true;
|
||||
// get the users current location and focus it on map
|
||||
case R.id.locate:
|
||||
iitc_view.loadUrl("javascript: window.smartphone.mapButton.click();");
|
||||
iitc_view.loadUrl("javascript: window.map.locate({setView : true, maxZoom: 13});");
|
||||
actionBar.setTitle(getString(R.string.menu_map));
|
||||
return true;
|
||||
@ -310,6 +311,9 @@ public class IITC_Mobile extends Activity {
|
||||
iitc_view.loadUrl("javascript: window.chat.choose('faction');");
|
||||
actionBar.setTitle(getString(R.string.menu_faction));
|
||||
return true;
|
||||
case R.id.menu_exit:
|
||||
super.onBackPressed();
|
||||
return true;
|
||||
default:
|
||||
return super.onOptionsItemSelected(item);
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user