mirror of
https://github.com/commons-app/apps-android-commons.git
synced 2025-10-27 04:43:54 +01:00
Fix back button issue
This commit is contained in:
parent
dbeeaa0aa8
commit
ee5df7d35c
3 changed files with 6 additions and 15 deletions
|
|
@ -84,7 +84,8 @@
|
||||||
android:label="@string/title_activity_signup"/>
|
android:label="@string/title_activity_signup"/>
|
||||||
<activity
|
<activity
|
||||||
android:name=".nearby.NearbyActivity"
|
android:name=".nearby.NearbyActivity"
|
||||||
android:label="@string/title_activity_nearby" />
|
android:label="@string/title_activity_nearby"
|
||||||
|
android:parentActivityName=".contributions.ContributionsActivity"/>
|
||||||
|
|
||||||
<service android:name=".upload.UploadService" >
|
<service android:name=".upload.UploadService" >
|
||||||
</service>
|
</service>
|
||||||
|
|
|
||||||
|
|
@ -30,7 +30,9 @@ public class NearbyActivity extends AppCompatActivity {
|
||||||
protected void onCreate(Bundle savedInstanceState) {
|
protected void onCreate(Bundle savedInstanceState) {
|
||||||
super.onCreate(savedInstanceState);
|
super.onCreate(savedInstanceState);
|
||||||
setContentView(R.layout.activity_nearby);
|
setContentView(R.layout.activity_nearby);
|
||||||
|
if (getSupportActionBar() != null) {
|
||||||
getSupportActionBar().setDisplayHomeAsUpEnabled(true);
|
getSupportActionBar().setDisplayHomeAsUpEnabled(true);
|
||||||
|
}
|
||||||
registerLocationManager();
|
registerLocationManager();
|
||||||
|
|
||||||
// Begin the transaction
|
// Begin the transaction
|
||||||
|
|
@ -38,23 +40,11 @@ public class NearbyActivity extends AppCompatActivity {
|
||||||
NearbyListFragment fragment = new NearbyListFragment();
|
NearbyListFragment fragment = new NearbyListFragment();
|
||||||
ft.add(R.id.container, fragment);
|
ft.add(R.id.container, fragment);
|
||||||
ft.commit();
|
ft.commit();
|
||||||
|
|
||||||
/*
|
|
||||||
if (savedInstanceState == null) {
|
|
||||||
getSupportFragmentManager().beginTransaction()
|
|
||||||
.add(R.id.container, new NearbyListFragment())
|
|
||||||
.commit();
|
|
||||||
}
|
|
||||||
*/
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
protected void onResume(){
|
protected void onResume(){
|
||||||
super.onResume();
|
super.onResume();
|
||||||
|
|
||||||
|
|
||||||
//TODO: Check if we need String or double coords, and in what format
|
|
||||||
//gpsCoords = String.valueOf(currentLatitude) + "|" + String.valueOf(currentLongitude);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
protected LatLng getmLatestLocation() {
|
protected LatLng getmLatestLocation() {
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue