Android application starts on emulator but does not respond - android

Everything was working fine yesterday and today, my application does not respond on the emulator! It's driving me crazy as I have done nothing different or made any changes apart from updating Android Studio and I do not know if that's the cause. The app launches on the emulator but it keeps flickering on and off. Other apps work fine.
My logcat output gives me this and doesn't stop!:
--------- beginning of system
08-28 14:29:16.772 1997-2013/com.example.lysandroslysandrou.myapplication W/EGL_emulation﹕ eglSurfaceAttrib not implemented
08-28 14:29:16.772 1997-2013/com.example.lysandroslysandrou.myapplication W/OpenGLRenderer﹕ Failed to set EGL_SWAP_BEHAVIOR on surface 0xa370ae00, error=EGL_SUCCESS
08-28 14:29:16.890 1997-1997/com.example.lysandroslysandrou.myapplication I/AppCompatViewInflater﹕ app:theme is now deprecated. Please move to using android:theme instead.
08-28 14:29:17.009 1997-2013/com.example.lysandroslysandrou.myapplication W/EGL_emulation﹕ eglSurfaceAttrib not implemented
08-28 14:29:17.009 1997-2013/com.example.lysandroslysandrou.myapplication W/OpenGLRenderer﹕ Failed to set EGL_SWAP_BEHAVIOR on surface 0xa28cad20, error=EGL_SUCCESS
08-28 14:29:17.233 1997-1997/com.example.lysandroslysandrou.myapplication I/AppCompatViewInflater﹕ app:theme is now deprecated. Please move to using android:theme instead.
08-28 14:29:17.312 1997-2013/com.example.lysandroslysandrou.myapplication W/EGL_emulation﹕ eglSurfaceAttrib not implemented
08-28 14:29:17.312 1997-2013/com.example.lysandroslysandrou.myapplication W/OpenGLRenderer﹕ Failed to set EGL_SWAP_BEHAVIOR on surface 0xa29a7b60, error=EGL_SUCCESS
08-28 14:29:17.382 1997-1997/com.example.lysandroslysandrou.myapplication I/AppCompatViewInflater﹕ app:theme is now deprecated. Please move to using android:theme instead.
08-28 14:29:17.529 1997-2013/com.example.lysandroslysandrou.myapplication W/EGL_emulation﹕ eglSurfaceAttrib not implemented
08-28 14:29:17.529 1997-2013/com.example.lysandroslysandrou.myapplication W/OpenGLRenderer﹕ Failed to set EGL_SWAP_BEHAVIOR on surface 0xa29a7b40, error=EGL_SUCCESS
08-28 14:29:17.839 1997-1997/com.example.lysandroslysandrou.myapplication I/AppCompatViewInflater﹕ app:theme is now deprecated. Please move to using android:theme instead.
08-28 14:29:17.883 1997-2013/com.example.lysandroslysandrou.myapplication W/EGL_emulation﹕ eglSurfaceAttrib not implemented
08-28 14:29:17.883 1997-2013/com.example.lysandroslysandrou.myapplication W/OpenGLRenderer﹕ Failed to set EGL_SWAP_BEHAVIOR on surface 0xa2a98dc0, error=EGL_SUCCESS
08-28 14:29:17.926 1997-1997/com.example.lysandroslysandrou.myapplication I/AppCompatViewInflater﹕ app:theme is now deprecated. Please move to using android:theme instead.
08-28 14:29:18.097 1997-2013/com.example.lysandroslysandrou.myapplication W/EGL_emulation﹕ eglSurfaceAttrib not implemented
08-28 14:29:18.097 1997-2013/com.example.lysandroslysandrou.myapplication W/OpenGLRenderer﹕ Failed to set EGL_SWAP_BEHAVIOR on surface 0xa2a98da0, error=EGL_SUCCESS
08-28 14:29:18.282 1997-1997/com.example.lysandroslysandrou.myapplication I/AppCompatViewInflater﹕ app:theme is now deprecated. Please move to using android:theme instead.
08-28 14:29:18.339 1997-2013/com.example.lysandroslysandrou.myapplication W/EGL_emulation﹕ eglSurfaceAttrib not implemented
08-28 14:29:18.339 1997-2013/com.example.lysandroslysandrou.myapplication W/OpenGLRenderer﹕ Failed to set EGL_SWAP_BEHAVIOR on surface 0xa2ba3480, error=EGL_SUCCESS
08-28 14:29:18.539 1997-1997/com.example.lysandroslysandrou.myapplication I/AppCompatViewInflater﹕ app:theme is now deprecated. Please move to using android:theme instead.
08-28 14:29:18.628 1997-2013/com.example.lysandroslysandrou.myapplication W/EGL_emulation﹕ eglSurfaceAttrib not implemented
08-28 14:29:18.628 1997-2013/com.example.lysandroslysandrou.myapplication W/OpenGLRenderer﹕ Failed to set EGL_SWAP_BEHAVIOR on surface 0xa327f3a0, error=EGL_SUCCESS
08-28 14:29:18.674 1997-1997/com.example.lysandroslysandrou.myapplication I/AppCompatViewInflater﹕ app:theme is now deprecated. Please move to using android:theme instead.
08-28 14:29:18.840 1997-2013/com.example.lysandroslysandrou.myapplication W/EGL_emulation﹕ eglSurfaceAttrib not implemented
08-28 14:29:18.840 1997-2013/com.example.lysandroslysandrou.myapplication W/OpenGLRenderer﹕ Failed to set EGL_SWAP_BEHAVIOR on surface 0xa327f380, error=EGL_SUCCESS
08-28 14:29:19.136 1997-1997/com.example.lysandroslysandrou.myapplication I/AppCompatViewInflater﹕ app:theme is now deprecated. Please move to using android:theme instead.
08-28 14:29:19.195 1997-2013/com.example.lysandroslysandrou.myapplication W/EGL_emulation﹕ eglSurfaceAttrib not implemented
08-28 14:29:19.195 1997-2013/com.example.lysandroslysandrou.myapplication W/OpenGLRenderer﹕ Failed to set EGL_SWAP_BEHAVIOR on surface 0xa250aa40, error=EGL_SUCCESS
08-28 14:29:19.323 1997-1997/com.example.lysandroslysandrou.myapplication I/AppCompatViewInflater﹕ app:theme is now deprecated. Please move to using android:theme instead.
08-28 14:29:19.543 1997-2013/com.example.lysandroslysandrou.myapplication W/EGL_emulation﹕ eglSurfaceAttrib not implemented
08-28 14:29:19.543 1997-2013/com.example.lysandroslysandrou.myapplication W/OpenGLRenderer﹕ Failed to set EGL_SWAP_BEHAVIOR on surface 0xa25843a0, error=EGL_SUCCESS
08-28 14:29:19.657 1997-1997/com.example.lysandroslysandrou.myapplication I/AppCompatViewInflater﹕ app:theme is now deprecated. Please move to using android:theme instead.
08-28 14:29:19.840 1997-2013/com.example.lysandroslysandrou.myapplication W/EGL_emulation﹕ eglSurfaceAttrib not implemented
08-28 14:29:19.840 1997-2013/com.example.lysandroslysandrou.myapplication W/OpenGLRenderer﹕ Failed to set EGL_SWAP_BEHAVIOR on surface 0xa25f0600, error=EGL_SUCCESS
08-28 14:29:20.047 1997-1997/com.example.lysandroslysandrou.myapplication I/AppCompatViewInflater﹕ app:theme is now deprecated. Please move to using android:theme instead.
08-28 14:29:20.191 1997-2013/com.example.lysandroslysandrou.myapplication W/EGL_emulation﹕ eglSurfaceAttrib not implemented
08-28 14:29:20.191 1997-2013/com.example.lysandroslysandrou.myapplication W/OpenGLRenderer﹕ Failed to set EGL_SWAP_BEHAVIOR on surface 0xa2601260, error=EGL_SUCCESS
08-28 14:29:20.398 1997-1997/com.example.lysandroslysandrou.myapplication I/AppCompatViewInflater﹕ app:theme is now deprecated. Please move to using android:theme instead.
08-28 14:29:20.461 1997-2013/com.example.lysandroslysandrou.myapplication W/EGL_emulation﹕ eglSurfaceAttrib not implemented
08-28 14:29:20.461 1997-2013/com.example.lysandroslysandrou.myapplication W/OpenGLRenderer﹕ Failed to set EGL_SWAP_BEHAVIOR on surface 0xa243a740, error=EGL_SUCCESS
08-28 14:29:20.667 1997-1997/com.example.lysandroslysandrou.myapplication I/AppCompatViewInflater﹕ app:theme is now deprecated. Please move to using android:theme instead.
08-28 14:29:20.771 1997-2013/com.example.lysandroslysandrou.myapplication W/EGL_emulation﹕ eglSurfaceAttrib not implemented
08-28 14:29:20.771 1997-2013/com.example.lysandroslysandrou.myapplication W/OpenGLRenderer﹕ Failed to set EGL_SWAP_BEHAVIOR on surface 0xa24477e0, error=EGL_SUCCESS
08-28 14:29:20.979 1997-1997/com.example.lysandroslysandrou.myapplication I/AppCompatViewInflater﹕ app:theme is now deprecated. Please move to using android:theme instead.
08-28 14:29:21.072 1997-2013/com.example.lysandroslysandrou.myapplication W/EGL_emulation﹕ eglSurfaceAttrib not implemented
08-28 14:29:21.072 1997-2013/com.example.lysandroslysandrou.myapplication W/OpenGLRenderer﹕ Failed to set EGL_SWAP_BEHAVIOR on surface 0xa2447720, error=EGL_SUCCESS
08-28 14:29:21.264 1997-1997/com.example.lysandroslysandrou.myapplication I/AppCompatViewInflater﹕ app:theme is now deprecated. Please move to using android:theme instead.
And my console is this..:
emulator: device fd:784
HAXM is working and emulator runs in fast virt mode
emulator: warning: opening audio input failed
creating window 61 83 462 820
emulator: emulator window was out of view and was recentered
draw: Could not use program error=0x505
draw: Could not use program error=0x505
draw: Could not use program error=0x505
draw: Could not use program error=0x505
draw: Could not use program error=0x505
ColorBuffer::bindFbo: FBO not complete: 0x8cd6
ColorBuffer::bindFbo: FBO not complete: 0x8cd6
ColorBuffer::bindFbo: FBO not complete: 0x8cd6
draw: Could not use program error=0x505
draw: Could not use program error=0x505
ColorBuffer::bindFbo: FBO not complete: 0x8cd6
ColorBuffer::bindFbo: FBO not complete: 0x8cd6
draw: Could not use program error=0x505
ColorBuffer::bindFbo: FBO not complete: 0x8cd6
draw: Could not use program error=0x505
ColorBuffer::bindFbo: FBO not complete: 0x8cd6
draw: Could not use program error=0x505
ColorBuffer::bindFbo: FBO not complete: 0x8cd6
ColorBuffer::bindFbo: FBO not complete: 0x8cd6
draw: Could not run program: Ü
draw: Could not run program: à
draw: Could not run program: ì
draw: Could not run program: ì
draw: Could not run program: ì
draw: Could not run program: ì
draw: Could not run program: ì
draw: Could not run program: ì
draw: Could not run program: ì
draw: Could not run program: ì
draw: Could not run program: ì
draw: Could not run program: ì
draw: Could not run program: ì
draw: Could not run program: î
draw: Could not run program: î
draw: Could not run program: î
draw: Could not run program: ð
draw: Could not run program: ð
ColorBuffer::bindFbo: FBO not complete: 0
draw: Could not run program: ò
These outputs don't stop!! Please any help will be appreciated..
If anything else is needed let me know!!

I don't have a solution to "solve" the problem, but what if you by-passed this by creating a new AVD and use it as default emulator?

Try to create another vm.
Check gradle version.
Reinstall api packages.

For future references, I've solved my problem by returning to an older version of my app and starting again from there. No matter how much research I have done, I didn't find a straight forward solution. Apparently this has to do with the OpenGLRenderer but I'm not sure in which way.
Best advice I can give is to make constant copies of your app at various stages in case something like this happens. In addition, always make sure you save your files before updating Android Studio because it can mess things up and be careful at what stage of your project you update it.

I myself found emulator extremely useless. Use real android device and then you know for sure if it works or not.

Related

IntentService started twice

I have used IntentSerivce to download a large json. I have used Gson and Retrofit2 in the first place. After I have found that Jackson is better for marshaling of large json.
And here problem starts, intentService has been triggered twice even in code is called only once.
I am triggering intentService from splash screen, the orientation of the device is landscape. There are no flipping up/down so I guess that there is no recreation of activity when orientation is changed. Also app is hardcoded to start in landscape orientation.
Here are logs from logCat
I/APPLICATION CLASS: DB FOUND
02-28 10:15:25.034 1561-2108/? I/ActivityManager: START u0 {flg=0x10000000 cmp=aoc.netcast.rs.android_ott_client/.view.SplashScreen} from uid 10073 on display 0
02-28 10:15:25.040 3195-3195/? I/INTENT PERFORMING: Starting intent...
02-28 10:15:25.041 3195-3195/? I/INTENT PERFORMING: Intent started...
02-28 10:15:25.053 1206-1286/? E/SurfaceFlinger: ro.sf.lcd_density must be defined as a build property
02-28 10:15:25.062 3195-3210/? W/nAnnotationIntrospector: Unable to load JDK7 annotation types; will have to skip
02-28 10:15:25.074 3195-3195/? I/INTENT PERFORMING: Starting intent...
02-28 10:15:25.074 3195-3195/? I/INTENT PERFORMING: Intent started...
02-28 10:15:25.090 3195-3210/? W/System.err: WARNING: could not load Java7 Path class
02-28 10:15:25.330 1206-1206/? E/SurfaceFlinger: rejecting buffer: bufWidth=1080, bufHeight=1920, front.active.{w=1080, h=1776}
[ 02-28 10:15:25.341 3195: 3209 D/ ]
HostConnection::get() New Host Connection established 0x7fa7db557360, tid 3209
02-28 10:15:25.344 3195-3209/? I/OpenGLRenderer: Initialized EGL, version 1.4
02-28 10:15:25.344 1561-1612/? I/InputReader: Reconfiguring input devices. changes=0x00000004
02-28 10:15:25.344 1561-1612/? I/InputReader: Device reconfigured: id=0, name='qwerty2', size 1080x1920, orientation 1, mode 1, display id 0
02-28 10:15:25.350 1694-2096/? E/Surface: getSlotFromBufferLocked: unknown buffer: 0x7fa7cf1b1b10
02-28 10:15:25.353 1694-2096/? E/EGL_emulation: tid 2096: eglSurfaceAttrib(1165): error 0x3009 (EGL_BAD_MATCH)
02-28 10:15:25.353 1694-2096/? W/OpenGLRenderer: Failed to set EGL_SWAP_BEHAVIOR on surface 0x7fa7ce77fa80, error=EGL_BAD_MATCH
02-28 10:15:25.365 3195-3209/? E/EGL_emulation: tid 3209: eglSurfaceAttrib(1165): error 0x3009 (EGL_BAD_MATCH)
02-28 10:15:25.365 3195-3209/? W/OpenGLRenderer: Failed to set EGL_SWAP_BEHAVIOR on surface 0x7fa7db548c40, error=EGL_BAD_MATCH
02-28 10:15:25.367 1694-2096/? E/Surface: getSlotFromBufferLocked: unknown buffer: 0x7fa7cf1b23d0
02-28 10:15:25.378 1694-2096/? E/EGL_emulation: tid 2096: eglSurfaceAttrib(1165): error 0x3009 (EGL_BAD_MATCH)
02-28 10:15:25.378 1694-2096/? W/OpenGLRenderer: Failed to set EGL_SWAP_BEHAVIOR on surface 0x7fa7ce77fac0, error=EGL_BAD_MATCH
02-28 10:15:25.449 1561-1580/? I/ActivityManager: Displayed aoc.netcast.rs.android_ott_client/.view.SplashScreen: +390ms (total +578ms)
02-28 10:15:25.458 1561-1580/? I/WindowManager: Screen frozen for +559ms due to Window{85b86c9 u0 aoc.netcast.rs.android_ott_client/aoc.netcast.rs.android_ott_client.view.SplashScreen}
02-28 10:15:27.461 1561-1580/? I/art: Starting a blocking GC Explicit
02-28 10:15:27.471 1561-1580/? I/art: Explicit concurrent mark sweep GC freed 14571(904KB) AllocSpace objects, 3(60KB) LOS objects, 31% free, 8MB/12MB, paused 127us total 9.460ms
02-28 10:15:30.335 1561-2989/? I/AccountManagerService: getTypesVisibleToCaller: isPermitted? true
I don't know why is this happening, can you please help me to solve this?

