mirror of
https://github.com/hmalik144/Mochee_Kent.git
synced 2026-03-17 23:16:03 +00:00
Minor amendments to compile screenshots
This commit is contained in:
@@ -66,7 +66,7 @@
|
||||
android:exported="false" />
|
||||
|
||||
<activity android:name=".ImageViewer.ImageViewer" />
|
||||
<activity android:name=".DetailsActivity"></activity>
|
||||
<!-- <activity android:name=".DetailsActivity"></activity>-->
|
||||
</application>
|
||||
|
||||
</manifest>
|
||||
@@ -1,5 +1,7 @@
|
||||
package com.example.h_mal.mochee;
|
||||
|
||||
import android.content.Intent;
|
||||
import android.net.Uri;
|
||||
import android.os.Bundle;
|
||||
import android.support.v4.app.Fragment;
|
||||
import android.view.LayoutInflater;
|
||||
@@ -16,6 +18,7 @@ import com.google.android.gms.maps.MapsInitializer;
|
||||
import com.google.android.gms.maps.OnMapReadyCallback;
|
||||
import com.google.android.gms.maps.model.CameraPosition;
|
||||
import com.google.android.gms.maps.model.LatLng;
|
||||
import com.google.android.gms.maps.model.Marker;
|
||||
import com.google.android.gms.maps.model.MarkerOptions;
|
||||
import com.google.firebase.database.DatabaseReference;
|
||||
import com.google.firebase.database.FirebaseDatabase;
|
||||
@@ -31,7 +34,7 @@ public class Fragment_Six extends Fragment{
|
||||
private DatabaseReference mDatabase;
|
||||
|
||||
@Override
|
||||
public View onCreateView(LayoutInflater inflater, ViewGroup container,
|
||||
public View onCreateView(final LayoutInflater inflater, ViewGroup container,
|
||||
Bundle savedInstanceState) {
|
||||
View rootView = inflater.inflate(R.layout.fragment6, container, false);
|
||||
|
||||
@@ -71,12 +74,23 @@ public class Fragment_Six extends Fragment{
|
||||
// map.setMyLocationEnabled(true);
|
||||
|
||||
// For dropping a marker at a point on the Map
|
||||
LatLng sydney = new LatLng(51.2704, 0.5227);
|
||||
map.addMarker(new MarkerOptions().position(sydney).title("Mochee Kent")).showInfoWindow();
|
||||
LatLng mocheeLocation = new LatLng(51.5226044,-0.118918);
|
||||
map.addMarker(new MarkerOptions().position(mocheeLocation).title("Mochee")).showInfoWindow();
|
||||
|
||||
// For zooming automatically to the location of the marker
|
||||
CameraPosition cameraPosition = new CameraPosition.Builder().target(sydney).zoom(12).build();
|
||||
CameraPosition cameraPosition = new CameraPosition.Builder().target(mocheeLocation).zoom(14).build();
|
||||
map.animateCamera(CameraUpdateFactory.newCameraPosition(cameraPosition));
|
||||
|
||||
mMap.setOnMarkerClickListener(new GoogleMap.OnMarkerClickListener() {
|
||||
@Override
|
||||
public boolean onMarkerClick(Marker marker) {
|
||||
|
||||
Intent intent = new Intent(android.content.Intent.ACTION_VIEW,
|
||||
Uri.parse("https://goo.gl/maps/nz4ukSBXrbvRwGvX6"));
|
||||
getActivity().startActivity(intent);
|
||||
return false;
|
||||
}
|
||||
});
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
@@ -8,16 +8,16 @@
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/textView4"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:gravity="center"
|
||||
android:text="KENT- UNITED KINGDOM"
|
||||
android:textSize="19sp"
|
||||
android:padding="20dp"
|
||||
android:textStyle="bold"
|
||||
android:textColor="#303132"/>
|
||||
<TextView
|
||||
android:id="@+id/textView4"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:gravity="center"
|
||||
android:padding="20dp"
|
||||
android:text="LONDON - UNITED KINGDOM"
|
||||
android:textColor="#303132"
|
||||
android:textSize="19sp"
|
||||
android:textStyle="bold" />
|
||||
|
||||
<TextView
|
||||
android:textColor="#303132"
|
||||
|
||||
Reference in New Issue
Block a user