Category "android"

Recyclerview not displaying items

Before setting the dataset to the adapter, I am getting the dataset from the Room database, and then I set the data to the adapter and set the adapter to the re

How to import org.apache.httpcomponents using Gradle

Just trying to make some POST requests in an Android app. I was testing with HttpClient 4.5.3 (https://hc.apache.org/downloads.cgi) in a standalone script. Ever

How to close a webview app if no activity within 5 minutes?

I am asking this after long searches without help. I created a simple webview app with eclipse. (Sometimes – app opens a web browser depending on the ur

How to make some part of text clickable and some part having different text color in react-native

I am trying to make some portion of text of different color and clickable Here is my code: <Text style = {styles.term_service}>By signing up, you agree

How to use wrap_content with a maximum width?

I am trying to layout a view that should wrap its content, but it shouldn't be more than ~100dp less than its parent width. How can I do that using a RelativeLa

Disable Firebase initialization when running instrumentation tests for modules

I have a multi module project. I want to be able to run the instrumentation tests i'm writing for these modules separately. I am continually running into the

Is it safe to turn on the Developer options in my Android smartphone?

I want to use smartphone instead of Genymotion emulator for debugging the apps that I develop. But I am not sure how safe it is to turn on Developer options. I

Can´t put the background in white on jetpack compose

I'm making a Login page on Jetpack compose. I'm using themes with MaterialTheme. When I choose the background colour as white, it shows me a dark grey colour. I

Pictures with Camera2 API are really dark

I'm working on Android and I'm trying to capture a picture without displaying any preview. I tried to simplify the process by making a class. It's working but a

How to clear textfield value in Jetpack Compose?

I've developed a textInput composable with a trailing icon, and I'd like to clear the textInput when the icon is clicked. How can I access the textInput value,

MediaSessionCompat:Targeting S+ (version 31 and above) requires that one of FLAG_IMMUTABLE or FLAG_MUTABLE be specified when creating a PendingIntent

I'm trying to update my application to Android SDK 31 but I'm having an issue with MediaSessionCompat. I have a MediaService that extends the MediaBrowserServic

onmouseover="this.click()" for Android

I am using this code: <a href="http://www...." onmouseover="this.click()">Link</a> I know that's not working with Android Browser. Which (javas

How can i get my buttons working for Android Studio?

I have an Activity which has two buttons on it. The first button adds the user data to a database and the second takes us to a different activity. The buttons i

Firestore Delete elements from a nested map kotlin

I have a collection, I want to delete 2 documents from this collection Paradas collection and delete it from the nested map too Nested map like in SQL, when yo

How to add Toolbar on Translucent imageview

I need to know, How we can create an toolbar on this imageview just with back button(getSupportActionBar().setDisplayHomeAsUpEnabled(true);). Here is the exampl

Cannot find a version of 'androidx.annotation:annotation' that satisfies the version constraints: Error when run androidTests

I have migrated to androidX recently and updated my targetSdkVersion to 29. After that I received the error when try to run androidTests: Cannot find a version

How to get location updates using FusedLocationProviderClient?

I'm an Android noob and also this is my first post on stackoverflow. I've been trying for some time to find a solution to my problem but couldn't find anything

Android : Failed writing handshake bytes (-1 of 14): Broken pipe

Bascially i'm trying to add the back functionality using (MinSDK is set to 11) getActionBar().setDisplayHomeAsUpEnabled(true); Here are is my function: pub

Is it enough to wrap exported functions of a C library using JNI for it to work using JNI?

I am trying to wrap a C library using JNI. I am interested about the prospects of using any C library using JNI (particularly with Android, but I assumed this c

How to Change App title to Logo in Android Studio

How to change the App Title to a Logo? seems this code is not working to Remove the App Title still in there when i build the app. <style name="AppTheme" pa