Google Play Services out of date in Android Emulator

I have an android emulator with Marshmallow and Google Apis.
For some reason the Google Play Services got stuck in release 8.1.85 and it doesn't get updated.
My app uses the 8.3 release in Android Studio Gradle:
compile 'com.google.android.gms:play-services:8.3.0'
When the app starts it detects it is out of date so the "update dialog" appears. Clicking on update it does nothing. I get this log:
12-21 12:21:46.369 3516-3516/app.pack.com W/GooglePlayServicesUtil: Google Play services out of date. Requires 8298000 but found 8185470
12-21 12:21:46.548 3516-3541/app.pack.com W/EGL_emulation: eglSurfaceAttrib not implemented
12-21 12:21:46.548 3516-3541/app.pack.com W/OpenGLRenderer: Failed to set EGL_SWAP_BEHAVIOR on surface 0xabff10c0, error=EGL_SUCCESS
12-21 12:21:46.685 3516-3541/app.pack.com W/EGL_emulation: eglSurfaceAttrib not implemented
12-21 12:21:46.686 3516-3541/app.pack.com W/OpenGLRenderer: Failed to set EGL_SWAP_BEHAVIOR on surface 0xb3f09320, error=EGL_SUCCESS
12-21 12:21:47.065 3516-3541/app.pack.com W/EGL_emulation: eglSurfaceAttrib not implemented
12-21 12:21:47.065 3516-3541/app.pack.com W/OpenGLRenderer: Failed to set EGL_SWAP_BEHAVIOR on surface 0xb3f3f240, error=EGL_SUCCESS
12-21 12:21:50.302 3516-3541/app.pack.com E/Surface: getSlotFromBufferLocked: unknown buffer: 0xab7980b0
12-21 12:21:56.326 3516-3516/app.pack.com E/SettingsRedirect: Can't redirect to app settings for Google Play services
12-21 12:21:56.333 3516-3541/app.pack.com E/Surface: getSlotFromBufferLocked: unknown buffer: 0xab796d70
12-21 12:21:56.339 3516-3541/app.pack.com D/OpenGLRenderer: endAllStagingAnimators on 0xa19fa980 (RippleDrawable) with handle 0xb12c9ac0
12-21 12:21:56.366 3516-3516/app.pack.com W/GooglePlayServicesUtil: Google Play services out of date. Requires 8298000 but found 8185470
12-21 12:21:56.432 3516-3541/app.pack.com W/EGL_emulation: eglSurfaceAttrib not implemented
12-21 12:21:56.432 3516-3541/app.pack.com W/OpenGLRenderer: Failed to set EGL_SWAP_BEHAVIOR on surface 0xad71b0c0, error=EGL_SUCCESS
12-21 12:21:56.793 3516-3541/app.pack.com W/EGL_emulation: eglSurfaceAttrib not implemented
12-21 12:21:56.793 3516-3541/app.pack.com W/OpenGLRenderer: Failed to set EGL_SWAP_BEHAVIOR on surface 0xb3f3f920, error=EGL_SUCCESS
12-21 12:22:00.027 3516-3541/app.pack.com E/Surface: getSlotFromBufferLocked: unknown buffer: 0xab798e40
The solution I've tried for this issue before is to change:
compile 'com.google.android.gms:play-services:8.3.0'
to
compile 'com.google.android.gms:play-services:7.+'
Sometimes, what is reflected on the gradle is not the actual version and by putting + the app will automatically use the latest version available.
Here is solution: using AVD image with build-in Google Play Services. It will enable you to use Google Services including Google Play. Also you will be able update it without re-creating AVD image.
Open AVD manager and choose create new device. You should use device definition with play store icon.
Then choose system image for it. You should choose one with Google Play and NOT with Google API.
Then launch new device.
You can update Play Services as shown on screenshot, or manually on device..

