Posts by Jônatas Barbosa • 136 points
6 posts
-
5
votes1
answer95
viewsQ: Where is the function taking the current time?
I have a function that returns the current time. Where does this value come from? Phone time? Server? Just follow my lead: public static Date getAgora() { Calendar calendar = Calendar.getInstance();…
-
0
votes1
answer243
viewsA: Relate firebase Authetication to Realtime database
To use email as an ID you need to encode in Base64; and to create a user already has a method in firebase: FirebaseAuth autentica; private void cadastrarUsuario() { autentica =…
-
0
votes1
answer65
viewsA: How to use Firebase
To make your life easier, advice create a class to easily catch the instance: My firebase class: public final class ConfiguracaoFirebase { private static DatabaseReference referenciaFireBase;…
-
3
votes3
answers455
viewsA: Show or hide an image in Android Studio
In xml, work component properties: To make visible android:visibility="visible" : To keep only the image space occupied in xml, but invisible: android:visibility="invisible" To remove the visibility…
-
2
votes2
answers66
viewsA: How do I click on the listview and open an activyity?
Use this method: list.setOnItemClickListener(new AdapterView.onItemClickListener() { @Override public void onItemClick(AdapterView<?> adapter, View view, int position, long arg) { Intent…
-
0
votes2
answers217
viewsA: Go back to the previous Fragment by clicking the Back Phone button?
This method makes have the event button back from mobile: @Override public void onBackPressed() { super.onBackPressed(); } Use it to call the previous Fragment.…