id
int64
28.5M
73.8M
title
stringlengths
15
150
question_body
stringlengths
69
39.4k
body_text
stringlengths
6
29.2k
tags
stringlengths
7
120
score
int64
-19
384
creation_date
stringlengths
20
24
year
int64
-1
2.02k
month
int64
-1
12
hour
int64
-1
23
dayofweek
int64
-1
6
view_count
int64
3
367k
answer_count
int64
0
34
body_len
int64
6
29.2k
title_len
int64
15
150
tag_count
int64
1
6
code_block_cnt
int64
0
17
has_code
bool
2 classes
is_unanswered
bool
2 classes
is_popular
bool
2 classes
is_viral
bool
2 classes
is_highly_voted
bool
2 classes
is_negative
bool
2 classes
score_bucket
stringclasses
5 values
60,203,707
Unable To get Activity name from adb command Android 10
<p>I'm trying to get activity name for current focused app on the device by running this command:</p> <pre><code>adb shell "dumpsys window windows | grep -E 'mCurrentFocusApp|mFocusedApp'" </code></pre> <p>It works on older phone with Android 6.0 but on Pixel XL running Android 10 its returns nothing.</p> <p>If I ru...
I'm trying to get activity name for current focused app on the device by running this command: [CODE] It works on older phone with Android 6.0 but on Pixel XL running Android 10 its returns nothing. If I run only dumpsys window windows it returns bunch of unfiltered info which is not very efficient for me.
android|shell|adb|appium-android
2
2020-02-13T08:50:38.987Z
2,020
2
8
3
1,889
3
307
55
4
1
true
false
false
false
false
false
low
60,203,722
getResources().getDrawable(rippleResourceId, null) return rippleDrawable with the wrong color
<p>I use android resourceId <code>android.R.attr.actionBarItemBackground</code> to set ripple.</p> <p>On one item it works fine. On anther item I change the RippleDrawable radius, but then the ripple color changes to pink.</p> <pre><code> int rippleResourceId = // android.R.attr.actionBarItemBackground from curren...
I use android resourceId android.R.attr.actionBarItemBackground to set ripple. On one item it works fine. On anther item I change the RippleDrawable radius, but then the ripple color changes to pink. [CODE] Anyhow had this problem?
android|android-drawable|ripple|rippledrawable
0
2020-02-13T08:51:32.900Z
2,020
2
8
3
55
1
231
93
4
1
true
false
false
false
false
false
zero
60,203,726
how to understand 1:n relation about viewmodel:activity?
<p>I'm studying mvvm. Studying this, I got one question. I heard that viewmodel can have many activities. the point is that one viewmodel used by activities share their datas. because I'm using koin for DI. one viewmodel can share their datas? </p> <pre><code>private val mainViewModel : MainViewModel by viewModel() ...
I'm studying mvvm. Studying this, I got one question. I heard that viewmodel can have many activities. the point is that one viewmodel used by activities share their datas. because I'm using koin for DI. one viewmodel can share their datas? [CODE]
android
0
2020-02-13T08:52:03.327Z
2,020
2
8
3
33
1
247
56
1
1
true
false
false
false
false
false
zero
60,203,770
Moving old VB.NET Device Application (PDA) to C# Android Application
<p>I received the task of converting an old project (made around 2005) which was targeting the <code>PDA devices</code>, to an <code>Android application</code>. The requirements were to change the already-existing code as little as possible. The bad part is that the provided code is written in <code>VB.NET</code> and i...
I received the task of converting an old project (made around 2005) which was targeting the PDA devices , to an Android application . The requirements were to change the already-existing code as little as possible. The bad part is that the provided code is written in VB.NET and it is heavily dependent on the GUI, so no...
c#|android|vb.net|xamarin|porting
0
2020-02-13T08:54:26.933Z
2,020
2
8
3
186
0
1,593
68
5
1
true
true
false
false
false
false
zero
60,203,820
Disable weak SSL cipher suites in react native applications
<p>How to set cipher suites for android and iOS in a react native application. Is there a native implementation needed?</p>
How to set cipher suites for android and iOS in a react native application. Is there a native implementation needed?
android|ios|react-native
1
2020-02-13T08:56:56.930Z
2,020
2
8
3
95
0
116
59
3
0
false
true
false
false
false
false
low
60,203,832
How to Update Apps using In-App update on android 10
<p>I'm trying to update program using in-app update on android and the whole update steps complete successfully on android devices with android version except version 10Q. On this version of android, the update dialog shows and the update of software completes successfully but the progress bar and the page which shows ...
I'm trying to update program using in-app update on android and the whole update steps complete successfully on android devices with android version except version 10Q. On this version of android, the update dialog shows and the update of software completes successfully but the progress bar and the page which shows tha...
android|android-10.0
1
2020-02-13T08:57:17.157Z
2,020
2
8
3
438
1
551
52
2
2
true
false
false
false
false
false
low
60,204,006
How can I achieve tear down in OpenTest framework
<p>I want to turn off the bluetooth at the end of testcase even if any intermidiate step in testcase get failed, it should turn off the bluetooth (i.e. achieve it as teardown step).</p> <p>How to achieve teardown in Opentest?</p>
I want to turn off the bluetooth at the end of testcase even if any intermidiate step in testcase get failed, it should turn off the bluetooth (i.e. achieve it as teardown step). How to achieve teardown in Opentest?
scripting|yaml|android-testing|teardown|opentest
1
2020-02-13T09:06:31.347Z
2,020
2
9
3
64
1
215
49
5
0
false
false
false
false
false
false
low
60,204,070
SendTextMessage doesn't send SMS
<p>I'm not getting any errors, but I don't see any SMS received on my phone either. My code:</p> <pre><code>if (ContextCompat.checkSelfPermission(this, Manifest.permission.SEND_SMS) != PackageManager.PERMISSION_GRANTED) { if (ActivityCompat.shouldShowRequestPermissionRationale( this, Manife...
I'm not getting any errors, but I don't see any SMS received on my phone either. My code: [CODE] I do get the "SENDING SMS" logged in my console, so it means everything is ok regarding permissions, yet no SMS is being sent. What could be the reason of the SMS not being sent? P.S I'm using this random phone number "1234...
android|kotlin|sms
0
2020-02-13T09:09:52.513Z
2,020
2
9
3
33
1
354
32
3
1
true
false
false
false
false
false
zero
60,204,079
Xamarin.Forms Introduction Guid
<p>I finished the functionalities of my app. Now when user first time login i need to make introduction guide on every page, with a short text Myabe some alert. Also on the dialog need chechbox , if he check the guide wont show again. I dont know where to start and how to organize this. Any example, practise to start. ...
I finished the functionalities of my app. Now when user first time login i need to make introduction guide on every page, with a short text Myabe some alert. Also on the dialog need chechbox , if he check the guide wont show again. I dont know where to start and how to organize this. Any example, practise to start. On ...
xamarin.forms|xamarin.android|xamarin.ios
-2
2020-02-13T09:10:20.867Z
2,020
2
9
3
265
1
356
31
3
0
false
false
false
false
false
true
negative
60,204,091
Get event trigger while crash application
<p>I want to open static screen with Restart application option whenever application is crashing. It can from any of screen. Is it possible to trigger application crash event on application level and start new screen? I did not getting anything for this. </p> <p>Any help appreciated. </p>
I want to open static screen with Restart application option whenever application is crashing. It can from any of screen. Is it possible to trigger application crash event on application level and start new screen? I did not getting anything for this. Any help appreciated.
android|events|crash
-1
2020-02-13T09:10:43.860Z
2,020
2
9
3
268
1
273
41
3
0
false
false
false
false
false
true
negative
60,204,126
How to request focus on currently expanded container layout inside nestedscrollview?
<p>I have following layout XML - </p> <pre class="lang-xml prettyprint-override"><code>&lt;?xml version="1.0" encoding="utf-8"?&gt; &lt;androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android" xmlns:app="http://schemas.android.com/apk/res-auto" xmlns:tools="h...
I have following layout XML - [CODE] Which looks like this visually - Each FrameLayout is being inflated with a Fragment containing the content for each stage, meaning this is a long scrollable view - this why I use NestedScrollView. The thing is that when I inflate the needed Fragment I will need to focus on that frag...
android|android-fragments|focus|nestedscrollview
0
2020-02-13T09:12:43.780Z
2,020
2
9
3
196
0
396
84
4
1
true
true
false
false
false
false
zero
60,204,130
Recycler View Items Not loading using firebase
<p><strong>ONStart Code</strong> </p> <pre><code>@Override public void onStart() { super.onStart(); DatabaseReference cartlistref = FirebaseDatabase.getInstance().getReference("Users").child(firebaseUser.getUid()).child("Cart"); FirebaseRecyclerAdapter&lt;Cart, CartViewHolder&gt; adapter = new Fireba...
ONStart Code [CODE] CartViewHolder Code [CODE] } Cart items xml code [CODE] Cart Fragment code [CODE] Firebase Database Structure Here is the firebase database structure I have tried the above code I want to load cart items of a specific user from the firebase database The view is loading but the recycler view items ar...
android|firebase|firebase-realtime-database|firebaseui
0
2020-02-13T09:12:54.483Z
2,020
2
9
3
221
2
387
46
4
4
true
false
false
false
false
false
zero
60,204,210
Application.onCreate() not called in debug build
<p>App.onCreate() is not being called at all in debug builds, but called normally in release builds. I expect it to be called each time I press "Run" button of Android Studio. If I put logs in static{} or onCreate(){} they will not appear in log. Breakpoints also will not be hit. Android Strudio version is 3.5.3 with g...
App.onCreate() is not being called at all in debug builds, but called normally in release builds. I expect it to be called each time I press "Run" button of Android Studio. If I put logs in static{} or onCreate(){} they will not appear in log. Breakpoints also will not be hit. Android Strudio version is 3.5.3 with grad...
android|android-studio-3.5.3
0
2020-02-13T09:17:12.637Z
2,020
2
9
3
333
1
751
48
2
3
true
false
false
false
false
false
zero
60,204,244
Kivy Apk crashes with firebase admin
<p>My apk crashes everytime i run it on my phone. the logcat states the following</p> <pre><code>Traceback (most recent call last): 02-13 14:27:42.571 1453 1517 I python : File "/home/castor/buildozer- env1/DravidianUniversity/.buildozer/android/platform/build-armeabi-v7a/build/python- installs/DuApp/firebase_...
My apk crashes everytime i run it on my phone. the logcat states the following [CODE] My Buildozer.spec The _http.py file with the issue has this import for line 17 [CODE] Buildozer requirements = python3,requests, urllib3, chardet, certifi, idna, kivy==master, kivymd, google.cloud, google.cloud.storage, google.auth, c...
android|firebase|google-cloud-platform|kivy|buildozer
2
2020-02-13T09:19:45.073Z
2,020
2
9
3
245
0
486
36
5
2
true
true
false
false
false
false
low
60,204,392
can' t cast double to int in xml
<p>Android studio 3.6</p> <p>data binding</p> <pre><code>&lt;SeekBar android:id="@+id/seekBar" android:layout_width="0dp" android:layout_height="40dp" android:max='@{model.maxDiscountBonuses}' android:progress="@{(int) model.discountBonuses}" app...
Android studio 3.6 data binding [CODE] But I get error. How cast double ( model.discountBonuses ) to int in xml?
android|android-databinding
0
2020-02-13T09:27:41.960Z
2,020
2
9
3
404
1
112
32
2
1
true
false
false
false
false
false
zero
60,204,683
android.content.res.Resources$NotFoundException · String resource ID #
<p>I get this error:</p> <blockquote> <p>android.content.res.Resources$NotFoundException · String resource ID #0x2040003</p> </blockquote> <p>and in the full stack I saw that it depends on:</p> <pre><code>Resources.java:322android.content.res.Resources.getText </code></pre> <p>I know probably the error is that I ...
I get this error: android.content.res.Resources$NotFoundException · String resource ID #0x2040003 and in the full stack I saw that it depends on: [CODE] I know probably the error is that I call somewhere a setText not passing a string. My problem is that I do not know where the problem occurs. Technically the line of t...
java|android|android-layout
0
2020-02-13T09:40:52.650Z
2,020
2
9
3
709
1
434
70
3
3
true
false
false
false
false
false
zero
60,204,719
How to send timestamp in Handler class?
<p>I have created a handler inside which I have parsed timestamp but i am getting an error as </p> <pre><code>android.view.ViewRootImpl$CalledFromWrongThreadException: Only the original thread that created a view hierarchy can touch its views. </code></pre> <p>I think this is because of the textview which I have defi...
I have created a handler inside which I have parsed timestamp but i am getting an error as [CODE] I think this is because of the textview which I have defined in xml I don't have idea of how to put textview then can. Can anybody help why I am getting this error as I have placed textview inside run() only MainActivity [...
android
0
2020-02-13T09:42:25.873Z
2,020
2
9
3
84
1
341
39
1
3
true
false
false
false
false
false
zero
60,204,750
Center-align horizontally UI items
<p>I'm attempting to create my first Android app and I'd like to horizontally align the items on screen and in rows.</p> <p>I've tried setting the layout_gravity to center_horizontal as shown below however that doesn't appear to do anything. What am I missing?</p> <p>Code:</p> <pre><code>&lt;?xml version="1.0" encod...
I'm attempting to create my first Android app and I'd like to horizontally align the items on screen and in rows. I've tried setting the layout_gravity to center_horizontal as shown below however that doesn't appear to do anything. What am I missing? Code: [CODE] UI:
android|android-layout|android-gridlayout
0
2020-02-13T09:43:28.217Z
2,020
2
9
3
89
1
267
34
3
1
true
false
false
false
false
false
zero
60,204,898
Migrating from Existing Room database to Sqlcipher
<p>My app is currently using room database. I'm tying to migrate to use Sqlcipher data base. I have <code>fallbackToDestructiveMigration()</code> enabled but still throwing the following error </p> <pre><code>java.lang.RuntimeException: Exception while computing database live data. at androidx.room.RoomTrackingLiv...
My app is currently using room database. I'm tying to migrate to use Sqlcipher data base. I have fallbackToDestructiveMigration() enabled but still throwing the following error [CODE] Is there any way to destroy all my database and move to Sqlcipher? i have also tried database.delete("table_name",null,null) command to ...
android|android-room|sqlcipher-android
5
2020-02-13T09:50:29.023Z
2,020
2
9
3
2,927
4
484
50
3
3
true
false
true
false
false
false
low
60,204,919
Continuous Service
<p>I am trying to run the service continously in background but it was closed when the service runs more than 2 hrs. I tried to put android:enabled="true" in manifest and placed START_NOT_STICKY in onStartCommand</p>
I am trying to run the service continously in background but it was closed when the service runs more than 2 hrs. I tried to put android:enabled="true" in manifest and placed START_NOT_STICKY in onStartCommand
android
0
2020-02-13T09:51:34.337Z
2,020
2
9
3
39
0
209
18
1
0
false
true
false
false
false
false
zero
60,204,965
licensing wihtout playstore and internet connection handle year check
<p>I have to implement a licensing mechanism for an android application. Usually one could use the <a href="https://developer.android.com/google/play/licensing/" rel="nofollow noreferrer">licensing-service</a> from the playstore. The catch is that the application will not be published on the playstore and the devices w...
I have to implement a licensing mechanism for an android application. Usually one could use the licensing-service from the playstore. The catch is that the application will not be published on the playstore and the devices where the application will run, will not have access to the internet. In my current solution i us...
java|android|license-key
1
2020-02-13T09:54:20.147Z
2,020
2
9
3
39
0
682
69
3
1
true
true
false
false
false
false
low
60,205,028
Launching flutter app on my physical iPhone via xcode set in portrait mode works, but not when launching through android studio
<p>In my main.dart file where I have declared the device orientation</p> <pre><code>import 'package:flutter/material.dart'; import 'package:flutter/services.dart'; void main() { SystemChrome.setPreferredOrientations([DeviceOrientation.portraitUp]); runApp(Egenkontroll()); } </code></pre> <p>When I launch the app ...
In my main.dart file where I have declared the device orientation [CODE] When I launch the app through xcode on my physical iPhone 7, I get my views in portrait mode which I want, but when I launch in through android studio on my device portrait mode is not enabled, and the views adjust to the devices orientation, whic...
android|ios|xcode|flutter
0
2020-02-13T09:56:55.833Z
2,020
2
9
3
16
1
392
127
4
1
true
false
false
false
false
false
zero
60,205,029
Flutter push route for Taskmanager?
<p>Since in my case it is about an insurance app, I have implemented a local app lock. When opening the app from the task manager a new screen is pushed and the fingerprint is requested.</p> <p>My problem now is that Android and iOS always show a <strong>screenshot of the app in the taskmanager</strong> and therefore ...
Since in my case it is about an insurance app, I have implemented a local app lock. When opening the app from the task manager a new screen is pushed and the fingerprint is requested. My problem now is that Android and iOS always show a screenshot of the app in the taskmanager and therefore maybe also relevant data. He...
android|ios|flutter|dart|taskmanager
0
2020-02-13T09:56:57.537Z
2,020
2
9
3
78
0
737
35
5
1
true
true
false
false
false
false
zero
60,205,038
How to make ListView resizable?
<p>Picture 1</p> <p><a href="https://i.stack.imgur.com/FjCfJ.jpg" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/FjCfJ.jpg" alt="enter image description here"></a></p> <p>Picture 2</p> <p><a href="https://i.stack.imgur.com/UQPPs.jpg" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/UQPPs....
Picture 1 Picture 2 How to make ListView resizable? This ListView is OK. OK ListView 1 Picture OK ListView 2 Picture I have tried all the layouts. That doesn't help. I have a fragment container: [CODE] OK Layout is Search Layout: [CODE] unadabtable Layout : [CODE] As you see Java Code will change Fragments container's ...
java|android|listview
0
2020-02-13T09:57:20.123Z
2,020
2
9
3
50
1
390
31
3
3
true
false
false
false
false
false
zero
60,205,088
Capture layout screen in Android
<p>I am facing an issue. I want to capture screen of a XML layout. I know there is a lot of topic on this question. I read them all. But No one of them helped me. Note: I want to get screen capture of a layout which is not part of the current activity.</p> <p>This my function which is suppose to make capture of the Y l...
I am facing an issue. I want to capture screen of a XML layout. I know there is a lot of topic on this question. I read them all. But No one of them helped me. Note: I want to get screen capture of a layout which is not part of the current activity. This my function which is suppose to make capture of the Y layout (cal...
android|kotlin
1
2020-02-13T10:00:08.253Z
2,020
2
10
3
939
3
530
32
2
1
true
false
false
false
false
false
low
60,205,162
AppAuth Authentication
<p>I want to use <a href="https://openid.github.io/AppAuth-Android/" rel="nofollow noreferrer">AppAuth</a> for my Android application.</p> <p>But as per there documentation, they mention that "WebView is explicitly not supported due to usability and security reasons".</p> <p>I need to do authentication inside the app...
I want to use AppAuth for my Android application. But as per there documentation, they mention that "WebView is explicitly not supported due to usability and security reasons". I need to do authentication inside the app and don't want to redirect to some browser on the phone because of our application requirement. Is t...
android|appauth
-1
2020-02-13T10:03:56.477Z
2,020
2
10
3
155
1
659
22
2
0
false
false
false
false
false
true
negative
60,205,208
Dynamic Feature with appbundle and PROGUARD not working
<p><strong>OVERVIEW:</strong><br> I am facing an issue while accessing the activity of the on-demand dynamic feature module from the base module due to proguard. (most probably I guess)</p> <p><strong>DESCRIPTION:</strong><br> I have implemented an <strong>ON-DEMAND</strong> dynamic feature module with app bundle and ...
OVERVIEW: I am facing an issue while accessing the activity of the on-demand dynamic feature module from the base module due to proguard. (most probably I guess) DESCRIPTION: I have implemented an ON-DEMAND dynamic feature module with app bundle and uploaded on play store. Implemented proguard with custom rules with it...
android|runtime-error|proguard|android-app-bundle|dynamic-feature-module
5
2020-02-13T10:06:50.430Z
2,020
2
10
3
1,210
2
1,443
55
5
1
true
false
false
false
false
false
low
60,205,222
How to convert some functions from an Activity to a Fragment?
<p>I try to convert my activity to a fragment, but I have some problems that occurs. The layout in the HomeFragment is null, so it occurs a crash...</p> <p><strong>My HomeActivity:</strong> </p> <pre><code>public class HomeActivity extends AppCompatActivity { Context mContext; @Override protected void onCreate(Bun...
I try to convert my activity to a fragment, but I have some problems that occurs. The layout in the HomeFragment is null, so it occurs a crash... My HomeActivity: [CODE] My HomeFragment: [CODE] Any ideas?
java|android|android-layout|android-fragments|android-activity
0
2020-02-13T10:07:19.620Z
2,020
2
10
3
58
1
204
61
5
2
true
false
false
false
false
false
zero
60,205,321
How to open an app directly from deeplink if app is installed already?
<p>I want to open app directly without giving propmt open with browser or open with app.</p> <p>I followed some links on stackoverflow did exactly what they did but still no luck.</p> <p>Please help to get it fixed.</p> <pre><code>&lt;activity android:name="com.zappfresh.android.Activity.login.SplashActi...
I want to open app directly without giving propmt open with browser or open with app. I followed some links on stackoverflow did exactly what they did but still no luck. Please help to get it fixed. [CODE]
java|android|deep-linking|appsflyer
1
2020-02-13T10:12:18.437Z
2,020
2
10
3
726
0
205
70
4
1
true
true
false
false
false
false
low
60,205,384
Where is the camera sensor booting setting?
<p>I am studying the camera bring up process in Android with Qualcomm platform. I have searched many bring up tutorial but I just can't figure out one thing: most of the tutorial would focus on the .dtsi setting and the driver porting. But I just can't find out where is the camera sensor boot setting. I can see the i2c...
I am studying the camera bring up process in Android with Qualcomm platform. I have searched many bring up tutorial but I just can't figure out one thing: most of the tutorial would focus on the .dtsi setting and the driver porting. But I just can't find out where is the camera sensor boot setting. I can see the i2c bo...
android|camera|android-source|i2c
0
2020-02-13T10:15:49.790Z
2,020
2
10
3
188
1
457
43
4
0
false
false
false
false
false
false
zero
60,205,623
How to override xml view (that use data Binding) from Library in my project (# Override_Views_Data_Binding_Android )
<p>First of all I have deep search for that and I didn't find any related topic or solution :(</p> <p>I have created a library project and import it as a library in another project, this library in all of its views use Android dataBinding, I need to override a xml view or portion of it(say include) in my project as fo...
First of all I have deep search for that and I didn't find any related topic or solution :( I have created a library project and import it as a library in another project, this library in all of its views use Android dataBinding, I need to override a xml view or portion of it(say include) in my project as follow : prod...
android|xml
1
2020-02-13T10:27:48.483Z
2,020
2
10
3
800
2
927
116
2
4
true
false
false
false
false
false
low
60,205,664
Launch my app once NFC tag is detected, then display result
<p>I've made an application who can read a NFC tag and display his content (once he has been parsed) following this tutorial : <a href="https://medium.com/@ssaurel/create-a-nfc-reader-application-for-android-74cf24f38a6f" rel="nofollow noreferrer">https://medium.com/@ssaurel/create-a-nfc-reader-application-for-android-...
I've made an application who can read a NFC tag and display his content (once he has been parsed) following this tutorial : https://medium.com/@ssaurel/create-a-nfc-reader-application-for-android-74cf24f38a6f except that I had a button who needs to be pushed if you want to scan a NFC tag. Now, in my AndroidManifest.xml...
java|android|android-intent|nfc
1
2020-02-13T10:30:14.007Z
2,020
2
10
3
1,210
1
556
59
4
1
true
false
false
false
false
false
low
60,205,666
Property not being initalized sometimes
<p>I'm trying to handle fragment clicks in FragmentPagerAdapter, but sometimes I'm getting Fatal Exception: kotlin.UninitializedPropertyAccessException, which says that click listener property is not initialized.</p> <p>So here is code for the PagerAdapter</p> <pre><code>class ApplicationListPagerAdapter( fm: Fra...
I'm trying to handle fragment clicks in FragmentPagerAdapter, but sometimes I'm getting Fatal Exception: kotlin.UninitializedPropertyAccessException, which says that click listener property is not initialized. So here is code for the PagerAdapter [CODE] Code how I initialize it in fragment [CODE] And here in onClick ca...
android|kotlin|crash
0
2020-02-13T10:30:16.883Z
2,020
2
10
3
45
1
453
39
3
3
true
false
false
false
false
false
zero
60,205,668
Make View Visible or Gone in adapter on ClickListener
<p>Iam showing the a recyclerview in my app and I want when user click on the recyclerview item a hidden view should be visible to him and on clicking back the item it should gone. My code :</p> <pre><code> holder.parentView.setOnClickListener(v -&gt; { if (viewVisibiltyCheck) { ...
Iam showing the a recyclerview in my app and I want when user click on the recyclerview item a hidden view should be visible to him and on clicking back the item it should gone. My code : [CODE] Iam using Firebase Recycler.I have a boolean check which is when true view become visible of which ever item in list I click ...
android|android-recyclerview|firebaseui|onitemclicklistener
0
2020-02-13T10:30:29.477Z
2,020
2
10
3
511
2
732
53
4
1
true
false
false
false
false
false
zero
60,205,749
best practice to picasso fetch with match parent in android
<p>I'm using Picasso to download pictures and show them in a RecyclerView. I'm trying to prevent the small delay which is happening when I'm scrolling the RecyclerView and Picasso is downloading the new pictures, so I'm using fetch. When I was using exact size for the pictures, it worked well, but now I'm using "match ...
I'm using Picasso to download pictures and show them in a RecyclerView. I'm trying to prevent the small delay which is happening when I'm scrolling the RecyclerView and Picasso is downloading the new pictures, so I'm using fetch. When I was using exact size for the pictures, it worked well, but now I'm using "match par...
android|android-recyclerview|picasso|prefetch
1
2020-02-13T10:34:41.700Z
2,020
2
10
3
57
0
1,112
59
4
4
true
true
false
false
false
false
low
60,205,769
Cannot call onActivityResult in fragment
<p>There is a main class mainActivity. And fragments. </p> <p>In one of the fragments google map. The feature is this:</p> <p>When geolocation is turned off and the application is turned on, a request is sent to allow location detection and the onActivityResult method in the fragment should restart. </p> <p>But the ...
There is a main class mainActivity. And fragments. In one of the fragments google map. The feature is this: When geolocation is turned off and the application is turned on, a request is sent to allow location detection and the onActivityResult method in the fragment should restart. But the onActivityResult method only ...
android
0
2020-02-13T10:35:46.407Z
2,020
2
10
3
167
1
589
40
1
3
true
false
false
false
false
false
zero
60,205,899
Powermockito NotAMockException even though object is a mock
<p>I am trying to mock Uri.parse() to always return a mocked Uri object. Unfortunately I am told, that the object I try to return is not a mocked object, but I am unable to understand why. </p> <p>My code:</p> <pre><code>package com.example.recyclerview; import android.net.Uri; import org.junit.Test; import org.juni...
I am trying to mock Uri.parse() to always return a mocked Uri object. Unfortunately I am told, that the object I try to return is not a mocked object, but I am unable to understand why. My code: [CODE] My build.gradle: [CODE] This is the error I get: [CODE]
android|mockito|android-testing|powermockito
1
2020-02-13T10:42:17.067Z
2,020
2
10
3
2,830
1
257
59
4
3
true
false
true
false
false
false
low
60,205,932
I don't know why array is not recognized when I create a string
<p>I don't know why array is not recognized when I create a string and type the following code to access it in <code>MainActivity.kt</code>:</p> <p><code>var values: Array &lt;String&gt; = resources.getStringArray (R.array.names)</code></p>
I don't know why array is not recognized when I create a string and type the following code to access it in MainActivity.kt : var values: Array <String> = resources.getStringArray (R.array.names)
android|kotlin
0
2020-02-13T10:43:29.947Z
2,020
2
10
3
44
1
195
63
2
0
false
false
false
false
false
false
zero
60,205,946
Adding custom number of array objects to v.findViewById(R.id.iterateHere1) without repeating code
<p>I want to iterate 10 times adding v.findViewById(R.id.iterateHere1) without having to repeat the same syntax. </p> <p>What i first had was:</p> <pre><code>SwitchCompat instance1 = v.findViewById(R.id.iterateHere1); SwitchCompat instance2 = v.findViewById(R.id.iterateHere2); SwitchCompat instance3 = v.findViewById(...
I want to iterate 10 times adding v.findViewById(R.id.iterateHere1) without having to repeat the same syntax. What i first had was: [CODE] the code above was written 10 times. I now have: [CODE] which works for each instance. My question is how do I add 10 R.id.iterateHere1 without repeating code?
java|android
0
2020-02-13T10:44:13.090Z
2,020
2
10
3
59
2
298
97
2
2
true
false
false
false
false
false
zero
60,205,972
jUnit4 - Why testing a suspendable function fails with `RuntimeException: ... AndroidJUnit4 could not be loaded`?
<p>When I test a simple db written with <code>Room</code>, a test that expects an exception fails when dao functions are declared with <code>suspend</code>. The error is:</p> <pre><code>java.lang.RuntimeException: Delegate runner 'androidx.test.internal.runner.junit4.AndroidJUnit4ClassRunner' for AndroidJUnit4 could n...
When I test a simple db written with Room , a test that expects an exception fails when dao functions are declared with suspend . The error is: [CODE] My entity is: [CODE] As you can see, I want to prevent the db to store User with same user_name content. My dao class is: [CODE] And my test are: [CODE] At that point al...
android|kotlin|automated-tests|junit4|androidjunitrunner
2
2020-02-13T10:45:15.803Z
2,020
2
10
3
574
0
950
113
5
9
true
true
false
false
false
false
low
60,205,987
Why not show firebase events on console in Android?
<p>In my application, I want to show some events in Firebase console.<br> I want when the user clicks on some buttons, there should be events shown in firebase console.<br></p> <pre><code>introPage_welcome.setOnClickListener(v -&gt; { Toast.makeText(this, "Show", Toast.LENGTH_SHORT).show(); Bundle bundle = new...
In my application, I want to show some events in Firebase console. I want when the user clicks on some buttons, there should be events shown in firebase console. [CODE] But I can't see this event in firebase console! Where can I see this event in firebase console? Is my above code correct and how can I use events in th...
java|android|firebase|firebase-analytics
0
2020-02-13T10:45:57.330Z
2,020
2
10
3
132
1
339
51
4
1
true
false
false
false
false
false
zero
60,205,993
What does WorkManager do with jobs after hitting JobScheduler limit of 100?
<p>I have scoured the internet for info on this subject but nobody seems to be experiencing this issue anymore.</p> <p>Remember this fun error?</p> <blockquote> <p>java.lang.IllegalStateException: JobScheduler 100 job limit exceeded. We count 101 WorkManager jobs in JobScheduler; we have 50 tracked jobs in our DB;...
I have scoured the internet for info on this subject but nobody seems to be experiencing this issue anymore. Remember this fun error? java.lang.IllegalStateException: JobScheduler 100 job limit exceeded. We count 101 WorkManager jobs in JobScheduler; we have 50 tracked jobs in our DB; our Configuration limit is 50. wit...
java|android|android-jetpack|android-workmanager
4
2020-02-13T10:46:13.077Z
2,020
2
10
3
1,589
2
1,211
75
4
0
false
false
false
false
false
false
low
60,206,001
How to autostart a system app automatically?
<p>I am creating a system app that open when first boot is complated. how can i start this app automatically ? i have the stock rom. is there a file for autostarting apps ?</p>
I am creating a system app that open when first boot is complated. how can i start this app automatically ? i have the stock rom. is there a file for autostarting apps ?
android|android-source
0
2020-02-13T10:46:35.970Z
2,020
2
10
3
743
1
169
44
2
0
false
false
false
false
false
false
zero
60,206,099
my recyclerview has an adapter that is null
<p>i want to get data from a edit text and give to adapter but adapter is null data isnt null because i can toast it but it doesnt show in my model</p> <p>My question now is: when is an adapter null in RecyclerView and what might be the solution to the problem?</p> <p>Please help a green developer; this is my first a...
i want to get data from a edit text and give to adapter but adapter is null data isnt null because i can toast it but it doesnt show in my model My question now is: when is an adapter null in RecyclerView and what might be the solution to the problem? Please help a green developer; this is my first app. Any suggestion ...
java|android
0
2020-02-13T10:52:03.320Z
2,020
2
10
3
55
2
416
43
2
3
true
false
false
false
false
false
zero
60,206,117
Not Generate Android APK Version wise using devops Pipeline after changes version code in build gradle and commit
<p>I have committed code after change Version Code in app Build Gradle File. I have run the pipeline in Azure DevOps. Complete the pipeline task and generate APK on drop folder but When I have published APK play store then got a message from Play store "Apk Version is already Used". </p>
I have committed code after change Version Code in app Build Gradle File. I have run the pipeline in Azure DevOps. Complete the pipeline task and generate APK on drop folder but When I have published APK play store then got a message from Play store "Apk Version is already Used".
android|azure-devops|continuous-integration|continuous-deployment
0
2020-02-13T10:53:17.640Z
2,020
2
10
3
308
1
280
113
4
0
false
false
false
false
false
false
zero
60,206,193
Finding Percentage of color in image OpenCV Android SDK
<p>I'm working on an Android Project for Color Detection using OpenCV Android SDK. I have been able to separate the green and brown mask from the image but i want the percent of green and brown color in the image. I'm not sure how to go about doing that.</p> <pre><code>oImage = imread(pathOfFile); hsvImage = new Mat()...
I'm working on an Android Project for Color Detection using OpenCV Android SDK. I have been able to separate the green and brown mask from the image but i want the percent of green and brown color in the image. I'm not sure how to go about doing that. [CODE] I have a working Python implementation of the solution but no...
java|android|opencv|colors
1
2020-02-13T10:57:59.430Z
2,020
2
10
3
363
1
360
55
4
2
true
false
false
false
false
false
low
60,206,220
Fragment Back Stack
<p>I have 3 fragments like Fragment 1, Fragment 2, Fragment 3</p> <p>These all are opened using replace transaction and api is implemented in OnViewCreated in each fragment.</p> <p>Now when i move from 2nd fragment to 3rd, then 2nd fragment should be removed and there should only 1st fragment in stack.</p> <p>The Pr...
I have 3 fragments like Fragment 1, Fragment 2, Fragment 3 These all are opened using replace transaction and api is implemented in OnViewCreated in each fragment. Now when i move from 2nd fragment to 3rd, then 2nd fragment should be removed and there should only 1st fragment in stack. The Problem occurs is that when i...
android|android-studio|android-fragments|kotlin|back-stack
0
2020-02-13T10:59:31.967Z
2,020
2
10
3
28
1
509
19
5
0
false
false
false
false
false
false
zero
60,206,252
unitTests.returnDefaultValues works when run in gradlew but not in Android Studio
<p>I have a test</p> <pre><code>class MyClassTest{ @Test fun testing() { Log.d("", "") } } </code></pre> <p>By default it will fail as <code>Log</code> is not mocked. However, in order to have it through, we could set</p> <pre><code> testOptions { unitTests.returnDefaultValues = true ...
I have a test [CODE] By default it will fail as Log is not mocked. However, in order to have it through, we could set [CODE] We could run the test smoothly, and through using ./gradlew test in console. However, when I run on Android Studio (i.e. RightClick on the MyClassTest , and select Run 'MyClassTest' , it still er...
android|unit-testing|android-studio|gradle
1
2020-02-13T11:00:51.773Z
2,020
2
11
3
460
1
457
81
4
3
true
false
false
false
false
false
low
60,206,258
Xamarin Android custom action bar - something went wrong error
<p>I was trying to do exactly this tutorial for xamarin android: <a href="https://docs.microsoft.com/pl-pl/xamarin/android/user-interface/controls/tool-bar/replacing-the-action-bar" rel="nofollow noreferrer">https://docs.microsoft.com/pl-pl/xamarin/android/user-interface/controls/tool-bar/replacing-the-action-bar</a> o...
I was trying to do exactly this tutorial for xamarin android: https://docs.microsoft.com/pl-pl/xamarin/android/user-interface/controls/tool-bar/replacing-the-action-bar okay so for the first time my project went good and I even created my custom bar but then I couldn't see the edit, save, overflow icons on the right of...
android|xamarin
0
2020-02-13T11:01:02.093Z
2,020
2
11
3
725
1
3,387
62
2
1
true
false
false
false
false
false
zero
60,206,335
Can't figure out why my ActivityTransition example doesn't work with BroadcastReceiver
<p>I have looked at multiple examples and implementations, I have no more ideas to check. I hope for outside perspective to see if I have missed something. <a href="https://github.com/vegetablesalad/ActivityTransitionTest" rel="nofollow noreferrer">Here is complete project on github for full source</a></p> <p>It doesn...
I have looked at multiple examples and implementations, I have no more ideas to check. I hope for outside perspective to see if I have missed something. Here is complete project on github for full source It doesn't give me any errors or anything, it even shows that I have registered my request successfully. But I don't...
android|broadcastreceiver|activitytransitionapi
0
2020-02-13T11:04:34.197Z
2,020
2
11
3
1,279
4
399
86
3
2
true
false
false
false
false
false
zero
60,206,386
React Native: App crashes on start due to SoLoader issue
<p>I'm having issues with my app on Android (iOS is running fine). Every time I do the build, when I open the application it closes before starting. I have tried many solutions that I have been looking for in Github and here, and I have not been able to solve it yet. </p> <p>The installation is clean, and I have check...
I'm having issues with my app on Android (iOS is running fine). Every time I do the build, when I open the application it closes before starting. I have tried many solutions that I have been looking for in Github and here, and I have not been able to solve it yet. The installation is clean, and I have checked that I am...
javascript|android|reactjs|react-native
7
2020-02-13T11:07:48.367Z
2,020
2
11
3
3,815
1
474
56
4
3
true
false
true
false
false
false
medium
60,206,517
How to use Shared Preferences without extending AppCompatActivity to the class?
<p>I need to use shared preferences in my class but when I use getSharedPreferences method it say "Cannot resolve method 'getSharedPreferences(java.lang.String, int)'. Here's the code:</p> <pre><code> public class FetchData extends AsyncTask&lt;Void, Void, Void&gt; { String data = ""; @Override protect...
I need to use shared preferences in my class but when I use getSharedPreferences method it say "Cannot resolve method 'getSharedPreferences(java.lang.String, int)'. Here's the code: [CODE]
java|android|json|sharedpreferences
-1
2020-02-13T11:14:44.043Z
2,020
2
11
3
59
2
188
79
4
1
true
false
false
false
false
true
negative
60,206,527
Retrofit different call and response json bodies
<p>How can be done retrofit PUT with different types of call and responce bodies? I have a limitation with error. Types must be identical <code>&lt;T&gt; and &lt;T&gt;</code>. Responce bodie can contain int value, but call should not, because when i initialize CallBody object with int value, it already contain n1=0, an...
How can be done retrofit PUT with different types of call and responce bodies? I have a limitation with error. Types must be identical <T> and <T> . Responce bodie can contain int value, but call should not, because when i initialize CallBody object with int value, it already contain n1=0, and send this parameter to se...
java|android|retrofit2
0
2020-02-13T11:15:20.867Z
2,020
2
11
3
66
1
332
48
3
1
true
false
false
false
false
false
zero
60,206,597
How do I implement dynamic API handling?
<p>So I was working on a project where there are many API is going to be used like 5 different ones, all from different hostnames. For this I am using Volley for the requests. Now my question is how do I get the values produced by the different APIs, with different JSON Output.</p> <p>The Sample Scenario: I need to g...
So I was working on a project where there are many API is going to be used like 5 different ones, all from different hostnames. For this I am using Volley for the requests. Now my question is how do I get the values produced by the different APIs, with different JSON Output. The Sample Scenario: I need to get the name ...
android|android-volley
0
2020-02-13T11:19:50.670Z
2,020
2
11
3
324
1
802
40
2
3
true
false
false
false
false
false
zero
60,206,640
React native app that can control other app
<p>I want to make an app that can control access to all installed apps. Is that possible using react native? I want to deploy to android device.</p> <p>the idea is: some admin user can define apps that are permanently accessible all apps, that are not defined as permanently accessible are accessible for only x minutes...
I want to make an app that can control access to all installed apps. Is that possible using react native? I want to deploy to android device. the idea is: some admin user can define apps that are permanently accessible all apps, that are not defined as permanently accessible are accessible for only x minutes total per ...
android|react-native
1
2020-02-13T11:22:27.737Z
2,020
2
11
3
183
0
510
43
2
0
false
true
false
false
false
false
low
60,206,648
Manifest merger failed on dependency com.google.firebase:firebase-analytics:17.2.2
<p>I'm trying to update my project to the lastest firebase versions but I got this error: Manifest merger failed : </p> <pre><code>Attribute application@appComponentFactory value=(android.support.v4.app.CoreComponentFactory) from [com.android.support:support-compat:28.0.0] AndroidManifest.xml:22:18-91 is also pre...
I'm trying to update my project to the lastest firebase versions but I got this error: Manifest merger failed : [CODE] on implementation 'com.google.firebase:firebase-analytics:17.2.2' also my project has this dependencies from google and firebase would it effect? [CODE] and here gradle and google services versions cla...
android|firebase|gradle|build.gradle
1
2020-02-13T11:22:53.330Z
2,020
2
11
3
523
1
407
82
4
2
true
false
false
false
false
false
low
60,206,742
Can not update TextView in Xamarin C#
<p>I have a problem to update a TextView in Xamarin/Android.</p> <p>I have created a tabbed application that is the default tabbed application in Xamarin.</p> <p>When I click on the "Resource.Id.nav_camera" I am trying to change the textview that by default in the App says: "Hello World!" to "Hello World2!" but the t...
I have a problem to update a TextView in Xamarin/Android. I have created a tabbed application that is the default tabbed application in Xamarin. When I click on the "Resource.Id.nav_camera" I am trying to change the textview that by default in the App says: "Hello World!" to "Hello World2!" but the textview is not upda...
c#|android|xamarin|textview
2
2020-02-13T11:27:54.053Z
2,020
2
11
3
553
1
531
37
4
2
true
false
false
false
false
false
low
60,206,901
Recycler view with sqlite kotlin
<p>I am trying to delete the SQLite DB notes and using kotlin and rendering is done by recyclerview. But my delete won't do the job, it's not deleting. Very new to this please help. </p> <p>holder class</p> <pre><code>class MyHolder (Itemview : View):RecyclerView.ViewHolder(Itemview) { var titleHolder: TextView = It...
I am trying to delete the SQLite DB notes and using kotlin and rendering is done by recyclerview. But my delete won't do the job, it's not deleting. Very new to this please help. holder class [CODE]
android|sqlite|kotlin|android-recyclerview|adapter
0
2020-02-13T11:35:58.293Z
2,020
2
11
3
301
1
198
32
5
1
true
false
false
false
false
false
zero
60,206,902
How to save data when i press back button
<p>I have made an app in kotlin through the android studio, Now I have used ViewModels to save UI data while phone rotation(configuration change), i also used onSaveInstanceState to save data while pressing back button but it's not working.</p> <p>The code is below</p> <p><strong>fragOne.kt</strong></p> <pre><code>c...
I have made an app in kotlin through the android studio, Now I have used ViewModels to save UI data while phone rotation(configuration change), i also used onSaveInstanceState to save data while pressing back button but it's not working. The code is below fragOne.kt [CODE] } ViewModelclass [CODE] } please tell me becau...
android|android-studio|kotlin|onsaveinstancestate
1
2020-02-13T11:36:19.387Z
2,020
2
11
3
1,899
1
358
41
4
2
true
false
false
false
false
false
low
60,207,098
Different Uri for same File
<p>Don't know why for the same file/gallery/emulator i get different uris every time i try to acces a file. I tried with a different project and these are the results i obtained.</p> <p>1º ATTEMPT</p> <pre><code>content://com.android.providers.media.documents/document/video%3A32 content://com.google.android.apps.phot...
Don't know why for the same file/gallery/emulator i get different uris every time i try to acces a file. I tried with a different project and these are the results i obtained. 1º ATTEMPT [CODE] 2º ATTEMPT [CODE] As you see, in the second project i get different uri every time i try to access the same file.The type of f...
android|uri|media|mediastore
2
2020-02-13T11:47:29.980Z
2,020
2
11
3
130
0
413
27
4
2
true
true
false
false
false
false
low
60,207,144
How to retry method with button click?
<p>I use an observable method that has dialog and I want to send retry message when failed. But after button clicked, it doesn't send retry message. How can I do it?</p> <pre><code>getCompositeDisposable().add(repository.method().flatMap(resource -&gt; { getNavigator().showDialog(new Fragment.Listener() { ...
I use an observable method that has dialog and I want to send retry message when failed. But after button clicked, it doesn't send retry message. How can I do it? [CODE]
android|dialog|observable|buttonclick|retrywhen
1
2020-02-13T11:49:39.180Z
2,020
2
11
3
142
0
169
38
5
1
true
true
false
false
false
false
low
60,207,370
How to test Intent's Bundle using Mockk?
<p>I would like to test a custom handler class which is starting a new <code>Activity</code>. I would like to test the <code>Intent</code>'s <code>Bundle</code> if contains the pre defined parameters.</p> <p><strong>The test class</strong>:</p> <pre><code>@MockK lateinit var activity: ActivityCalendar @Before fun se...
I would like to test a custom handler class which is starting a new Activity . I would like to test the Intent 's Bundle if contains the pre defined parameters. The test class : [CODE] The code above is crashing at line: val bundle = intent.extras!! but it shouldn't. The class that I want to test : [CODE] I debugged th...
android|unit-testing|mockk
3
2020-02-13T12:01:24.190Z
2,020
2
12
3
868
0
465
40
3
2
true
true
false
false
false
false
low
60,207,413
How to fix the Camera API?
<p>Hi i am trying to open a camera and i saw the documentation of android on how to use it.</p> <p>so i just copy paste it to my code, and i already set the permission of it, but when i am clicking the button, the camera is not opening.</p> <pre><code> @Override protected void onActivityResult(int requestCode, i...
Hi i am trying to open a camera and i saw the documentation of android on how to use it. so i just copy paste it to my code, and i already set the permission of it, but when i am clicking the button, the camera is not opening. [CODE] [CODE] [CODE] Manifest.xml [CODE] i really don't know what to do, there is no error, d...
java|android|camera-api
0
2020-02-13T12:03:34.540Z
2,020
2
12
3
97
1
396
26
3
5
true
false
false
false
false
false
zero
60,207,528
Uploading multiple images to a server
<p>Almost its going a second week that I'm trying to upload multiple images on server as I can send single image on server but I don't know how to do it with multiple images. By following <a href="https://www.simplifiedcoding.net/android-upload-image-using-php-mysql-android-studio/" rel="nofollow noreferrer">this link<...
Almost its going a second week that I'm trying to upload multiple images on server as I can send single image on server but I don't know how to do it with multiple images. By following this link I can upload only single image to the server but how can I upload multiple images to the server? I've created a new project w...
android|mysql|image|server
0
2020-02-13T12:09:32.133Z
2,020
2
12
3
44
0
703
37
4
2
true
true
false
false
false
false
zero
60,207,600
Admob shows test ads but not real ads in beta version?
<p>i uploaded my app in beta version, my app is showing test interstitial ads instead of real ads but banner ads working fine. please anyone tell me is there any rule BETA show test ads instead of real ads whether banner is showing real.</p>
i uploaded my app in beta version, my app is showing test interstitial ads instead of real ads but banner ads working fine. please anyone tell me is there any rule BETA show test ads instead of real ads whether banner is showing real.
android|admob
0
2020-02-13T12:13:54.153Z
2,020
2
12
3
75
1
234
54
2
0
false
false
false
false
false
false
zero
60,207,607
What are ways to transfer data between activities
<p>I am reading User class from database with this code :</p> <pre><code> mDatabase.orderByChild("name") .equalTo(s1) .addValueEventListener(new ValueEventListener() { @Override public void onDataChange(DataSnapshot dataS...
I am reading User class from database with this code : [CODE] I want to display content of User object in a new activity. How do I pass User object to new activity?
android|android-activity
-2
2020-02-13T12:14:10.173Z
2,020
2
12
3
64
2
164
49
2
1
true
false
false
false
false
true
negative
60,207,650
Appium with Selenium Eclipse
<p>The below code seems to be working fine in one device but while trying with another device ( that has the same android version ) the click happens at another location </p> <pre><code>list = (AndroidElement)driver.findElement(MobileBy.AndroidUIAutomator("new UiScrollable(new UiSelector()).scrollIntoView("+ "new U...
The below code seems to be working fine in one device but while trying with another device ( that has the same android version ) the click happens at another location [CODE] The above code when we try with one device is clicking on "display" which is as expected While we try it with another device its clicking at a dif...
android|eclipse|selenium|appium
4
2020-02-13T12:16:27.870Z
2,020
2
12
3
178
0
335
28
4
1
true
true
false
false
false
false
low
60,207,769
ADB command to resume android app to foreground without knowing activity
<p>I want to bring a background application to the foreground by its package name without knowing the current activity.</p>
I want to bring a background application to the foreground by its package name without knowing the current activity.
android|adb|appium
1
2020-02-13T12:22:39.760Z
2,020
2
12
3
1,401
2
116
72
3
0
false
false
false
false
false
false
low
60,207,804
Android phone caches network response
<p>I experienced a strange issue in my Android app where one of the phone seems to cache the network calls. The app seems to return the same response irrespective of which user I try to login with.</p> <p>When I try to inspect the request I can see the old response being received. But when I try to replay the request ...
I experienced a strange issue in my Android app where one of the phone seems to cache the network calls. The app seems to return the same response irrespective of which user I try to login with. When I try to inspect the request I can see the old response being received. But when I try to replay the request as is in a ...
android|samsung-mobile
0
2020-02-13T12:24:12.537Z
2,020
2
12
3
102
0
718
37
2
0
false
true
false
false
false
false
zero
60,207,830
Kotlin DSL adding Kotlin SourceSets doesn't affect
<p>I am adding <code>Kotlin</code> <code>SourceSets</code> to my project but I am unable to see <code>Kotlin</code> source in the <code>Project layout</code>.</p> <blockquote> <p>What I have in build.gradle.kts</p> </blockquote> <pre><code>sourceSets { getByName("main").java.srcDirs("src/main/kotlin") } </code>...
I am adding Kotlin SourceSets to my project but I am unable to see Kotlin source in the Project layout . What I have in build.gradle.kts [CODE] What I see in the project path And also when I run ./gradlew sourcesets task I see 2 sources for the module. I googled it but couldn't find useful info. How can I have kotlin i...
android|kotlin|gradle-kotlin-dsl|source-sets
0
2020-02-13T12:25:24.217Z
2,020
2
12
3
945
1
344
50
4
1
true
false
false
false
false
false
zero
60,207,852
How do I get a single document from a Firestore query within a loop
<p>In my app I am running a <code>for</code> loop in my Firestore query. this query itself is meant to only return documents where the criteria of brand and location are met (String values) AND where a counter (<code>"deal_number"</code>) located in the document is > than a comparative counter in users collections (<co...
In my app I am running a for loop in my Firestore query. this query itself is meant to only return documents where the criteria of brand and location are met (String values) AND where a counter ( "deal_number" ) located in the document is > than a comparative counter in users collections ( Login.deal_number ). So essen...
kotlin|google-cloud-firestore|android-notifications
0
2020-02-13T12:26:48.790Z
2,020
2
12
3
96
0
1,120
67
3
1
true
true
false
false
false
false
zero
60,207,947
How to add the menu items using android navigation component
<p>I'm trying to add a menu to the the toolbar of the application</p> <p>My app is based on <strong>single-activity multi-fragment</strong></p> <p>and I'm using the navigation component my app style is:</p> <pre><code>&lt;style name="AppTheme" parent="Theme.AppCompat.Light.DarkActionBar"&gt; &lt;!-- Customize yo...
I'm trying to add a menu to the the toolbar of the application My app is based on single-activity multi-fragment and I'm using the navigation component my app style is: [CODE] and I'm configuring the grapp in the MainActivity's onCreate method like that: [CODE] My question is how to add different custom menu items for ...
android|menuitem|android-navigation
2
2020-02-13T12:32:22.123Z
2,020
2
12
3
1,636
1
440
60
3
2
true
false
false
false
false
false
low
60,208,013
Dynamic Tabs with dynamic data in viewpager fragment
<p><a href="https://i.stack.imgur.com/VL4gG.jpg" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/VL4gG.jpg" alt="enter image description here"></a>I need a help. I am developing dynamic tabs with dynamic data in viewpager fragment's list. Somehow i got the dynamic tabs and hit API in placeholder fragment ...
I need a help. I am developing dynamic tabs with dynamic data in viewpager fragment's list. Somehow i got the dynamic tabs and hit API in placeholder fragment to get the recyclerview list. there are two issue. 1. design is overlapping the tabs and 2. its loading 3rd id data first. here is the code. here is main class [...
android|android-fragments|dynamic|android-tablayout
0
2020-02-13T12:35:43.127Z
2,020
2
12
3
550
0
449
52
4
4
true
true
false
false
false
false
zero
60,208,068
how to show pdf from Internal Storage Custom folder in xmarine android c# App?
<p>I want to show pdf file after downloading (from Internal Storage Custom folder) in my app. I want users can choice their preferred apps to open it. I have used the below mention code but it is not working. How can I do this? <a href="https://i.stack.imgur.com/W8cKp.jpg" rel="nofollow noreferrer"><img src="https://i....
I want to show pdf file after downloading (from Internal Storage Custom folder) in my app. I want users can choice their preferred apps to open it. I have used the below mention code but it is not working. How can I do this? [CODE]
c#|android|pdf|storage|androidpdfviewer
0
2020-02-13T12:38:26.633Z
2,020
2
12
3
62
1
231
78
5
1
true
false
false
false
false
false
zero
60,208,141
Light sensor emulation with camera
<p>I have already programmed the camera with the camera2 API, but when I execute the onCaptureCompleted or onCaptureProgressed method, the values ​​get null except LENS_FOCAl_LENGTH.</p> <pre><code>@Override public void onCaptureCompleted(@NonNull CameraCaptureSession session, @NonNull CaptureRequest request, @Non...
I have already programmed the camera with the camera2 API, but when I execute the onCaptureCompleted or onCaptureProgressed method, the values ​​get null except LENS_FOCAl_LENGTH. [CODE] enter image description here
java|android|camera|android-camera2
0
2020-02-13T12:42:01.663Z
2,020
2
12
3
139
1
215
34
4
1
true
false
false
false
false
false
zero
60,208,148
Do Firebase Device Tests Run sequentially or Concurrently?
<p>Im currently testing an app using Firebase physical devices and I am wondering if I test it over two or more devices (S9 and One plus) would the devices be tested sequentially or in parallel. If in parallel is there a way to change it to sequentially?</p>
Im currently testing an app using Firebase physical devices and I am wondering if I test it over two or more devices (S9 and One plus) would the devices be tested sequentially or in parallel. If in parallel is there a way to change it to sequentially?
android|firebase|android-espresso|firebase-test-lab
0
2020-02-13T12:42:34.317Z
2,020
2
12
3
69
1
251
58
4
0
false
false
false
false
false
false
zero
60,208,151
Firebase not sending verification code to phone the second time
<p>In my app, I'm using Firebase to verify the user's phone number. However, the verification system is inconsistent and sends the OTP only the first time. For example, I get the OTP when I'm signing in for the first time, but if I sign out and try to sign in again, I don't get the OTP.</p> <p>This is the activity whe...
In my app, I'm using Firebase to verify the user's phone number. However, the verification system is inconsistent and sends the OTP only the first time. For example, I get the OTP when I'm signing in for the first time, but if I sign out and try to sign in again, I don't get the OTP. This is the activity where the user...
android|firebase|firebase-authentication
10
2020-02-13T12:42:42.897Z
2,020
2
12
3
25,686
6
450
63
3
1
true
false
true
true
true
false
medium
60,208,242
Xamarin Custom Renderer Event not Firing from TabbedPage
<p>I have been struggling with a problem for quite some time now, I'm fairly new to xamarin. I have a script containing multiple custom renderers. My first Renderers click event works perfectly, but every other click event does not, they don't even get called. Below is my Renderer scripts code</p> <pre><code>[assembly...
I have been struggling with a problem for quite some time now, I'm fairly new to xamarin. I have a script containing multiple custom renderers. My first Renderers click event works perfectly, but every other click event does not, they don't even get called. Below is my Renderer scripts code [CODE] and in my TabbedPage ...
android|xamarin|custom-renderer
0
2020-02-13T12:47:54.163Z
2,020
2
12
3
192
1
435
56
3
1
true
false
false
false
false
false
zero
60,208,255
Android Widget View in Fragment getting IllegalStateException in Rx Subscription
<p>I have a couple IllegalStateExceptions which are occurring at times due to <code>this.progressContainer</code> being null. In general that seems basically impossible but I'm worried I'm making a false assumption on how these lifecycle events are working. I feel like its not necessary to do this defensive checking ...
I have a couple IllegalStateExceptions which are occurring at times due to this.progressContainer being null. In general that seems basically impossible but I'm worried I'm making a false assumption on how these lifecycle events are working. I feel like its not necessary to do this defensive checking in this case, as i...
android|kotlin|rx-java|reactive-programming
0
2020-02-13T12:48:38.693Z
2,020
2
12
3
55
0
744
80
4
2
true
true
false
false
false
false
zero
60,208,318
Ideavim writes letter "u" instead of adding a line when typing <cr> (hitting return button)
<p>In Android Studio 3.5.3 (using Ideavim 0.55) when in insert mode I hit return, it types the letter "u". How do I disable it?</p> <p>Here is my .vimrc file: <a href="https://github.com/tomasbaran/My-Bash-Setup/blob/master/.vimrc" rel="nofollow noreferrer">https://github.com/tomasbaran/My-Bash-Setup/blob/master/.vimr...
In Android Studio 3.5.3 (using Ideavim 0.55) when in insert mode I hit return, it types the letter "u". How do I disable it? Here is my .vimrc file: https://github.com/tomasbaran/My-Bash-Setup/blob/master/.vimrc
macos|android-studio|mapping|ideavim
0
2020-02-13T12:51:54.890Z
2,020
2
12
3
16
1
211
91
4
0
false
false
false
false
false
false
zero
60,208,339
Checking if file exists in Kotlin without creating the file
<p>Relevant answers checked but they don't exactly address my situation.</p> <p>At the beginning of my application it is checked if a file exists by the code: <code>someFile.exists()</code>. However I found out that if the user navigates inside the app using menu items and back button the code behaves like <code>someF...
Relevant answers checked but they don't exactly address my situation. At the beginning of my application it is checked if a file exists by the code: someFile.exists() . However I found out that if the user navigates inside the app using menu items and back button the code behaves like someFile is created -although the ...
android|kotlin|sharedpreferences|file-exists
1
2020-02-13T12:52:52.557Z
2,020
2
12
3
680
0
662
59
4
0
false
true
false
false
false
false
low
60,208,358
Where to place onClickListener
<p>I have buttons in the rows of a RecyclerView within a Fragment within an Activity. Is it best to place the onClickListener and logic in the RecyclerView adapter or within the Fragments onActivityCreated method or the in the Activity? </p>
I have buttons in the rows of a RecyclerView within a Fragment within an Activity. Is it best to place the onClickListener and logic in the RecyclerView adapter or within the Fragments onActivityCreated method or the in the Activity?
android|android-fragments|android-recyclerview
0
2020-02-13T12:53:32.053Z
2,020
2
12
3
34
3
233
30
3
0
false
false
false
false
false
false
zero
60,208,362
Volley DELETE request throws 400 BAD REQUEST
<p>I try to send a DELETE request to my server, but I get a 400 bad request error code back. I search a lot but I can't find any solution that help. When I try it with Postman, the request works fine.</p> <p>This is how the curl command from Postman looks: </p> <pre><code>curl --location --request DELETE 'https://bla...
I try to send a DELETE request to my server, but I get a 400 bad request error code back. I search a lot but I can't find any solution that help. When I try it with Postman, the request works fine. This is how the curl command from Postman looks: [CODE] This is my Java code: [CODE] I also try it without to set the Cont...
java|android|json|request|android-volley
0
2020-02-13T12:53:38.893Z
2,020
2
12
3
252
1
485
44
5
2
true
false
false
false
false
false
zero
60,208,402
MainActivity not reading Subfolders Android Java
<p>I created an application that uses the Room, ViewModel approach. I created subfolders to organize my code as shown in the photo: <a href="https://i.stack.imgur.com/WAUMt.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/WAUMt.png" alt="MainActivity.Java"></a></p> <p>How do I make my Main Activity r...
I created an application that uses the Room, ViewModel approach. I created subfolders to organize my code as shown in the photo: How do I make my Main Activity recognize the code created in the subfolders? I tried invalidate caches/restart already and tried many times to rebuild the project.
android|android-studio
0
2020-02-13T12:56:21.173Z
2,020
2
12
3
56
3
292
48
2
0
false
false
false
false
false
false
zero
60,208,436
How to send local notification everyday at specific time in Android (API > 26)
<p>I searched Stackoverflow and Google but no answers.</p> <p>I can't find how to send notifications at specific time that occur everyday. Below API level of 26, it's not a problem. How can I do it in API>26?</p> <p>I know that i need to create a channel to create notifications in API>26 but how to set it to repeat e...
I searched Stackoverflow and Google but no answers. I can't find how to send notifications at specific time that occur everyday. Below API level of 26, it's not a problem. How can I do it in API>26? I know that i need to create a channel to create notifications in API>26 but how to set it to repeat everyday?
java|android|notifications|android-notifications
2
2020-02-13T12:58:10.403Z
2,020
2
12
3
1,445
1
309
78
4
0
false
false
false
false
false
false
low
60,208,471
Unknown reason for FileNotFoundException
<p>I have a method : <code>copyImage</code> thats take two string arguments ( <strong>source</strong> image , <strong>target</strong> image) inside <code>ImageLoder</code>class as shown below:</p> <pre><code>public Class ImageLoader{ public boolean copyIMAGE(String source, String target){ File sourceFile=ne...
I have a method : copyImage thats take two string arguments ( source image , target image) inside ImageLoder class as shown below: [CODE] the method fired after copyButton get clicked in MainActivity class and copyImage return false [CODE] The method return false and i get FileNotFound exception . Ps: the source file e...
android|file
0
2020-02-13T13:00:18.327Z
2,020
2
13
3
31
1
372
40
2
2
true
false
false
false
false
false
zero
60,208,595
Android Zoom In Animation
<p>When i Zoom in on a PDF View with an animation i cannot zoom out with pinch zoom after, when I don't use the animation i can easily zoom in and zoom out with pinch zoom. I can't see the problem, is there some code that can simulate a pinch zoom to certain X and Y values?</p> <p>My Zoom xml file</p> <pre><code>&lt;...
When i Zoom in on a PDF View with an animation i cannot zoom out with pinch zoom after, when I don't use the animation i can easily zoom in and zoom out with pinch zoom. I can't see the problem, is there some code that can simulate a pinch zoom to certain X and Y values? My Zoom xml file [CODE]
android|zooming|pinchzoom
0
2020-02-13T13:06:35.890Z
2,020
2
13
3
201
1
295
25
3
1
true
false
false
false
false
false
zero
60,208,659
My NFC Scan application starts only if NFC Type 2
<p>I've made an NFC application who can reads NFC tag. It works well. (With all types)</p> <p>But since yesterday i'm trying to start automatically my app once a NFC tag is maintained against my device. </p> <p>So i've updated my Manifest :</p> <pre><code> &lt;activity android:name=".MainActivity" android:scr...
I've made an NFC application who can reads NFC tag. It works well. (With all types) But since yesterday i'm trying to start automatically my app once a NFC tag is maintained against my device. So i've updated my Manifest : [CODE] Then, here is my nfc_tech_filter.xml [CODE] And surprise, it works only when I hold a NFC ...
java|android|nfc|mifare
0
2020-02-13T13:10:38.310Z
2,020
2
13
3
129
1
747
49
4
4
true
false
false
false
false
false
zero
60,208,703
Android: How can I create a RecyclerView where I can freely drag and drop an item to do certain things?
<p>I am facing a tricky task where I have a horizontal RecyclerView where the user should be able to grab the first item and freely move it. If he drops it in two certain areas, it will be added into the other two lists respectively.</p> <p>Here is a diagram for the explicit task:</p> <p><a href="https://i.stack.imgu...
I am facing a tricky task where I have a horizontal RecyclerView where the user should be able to grab the first item and freely move it. If he drops it in two certain areas, it will be added into the other two lists respectively. Here is a diagram for the explicit task: Basically the user can only grab the first item ...
android|animation|kotlin|android-recyclerview|drag-and-drop
1
2020-02-13T13:12:43.397Z
2,020
2
13
3
300
1
1,103
103
5
0
false
false
false
false
false
false
low
60,208,749
Center-align horizontally UI items on the same row
<p>I'm attempting to create my first Android app and I'd like to center horizontally align two elements on the same row so that they appear on top of each other.</p> <p>I've tried setting the layout_row to the same value and gravity to center however that shows the ChartView and not the (serviceScore) TextView. If I r...
I'm attempting to create my first Android app and I'd like to center horizontally align two elements on the same row so that they appear on top of each other. I've tried setting the layout_row to the same value and gravity to center however that shows the ChartView and not the (serviceScore) TextView. If I remove the C...
android|android-layout|android-gridlayout
0
2020-02-13T13:14:50.340Z
2,020
2
13
3
79
1
505
50
3
1
true
false
false
false
false
false
zero
60,208,909
How to iterate on a list of object but in specific field Kotlin
<p>Lets say that i have a list of AccountDto (getContats() -> List)that each has a column accountId </p> <pre><code>List&lt;Int&gt; list = accountsDao.getContactIds() </code></pre> <p>and i have a list of MessageDto, where messageDto has a field 'fromAccountId'. I want to loop through the messageList and find what ne...
Lets say that i have a list of AccountDto (getContats() -> List)that each has a column accountId [CODE] and i have a list of MessageDto, where messageDto has a field 'fromAccountId'. I want to loop through the messageList and find what new fromAccountId i have that dont exist in my DB. [CODE] Is there an elegant way to...
android|kotlin|iteration|dto
1
2020-02-13T13:23:42.770Z
2,020
2
13
3
978
1
342
63
4
2
true
false
false
false
false
false
low
60,209,150
Support for port number in hostname in Certificate Pinner
<pre><code>private static final String Sha256="sha256/hxvqB+muy3jP5UZQ4CrRIr7oK0DourlxQCzr7UpTTVY=" ; final static CertificatePinner certificate = new CertificatePinner.Builder().add("172.18.10.10:8090",Sha256).build(); </code></pre> <p>When i run the above code , the exception says</p> <p><code>java.lang.IllegalAr...
[CODE] When i run the above code , the exception says java.lang.IllegalArgumentException: Invalid pattern: 172.18.10.10:8090 But i never get the same error , when i put the hostname without any port number i.e just 172.18.10.10 The CertificatePinner is not accepting hostnames with portnumber i guess , due to the validi...
java|android|okhttp
0
2020-02-13T13:37:04.003Z
2,020
2
13
3
359
1
426
57
3
1
true
false
false
false
false
false
zero
60,209,253
How can I change app colors programmatically?
<p>I want change to my primary colors at runtime. I can change it with custom themes and colors. But I want to change my color from service result not static styles code. Is there any way to change colors.xml programmatically.</p> <p>I find a solution but that's deprecated now: <a href="https://stackoverflow.com/a/341...
I want change to my primary colors at runtime. I can change it with custom themes and colors. But I want to change my color from service result not static styles code. Is there any way to change colors.xml programmatically. I find a solution but that's deprecated now: https://stackoverflow.com/a/34178187/6155031
android|resources|android-resources
0
2020-02-13T13:42:16.403Z
2,020
2
13
3
374
1
313
45
3
0
false
false
false
false
false
false
zero
60,209,276
Kotlin how to get and open a video
<p>New to Kotlin and i'm trying to simple get any video from gallery and open into device's default app player.</p> <p>My function to get all videos. It seens to work well, but the returned Uri is like 'content://...', i don't know if this is the right or it should be something like 'file://...'</p> <pre><code>privat...
New to Kotlin and i'm trying to simple get any video from gallery and open into device's default app player. My function to get all videos. It seens to work well, but the returned Uri is like 'content://...', i don't know if this is the right or it should be something like 'file://...' [CODE] Then i try to open the Uri...
android|file|kotlin
1
2020-02-13T13:43:31.660Z
2,020
2
13
3
818
1
541
34
3
2
true
false
false
false
false
false
low
60,209,436
How can I take release build with flutter using the existing keystore file?
<p>I have created an Android native application first. Then I uploaded into play store. Then afterwards I created an application using flutter. I used same package name and all. Then now am trying to upload new flutter app to the play store. So am not able to upload when am trying to upload it is showing <code>Your And...
I have created an Android native application first. Then I uploaded into play store. Then afterwards I created an application using flutter. I used same package name and all. Then now am trying to upload new flutter app to the play store. So am not able to upload when am trying to upload it is showing Your Android App ...
android|flutter
0
2020-02-13T13:51:22.567Z
2,020
2
13
3
1,439
1
522
75
2
0
false
false
false
false
false
false
zero
60,209,526
Launching Surface Duo Emulator Shows "ACPI" error and emulator does not start
<p>When launching the beta Surface Duo emulator, the emulator appears as a blank screen and scrolls an error about ACPI in the status window. </p> <p>I have already followed the Xamarin instructions for getting the emulator launching:</p> <p><a href="https://docs.microsoft.com/en-us/dual-screen/android/use-emulator?t...
When launching the beta Surface Duo emulator, the emulator appears as a blank screen and scrolls an error about ACPI in the status window. I have already followed the Xamarin instructions for getting the emulator launching: https://docs.microsoft.com/en-us/dual-screen/android/use-emulator?tabs=windows
android|visual-studio|xamarin|emulation|surface-duo
1
2020-02-13T13:56:12.257Z
2,020
2
13
3
151
1
302
77
5
0
false
false
false
false
false
false
low
60,209,548
How to use `onSaveInstanceState`?
<h2>What do I want to achieve?</h2> <ul> <li>I want to save values of <code>x</code>, <code>y</code> and <code>score</code>, so when the user rotates the screen then the values are retrieved and not regenerated.</li> </ul> <p><hr /></p> <h2>What do I have?</h2> <ol> <li>Probably correct <code>onSaveInstanceState</c...
What do I want to achieve? I want to save values of x , y and score , so when the user rotates the screen then the values are retrieved and not regenerated. What do I have? Probably correct onSaveInstanceState code that isn't working probably because of some @Override coming into conflict with it What do I need? Some f...
java|android|oncreate|onsaveinstancestate
0
2020-02-13T13:57:42.810Z
2,020
2
13
3
268
2
479
33
4
2
true
false
false
false
false
false
zero
60,209,555
How to getchildren text and set that in list view
<p>I've been trying to get the children list in list view in my dashboard. Whenever I click users I need this children to be listed in a list view.</p> <p><a href="https://i.stack.imgur.com/kPEQA.png" rel="nofollow noreferrer">My Database</a></p> <pre><code> ClientsRef= FirebaseDatabase.getInstance().getReference(...
I've been trying to get the children list in list view in my dashboard. Whenever I click users I need this children to be listed in a list view. My Database [CODE]
java|android|firebase
0
2020-02-13T13:58:07.780Z
2,020
2
13
3
64
2
163
49
3
1
true
false
false
false
false
false
zero
60,209,563
ActivityScenario.launch looking for some cached jar
<p>I am running android instrumentation tests and I have the following code:</p> <pre><code> lateinit var scenario: ActivityScenario&lt;MainActivity&gt; @Before fun before(){ scenario = ActivityScenario.launch(MainActivity::class.java) } </code></pre> <p>The tests themselves, run great.</p> <p>However, every...
I am running android instrumentation tests and I have the following code: [CODE] The tests themselves, run great. However, every time I launch the suite (or an individual test) I see the following in the log [CODE] What is it? Do you know how to get rid of it?
android|android-instrumentation|activity-scenario
7
2020-02-13T13:58:18.513Z
2,020
2
13
3
256
0
260
51
3
2
true
true
false
false
false
false
medium
60,209,629
Constraint layout always alinging to top left corner
<p>I was trying to aling some EditTexts in three columns. But all I get is this. You can't even see them without selecting them in design editor. I tried adding them separately and setting the constraints as I go along and adding all of them and setting constraint after that. None of which helped. I'm lost, I thought c...
I was trying to aling some EditTexts in three columns. But all I get is this. You can't even see them without selecting them in design editor. I tried adding them separately and setting the constraints as I go along and adding all of them and setting constraint after that. None of which helped. I'm lost, I thought cons...
android|android-constraintlayout
0
2020-02-13T14:02:00.357Z
2,020
2
14
3
812
4
468
52
2
1
true
false
false
false
false
false
zero