android-studio

Android App with Google Drive API stucks after choosing an account. Why?

我们两清 提交于 2021-02-17 03:36:32
问题 I'm trying to understand how I can integrate Google Drive API in my Android App(using Android Studio). I have tried the example app that I found here(https://github.com/googleworkspace/android-samples/tree/master/drive/deprecation) but after Google API console configuration my app stucks in an infinite loop when I choose an Account. Why? Where is the problem? I tried also with this(https://youtu.be/5bSEIQYJzKs) tutorial but I have the same problem. Here my build.gradle specific lines:

Android Studio OpenCV NDK: Unspecified error, The function is not implemented

 ̄綄美尐妖づ 提交于 2021-02-16 20:46:09
问题 I write in Android Studio on Windows. And I use OpenCV in my native c++ code.When calling the function, I get this error in logcat: "OpenCV Error: Unspecified error (The function is not implemented. Rebuild the library with Windows, GTK+ 2.x or Carbon support. If you are on Ubuntu or Debian, install libgtk2.0-dev and pkg-config, then re-run cmake or configure script) in cvShowImage, file /Volumes/Linux/builds/master_pack-android/opencv/modules/highgui/src/window.cpp, line 545". I found

How to filter logcat to remove irrelevant statements

风流意气都作罢 提交于 2021-02-16 18:22:45
问题 I'm new to Android Studio, using latest version, and trying to code a basic calculator app. For some reason, my logcat is full of 2021-01-11 14:38:35.288 6938-6938/? W/cmd: Can't find service car_service This is really annoying for debugging. How can I get rid of it ? 回答1: I'll change my comment to an answer, seeing as though it actually helped: click on logcat at the bottom of android studio, then (i'm assuming) yours will show no filters , change that dropdown to show only selected

I can auto increment id in room database but when refresh database it's shows double

蹲街弑〆低调 提交于 2021-02-13 12:58:47
问题 In my app firstly i am fetching data from server using retrofit then it's saved in room database table then it shows in recyclerview but when i using a id as a primary key it's show only one data then this id i annotat autoGenerate = true then it's show all data which i put in server but when i reopen my app,it's show double data(this mean firstly i have 3 data in server,this app show 3 data but when i reopen or refresh my database it's show 6 data ,every time in refresh it's increasing).but

I can auto increment id in room database but when refresh database it's shows double

旧街凉风 提交于 2021-02-13 12:56:51
问题 In my app firstly i am fetching data from server using retrofit then it's saved in room database table then it shows in recyclerview but when i using a id as a primary key it's show only one data then this id i annotat autoGenerate = true then it's show all data which i put in server but when i reopen my app,it's show double data(this mean firstly i have 3 data in server,this app show 3 data but when i reopen or refresh my database it's show 6 data ,every time in refresh it's increasing).but

I can auto increment id in room database but when refresh database it's shows double

核能气质少年 提交于 2021-02-13 12:54:16
问题 In my app firstly i am fetching data from server using retrofit then it's saved in room database table then it shows in recyclerview but when i using a id as a primary key it's show only one data then this id i annotat autoGenerate = true then it's show all data which i put in server but when i reopen my app,it's show double data(this mean firstly i have 3 data in server,this app show 3 data but when i reopen or refresh my database it's show 6 data ,every time in refresh it's increasing).but

Why is my Jsoup Code not Returning the Correct Elements?

家住魔仙堡 提交于 2021-02-13 05:44:30
问题 I am working on an app in Android Studio and am having some trouble web-scraping with JSoup. I have successfully connected to the webpage and returned some basic elements to test the library, but now I cannot actually get the elements I need for my app. I am trying to get a number of elements with the "data-at" attribute. The weird thing is, a few elements with the "data-at" attribute are returned, but not the ones I am looking for. For whatever reason my code is not extracting all of the

Unresolved reference - activity does not recognize synthetic imports in android studio v4

五迷三道 提交于 2021-02-13 05:40:42
问题 last night I noticed I'm not able to change the attributes of elements in the layout from my main activity so I built a new project and I had the same problem there too. I could not find out what was wrong with my android studio so I'd appreciate it if someone with the same problem helps me out. as you see in the picture when I call a defined view from the layout in my activity its not recognized the error will be: Unresolved reference: txtHello 回答1: Kotlin Synthetic imports not working ?

How to encrypt sqlite texts without 3rd party libraries (Android)

混江龙づ霸主 提交于 2021-02-11 18:11:35
问题 I'm using an external database inside my android application and it directly embeds inside the apk package after compiling. As I want to implement in app purchase in order to access some of its data I don't want to leave it without any encryption. I used Sqlcipher library but it makes the app too big and slow. Isn't there any other way to do this? For example an algorithm to encrypt the strings so I put the encrypted text in database and decrypt it inside application code? 回答1: The following