This repository has been archived by the owner on Oct 25, 2019. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Malah
committed
Feb 5, 2019
1 parent
cc4392d
commit 81afe40
Showing
4 changed files
with
40 additions
and
46 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
36 changes: 36 additions & 0 deletions
36
app/src/main/java/fr/istic/hbmlh/photoloc/adapter/MapItemAdapter.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
package fr.istic.hbmlh.photoloc.adapter; | ||
|
||
|
||
import android.content.Context; | ||
import android.view.View; | ||
import android.view.ViewGroup; | ||
import android.widget.ImageView; | ||
import android.widget.LinearLayout; | ||
|
||
import com.google.android.gms.maps.GoogleMap; | ||
import com.google.android.gms.maps.model.Marker; | ||
import com.squareup.picasso.Picasso; | ||
|
||
public class MapItemAdapter implements GoogleMap.InfoWindowAdapter { | ||
|
||
private ImageView imageView; | ||
|
||
public MapItemAdapter(Context context) { | ||
imageView = new ImageView(context); | ||
LinearLayout.LayoutParams lp = new LinearLayout.LayoutParams(ViewGroup.LayoutParams.MATCH_PARENT, ViewGroup.LayoutParams.MATCH_PARENT); | ||
imageView.setLayoutParams(lp); | ||
} | ||
|
||
@Override | ||
public View getInfoWindow(Marker marker) { | ||
Picasso.get().load("file://" + marker.getTitle()) | ||
.resize(300, 300).centerCrop() | ||
.into(imageView); | ||
return imageView; | ||
} | ||
|
||
@Override | ||
public View getInfoContents(Marker marker) { | ||
return null; | ||
} | ||
} |
44 changes: 0 additions & 44 deletions
44
app/src/main/java/fr/istic/hbmlh/photoloc/repository/AsyncRepository.java
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters