Questions tagged as 'android'

1
answer

Webview problem

I'm trying to make an application in Webview, but when I click on a button that contains url it displays the if I want to open in which app, is there any way to make the app itself open the next page ?.     
asked by 16.07.2018 / 00:27
1
answer

How can I add 2 buttons with submenu in Android Studio

I'd like to dynamically add options to my screen menu on Android, I've seen several examples, but all turned to a single button. Assuming I have it. override fun onCreateOptionsMenu(menu: Menu, menuInflater: MenuInflater) { menu.cl...
asked by 16.07.2018 / 20:01
1
answer

How to insert onCreateOptionsMenu into a Java class?

How do I insert onCreateOptionsMenu and onOptionsItemSelected into a Java class so I do not get repeating on all the Activities that call it? I have to pass only the ids and classes that I call by clicking on the menu item. @O...
asked by 01.07.2018 / 15:05
1
answer

String in findViewById

Hello, I was wondering if you can use a string in findViewById. I have an app with several imageview that when calling a call to the camera's camera. So that I do not need to put this intent and its startActivityforResult for each imageview, I t...
asked by 04.07.2018 / 21:16
2
answers

EditText.getText on a null object reference

I'm trying to add records in the Firebase Realtime Database, through an AlertDialog, but the EditText components do not let me abstract the information from the components. Below is the java excerpt .. fab.setOnClickListener(new View.OnClic...
asked by 26.06.2018 / 10:58
1
answer

Counter zeroing for no reason

I have a method in which every time it fires, in addition to performing other operations, a certain counter cont must be incremented and then call another method in which it will check if the counter is greater than zero. The problem...
asked by 11.07.2018 / 19:58
1
answer

Is there a problem in instantiating a Fragment twice?

I have a Fragment that is the first one to open, it's a list of items! After depending on the button clicked on the Cards inside this fragment it opens a screen with a TabLayout with some tabs and one of those tabs is just that first fragment...
asked by 11.07.2018 / 01:42
1
answer

Query in firestore to check item inside a document

I'm using the Firebase Firestore and I need to mount a * query that checks the following data as indicated in the following figure: Because it is in an array , inside my document, I do not know how to mount the query .     
asked by 06.06.2018 / 21:37
1
answer

Open APK settings via API

I'd like to know how to drop the user's APK settings via API , for example, the user put the "Do not ask me again" option, in the permissions of the application, and I open an alertDialog that causes the user to go to the settings of the allo...
asked by 01.06.2018 / 17:01
1
answer

Access a specific component within a listview

I have a list of music with a favorite icon, when the user clicks on this icon I want to change the color of the icon as the action to enjoy. In this framework I have an Activity, a listView in this Activity, an Adapter class that does the in...
asked by 29.05.2018 / 18:51