With option for associating image with wikipedia article (#3783)

This commit is contained in:
Vivek Maskara 2020-06-16 06:51:06 -07:00 committed by GitHub
parent a4379fde02
commit e4190f3f7d
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
28 changed files with 979 additions and 479 deletions

View file

@ -518,6 +518,14 @@ public class Media implements Parcelable {
this.coordinates = coordinates;
}
/**
* Returns wikicode to use the media file on a MediaWiki site
* @return
*/
public String getWikiCode() {
return String.format("[[%s|thumb|%s]]", filename, thumbnailTitle);
}
/**
* Sets the categories the file falls under.
* </p>