Unable to Show Progress Dialog [closed]

Closed. This question needs details or clarity. It is not currently accepting answers.
Want to improve this question? Add details and clarify the problem by editing this post.
Closed 7 years ago.
Improve this question
I'm using ProgressDialog to show a loading page in my android app .
My code looks like :
final ProgressDialog dialog = new ProgressDialog(this);
dialog.setCancelable(false);
dialog.setMessage("please Wait ...");
dialog.requestWindowFeature(Window.FEATURE_NO_TITLE);
dialog.setProgressStyle(R.style.progress_dialog_style);
dialog.show();
String toastMsg = null;
LoginService loginService = new LoginService(LoginActivity.this);
ProfileDetails profileDetails = loginService.checkLogin(mobile_number.getText().toString().trim(), password.getText().toString().trim());
if(profileDetails != null && loginService.changeLogin(MainActivity.LOGIN_YES, mobile_number.getText().toString().trim())) {
toastMsg = MainActivity.LOGIN_SUCCESSFUL;
}
if(profileDetails == null) {
runOnUiThread(new Runnable() {
public void run() {
dialog.dismiss();
}
});
}
and then i perform some DB Operations and get some data
and i use dialog.dismiss().
If i get data successfully i use startActivity(intent);
Here
i) if i use dialog.dismiss() when i run the code i am not able to see the Dialog.
ii) When i remove the dialog.dimiss() section i am able to see the Dialog but unable to close it.
Please resolve this problem.
Thank You
Log i got is
12-16 00:12:42.325 2146-2172/mycompany.com.weekendmovierating W/EGL_emulation﹕ eglSurfaceAttrib not implemented
12-16 00:12:42.325 2146-2172/mycompany.com.weekendmovierating W/OpenGLRenderer﹕ Failed to set EGL_SWAP_BEHAVIOR on surface 0xa34423e0, error=EGL_SUCCESS
12-16 00:12:42.632 2146-2172/mycompany.com.weekendmovierating W/EGL_emulation﹕ eglSurfaceAttrib not implemented
12-16 00:12:42.632 2146-2172/mycompany.com.weekendmovierating W/OpenGLRenderer﹕ Failed to set EGL_SWAP_BEHAVIOR on surface 0xa34422e0, error=EGL_SUCCESS
12-16 00:12:42.804 2146-2160/mycompany.com.weekendmovierating I/art﹕ WaitForGcToComplete blocked for 58.235ms for cause Background
12-16 00:12:42.937 2146-2156/mycompany.com.weekendmovierating W/art﹕ Suspending all threads took: 38.186ms
12-16 00:12:42.938 2146-2160/mycompany.com.weekendmovierating W/art﹕ Suspending all threads took: 19.448ms
12-16 00:12:42.946 2146-2160/mycompany.com.weekendmovierating I/art﹕ Background sticky concurrent mark sweep GC freed 8670(494KB) AllocSpace objects, 5(100KB) LOS objects, 0% free, 5MB/5MB, paused 21.810ms total 130.763ms
12-16 00:12:43.105 2146-2160/mycompany.com.weekendmovierating W/art﹕ Suspending all threads took: 61.760ms
12-16 00:12:43.171 2146-2146/mycompany.com.weekendmovierating I/Choreographer﹕ Skipped 44 frames! The application may be doing too much work on its main thread.
12-16 00:12:43.245 2146-2160/mycompany.com.weekendmovierating I/art﹕ Background partial concurrent mark sweep GC freed 1796(126KB) AllocSpace objects, 2(76KB) LOS objects, 39% free, 5MB/9MB, paused 12.887ms total 76.159ms
12-16 00:12:43.803 2146-2172/mycompany.com.weekendmovierating W/EGL_emulation﹕ eglSurfaceAttrib not implemented
12-16 00:12:43.803 2146-2172/mycompany.com.weekendmovierating W/OpenGLRenderer﹕ Failed to set EGL_SWAP_BEHAVIOR on surface 0xb3fdece0, error=EGL_SUCCESS
12-16 00:12:44.892 1294-1313/system_process I/ActivityManager﹕ Displayed mycompany.com.weekendmovierating/mycompany.weekendmovierating.activity.SelectLanguageActivity: +2s541ms
12-16 00:12:45.023 2146-2146/mycompany.com.weekendmovierating I/Choreographer﹕ Skipped 69 frames! The application may be doing too much work on its main thread.
12-16 00:12:45.055 1545-6738/com.android.inputmethod.latin E/Surface﹕ getSlotFromBufferLocked: unknown buffer: 0xab7d6dc0
12-16 00:12:45.082 2146-2172/mycompany.com.weekendmovierating E/Surface﹕ getSlotFromBufferLocked: unknown buffer: 0xab7da1d0
12-16 00:12:45.093 2146-2172/mycompany.com.weekendmovierating E/Surface﹕ getSlotFromBufferLocked: unknown buffer: 0xab7d8870
12-16 00:12:45.148 2146-2172/mycompany.com.weekendmovierating E/Surface﹕ getSlotFromBufferLocked: unknown buffer: 0xab7d85d0
12-16 00:12:45.342 2146-2146/mycompany.com.weekendmovierating E/WindowManager﹕ android.view.WindowLeaked: Activity mycompany.weekendmovierating.activity.LoginActivity has leaked window com.android.internal.policy.PhoneWindow$DecorView{ffa0769 V.E...... R......D 0,0-760,192} that was originally added here
at android.view.ViewRootImpl.<init>(ViewRootImpl.java:368)
at android.view.WindowManagerGlobal.addView(WindowManagerGlobal.java:299)
at android.view.WindowManagerImpl.addView(WindowManagerImpl.java:85)
at android.app.Dialog.show(Dialog.java:319)
at mycompany.weekendmovierating.activity.LoginActivity.login(LoginActivity.java:87)
at java.lang.reflect.Method.invoke(Native Method)
at android.view.View$DeclaredOnClickListener.onClick(View.java:4447)
at android.view.View.performClick(View.java:5198)
at android.view.View$PerformClick.run(View.java:21147)
at android.os.Handler.handleCallback(Handler.java:739)
at android.os.Handler.dispatchMessage(Handler.java:95)
at android.os.Looper.loop(Looper.java:148)
at android.app.ActivityThread.main(ActivityThread.java:5417)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:726)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:616)
12-16 00:12:45.371 2146-2156/mycompany.com.weekendmovierating W/art﹕ Suspending all threads took: 25.085ms
12-16 00:12:45.397 1294-1305/system_process W/WindowManager﹕ Failed looking up window
java.lang.IllegalArgumentException: Requested window android.os.BinderProxy#aa60cd1 does not exist
at com.android.server.wm.WindowManagerService.windowForClientLocked(WindowManagerService.java:8723)
at com.android.server.wm.WindowManagerService.windowForClientLocked(WindowManagerService.java:8714)
at com.android.server.wm.WindowManagerService.removeWindow(WindowManagerService.java:2697)
at com.android.server.wm.Session.remove(Session.java:187)
at android.view.IWindowSession$Stub.onTransact(IWindowSession.java:242)
at com.android.server.wm.Session.onTransact(Session.java:130)
at android.os.Binder.execTransact(Binder.java:453)
runOnUiThread(new Runnable() {
#Override
public void run()
{
progress.dismiss();
}
Dismiss your dialog like this in runnable thread.

Android App says "Can't Play this video" when provided with link

I developed a small android app to which a link is provided and it just need to play that video.
But playback says "Can't play this video".
Can anyone help me with this.?
Main Activity Code:
public class MainActivity extends AppCompatActivity {
#Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_main);
final VideoView ramVV= (VideoView)findViewById(R.id.ramVV);
ramVV.setVideoPath("https://www.thenewboston.com/forum/project_files/006_testVideo.mp4");
ramVV.start();
}
}
logcat shows the following:
07-18 22:24:19.925 17364-17364/com.example.ram.videoplayer D/﹕ HostConnection::get() New Host Connection established 0xb3eb3e80, tid 17364
07-18 22:24:20.015 17364-17364/com.example.ram.videoplayer D/Atlas﹕ Validating map...
07-18 22:24:20.059 17364-17379/com.example.ram.videoplayer D/﹕ HostConnection::get() New Host Connection established 0xb3eb3fd0, tid 17379
07-18 22:24:20.076 17364-17379/com.example.ram.videoplayer I/OpenGLRenderer﹕ Initialized EGL, version 1.4
07-18 22:24:20.110 17364-17379/com.example.ram.videoplayer D/OpenGLRenderer﹕ Enabling debug mode 0
07-18 22:24:20.117 17364-17379/com.example.ram.videoplayer W/EGL_emulation﹕ eglSurfaceAttrib not implemented
07-18 22:24:20.117 17364-17379/com.example.ram.videoplayer W/OpenGLRenderer﹕ Failed to set EGL_SWAP_BEHAVIOR on surface 0xb3f1ec20, error=EGL_SUCCESS
07-18 22:24:20.167 17364-17364/com.example.ram.videoplayer D/MediaPlayer﹕ Couldn't open file on client side, trying server side
07-18 22:24:50.612 17364-17378/com.example.ram.videoplayer E/MediaPlayer﹕ error (1, -2147483648)
07-18 22:24:50.612 17364-17364/com.example.ram.videoplayer E/MediaPlayer﹕ Error (1,-2147483648)
07-18 22:24:50.612 17364-17364/com.example.ram.videoplayer D/VideoView﹕ Error: 1,-2147483648
07-18 22:24:50.703 17364-17379/com.example.ram.videoplayer W/EGL_emulation﹕ eglSurfaceAttrib not implemented
07-18 22:24:50.703 17364-17379/com.example.ram.videoplayer W/OpenGLRenderer﹕ Failed to set EGL_SWAP_BEHAVIOR on surface 0xb3feb960, error=EGL_SUCCESS
07-18 22:24:53.600 17364-17379/com.example.ram.videoplayer D/OpenGLRenderer﹕ endAllStagingAnimators on 0xa512fd80 (RippleDrawable) with handle 0xa51358f0
And I have also added permission in Manifest file.

Android Studio - Genymotion - Volley gets wrong url to download

I'm facing this really strange issue and I couldn't realize what's happening.
I have a login activity and when I try to make a request to validate the user information, I get this error in volley:
com.android.volley.NoConnectionError: java.net.UnknownHostException: Unable to resolve host "teste.escolaemmovimento.com.br": No address associated with hostname.
This error only happens when I'm using the Genymotion emulator, I verify the URL field inside of the volley Request object right after create that and after insert the request in the volley queue and the correct url is there.
(when I test in the device this error does not happens.)
LogCat:
06-01 13:17:28.351 25469-25521/br.com.escolaemmovimento D/OpenGLRenderer﹕ Render dirty regions requested: true
06-01 13:17:28.362 25469-25469/br.com.escolaemmovimento D/﹕ HostConnection::get() New Host Connection established 0xabb84990, tid 25469
06-01 13:17:28.374 25469-25469/br.com.escolaemmovimento D/Atlas﹕ Validating map...
06-01 13:17:28.556 25469-25521/br.com.escolaemmovimento D/libEGL﹕ loaded /system/lib/egl/libEGL_emulation.so
06-01 13:17:28.557 25469-25521/br.com.escolaemmovimento D/libEGL﹕ loaded /system/lib/egl/libGLESv1_CM_emulation.so
06-01 13:17:28.568 25469-25521/br.com.escolaemmovimento D/libEGL﹕ loaded /system/lib/egl/libGLESv2_emulation.so
06-01 13:17:28.578 25469-25521/br.com.escolaemmovimento D/﹕ HostConnection::get() New Host Connection established 0xaf60b940, tid 25521
06-01 13:17:28.604 25469-25521/br.com.escolaemmovimento I/OpenGLRenderer﹕ Initialized EGL, version 1.4
06-01 13:17:28.635 25469-25521/br.com.escolaemmovimento D/OpenGLRenderer﹕ Enabling debug mode 0
06-01 13:17:28.650 25469-25521/br.com.escolaemmovimento W/EGL_emulation﹕ eglSurfaceAttrib not implemented
06-01 13:17:28.651 25469-25521/br.com.escolaemmovimento W/OpenGLRenderer﹕ Failed to set EGL_SWAP_BEHAVIOR on surface 0xaf639400, error=EGL_SUCCESS
06-01 13:17:54.808 25469-25469/br.com.escolaemmovimento I/System.out﹕ com.android.volley.NoConnectionError: java.net.UnknownHostException: Unable to resolve host "teste.escolaemmovimento.com.br": No address associated with hostname
Anyone has already faced this issue? This is a problem only associate with the emulator? Thanks for any help.
UnknownHostException is thrown to indicate that the IP address of a host could not be determined. Make sure you have internet access inside of Genymotion.

Categories

Resources