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