Please carefully read this guide in order to fully configure this template, and remember to test it on a Real Device – the Emulator may fail.
This template has native Android Java/XML code so you can edit it only with Android Studio. If you don’t have it, download it for free.
Download Android Studiostring.xml
file – it’s into the res/values
folder in Android Studio – and replace the App Name of this line with your new one:
<string> string name="app_name"> TranslateIt </string>
com
folder as it is and rename the other ones.build.gradle
(the Module app one) in Android Studio and rename the applicationId
into your new package name, then click Sync Now on the top-right corner.
.xml
files stored into the res/layout
folder. Those files are the ones where you can edit all Views, Buttons texts, TextView’s strings, and all Views attributes – position, font color, size, etc.
.java
files.
drawable
folders, where the app icons are stored into the mipmap
folders.
res/values
folder in Android Studio. Open this file and keep reading this guide, you’ll have to perform some edits in this file in order to get your template ready to run.
<string> string name="app_name"> TranslateIt </string>
<string>name="ADMOB_INTERSTITIAL_UNIT_ID">ca-app-pub-3940256099942544/1033173712
<string>name="ADMOB_APP_ID">ca-app-pub-3940256099942544~3347511713
You have to create your Unit ID at apps.admob.com public static String MAIN_COLOR = "#8344af";
public static String GOOGLE_TRANSLATION_API_KEY = "AIzaSyDby9oQjWarxP9EGwA8q7NGD5-94xmAkj";
Follow these steps to generate a Key and enable the Cloud Translate API (you must have an active Google Billing account with your credit card registered in it, and a created Cloud Platform’s Project):
public static String[] languagesArray = {
"af__Afrikaans",
"sq__Albanian",
"am__Amharic",
"ar__Arabic",
"hy__Armenian",
"az__Azerbaijani",
"eu__Basque",
"be__Belarusian",
"bn__Bengali",
"bs__Bosnian",
"bg__Bulgarian",
"ca__Catalan",
"ceb__Cebuano",
"ny__Chichewa",
"zh__Chinese (Simplified)",
"zh-TW__Chinese (Traditional)",
"co__Corsican",
"hr__Croatian",
"cs__Czech",
"da__Danish",
"nl__Dutch",
"en__English",
"eo__Esperanto",
"et__Estonian",
"tl__Filipino",
"fi__Finnish",
"fr__French",
"fy__Frisian",
"gl__Galician",
"ka__Georgian",
"de__German",
"el__Greek",
"gu__Gujarati",
"ht__Haitian Creole",
"ha__Hausa",
"haw__Hawaiian",
"iw__Hebrew",
"hi__Hindi",
"hmn__Hmong",
"hu__Hungarian",
"is__Icelandic",
"ig__Igbo",
"id__Indonesian",
"ga__Irish",
"it__Italian",
"ja__Japanese",
"jw__Javanese",
"kn__Kannada",
"kk__Kazakh",
"km__Khmer",
"ko__Korean",
"ku__Kurdish (Kurmanji)",
"ky__Kyrgyz",
"lo__Lao",
"la__Latin",
"lv__Latvian",
"lt__Lithuanian",
"lb__Luxembourgish",
"mk__Macedonian",
"mg__Malagasy",
"ms__Malay",
"ml__Malayalam",
"mt__Maltese",
"mi__Maori",
"mr__Marathi",
"mn__Mongolian",
"my__Myanmar (Burmese)",
"ne__Nepali",
"no__Norwegian",
"ps__Pashto",
"fa__Persian",
"pl__Polish",
"pt__Portuguese",
"pa__Punjabi",
"ro__Romanian",
"ru__Russian",
"sm__Samoan",
"gd__Scots Gaelic",
"sr__Serbian",
"st__Sesotho",
"sn__Shona",
"sd__Sindhi",
"si__Sinhala",
"sk__Slovak",
"sl__Slovenian",
"so__Somali",
"es__Spanish",
"su__Sundanese",
"sw__Swahili",
"sv__Swedish",
"tg__Tajik",
"ta__Tamil",
"te__Telugu",
"th__Thai",
"tr__Turkish",
"uk__Ukrainian",
"ur__Urdu",
"uz__Uzbek",
"vi__Vietnamese",
"cy__Welsh",
"xh__Xhosa",
"yi__Yiddish",
"yo__Yoruba",
"zu__Zulu",
};
showAdMobInterstitial
The Find in Path window will show you a list of files where that string is located. showAdMobInterstitial(ctx);