Skip to content
This repository has been archived by the owner on Sep 21, 2021. It is now read-only.

Sometimes make error at some devices #5

Open
sungeuns opened this issue Aug 25, 2012 · 21 comments
Open

Sometimes make error at some devices #5

sungeuns opened this issue Aug 25, 2012 · 21 comments
Labels

Comments

@sungeuns
Copy link

I refer similar code in stackoverflow, and it worked very well on my device(HTC raidar 4G, Nexus 7, Galaxy)

But If I use other phone(other htc phone, motorola atrix) it crashed. I track code and find that devices have different view.

http://stackoverflow.com/questions/11650847/decorview-child-framelayout
<- This issue has similar problem with me.

That thread said that remove NoTitleBar attribute, but it doesn't work to me.

So I asked here : http://stackoverflow.com/questions/12109512/decorview-child-framelayout-is-different-at-devices

and one said that do not use android.R.id.content since it is different with devices. Have you any idea about this? Thanks,

@bk138
Copy link
Owner

bk138 commented Aug 26, 2012

Could you provide a stack trace of the crash? We heard from at least one user with a similar problem...

@stefanreimers
Copy link

I do experience similar problems with a basic app, that works on Nexus S (Android 4.1.1), but crashes on others (Samsung Galaxy S and Huawei Ideos X3, both 2.3). The app is designed to work with API version 9. Above stackoverflow threads don't give me a clue. Has anyone made similar experience?

My stack trace would be:
08-27 10:56:18.330: D/AndroidRuntime(1276): Shutting down VM
08-27 10:56:18.330: W/dalvikvm(1276): threadid=1: thread exiting with uncaught exception (group=0x40020560)
08-27 10:56:18.340: E/AndroidRuntime(1276): FATAL EXCEPTION: main
08-27 10:56:18.340: E/AndroidRuntime(1276): java.lang.ClassCastException: com.android.internal.policy.impl.PhoneWindow$DecorView
08-27 10:56:18.340: E/AndroidRuntime(1276): at com.coboltforge.slidemenu.SlideMenu.show(SlideMenu.java:245)
08-27 10:56:18.340: E/AndroidRuntime(1276): at com.coboltforge.slidemenu.SlideMenu.show(SlideMenu.java:237)
08-27 10:56:18.340: E/AndroidRuntime(1276): at com.example.googlemaps.MainActivity$1.onClick(MainActivity.java:54)
08-27 10:56:18.340: E/AndroidRuntime(1276): at android.view.View.performClick(View.java:2485)
08-27 10:56:18.340: E/AndroidRuntime(1276): at android.view.View$PerformClick.run(View.java:9080)
08-27 10:56:18.340: E/AndroidRuntime(1276): at android.os.Handler.handleCallback(Handler.java:587)
08-27 10:56:18.340: E/AndroidRuntime(1276): at android.os.Handler.dispatchMessage(Handler.java:92)
08-27 10:56:18.340: E/AndroidRuntime(1276): at android.os.Looper.loop(Looper.java:123)
08-27 10:56:18.340: E/AndroidRuntime(1276): at android.app.ActivityThread.main(ActivityThread.java:3695)
08-27 10:56:18.340: E/AndroidRuntime(1276): at java.lang.reflect.Method.invokeNative(Native Method)
08-27 10:56:18.340: E/AndroidRuntime(1276): at java.lang.reflect.Method.invoke(Method.java:507)
08-27 10:56:18.340: E/AndroidRuntime(1276): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:842)
08-27 10:56:18.340: E/AndroidRuntime(1276): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:600)
08-27 10:56:18.340: E/AndroidRuntime(1276): at dalvik.system.NativeStart.main(Native Method)
08-27 10:56:20.980: I/Process(1276): Sending signal. PID: 1276 SIG: 9

Thanks

@bk138
Copy link
Owner

bk138 commented Aug 27, 2012

@stefanreimers
Copy link

I emptied my layout xml to verify there is no problem in that --> issue remains anyway, even with the layout.xml of your example project.
But it turns out that

android:theme="@android:style/Theme.NoTitleBar"

within the activity tag of the manifest file is the problem. As soon as I remove this attribute, sliding works fine. But displaying the title bar is not the intended solution.

@bk138
Copy link
Owner

bk138 commented Aug 27, 2012

That is, it fails with android:theme="@android:style/Theme.NoTitleBar" applied to the example project?

@stefanreimers
Copy link

Yes, the example project crashes when adding the NoTitleBar attribute to the manifest. Did Darren - who posted the comment about a possible solution on your website - supply any patch for that?

@bk138
Copy link
Owner

bk138 commented Aug 27, 2012

Nope, but at least we can reproduce it now and find a fix...

@sungeuns
Copy link
Author

Hi Guys,

I didn't add NoTitleBar attribute, but still have a problem. So I changed a
code as possible as I can, but it have limitation in some devices.

Here is related thread:
http://stackoverflow.com/questions/12109512/decorview-child-framelayout-is-different-at-devices

I apply his comment and doesn't use android.R.id.content in here. Still
works well in some devices,

but still have a little problem when using show() method in devices that
have a problem before.

2012/8/28 Christian Beier [email protected]

Nope, but at least we can reproduce it now and find a fix...


Reply to this email directly or view it on GitHubhttps://github.com//issues/5#issuecomment-8058378.

Best regards,
Seongeun So

@bk138
Copy link
Owner

bk138 commented Aug 27, 2012

Guys,
what about 9b9ae22 ?

@stefanreimers
Copy link

Works for me, thanks a lot!

@sungeuns
Copy link
Author

Hi Guys,

It can catch crash, but still have a problem in my atrix.

There's no crash, but the problem is, slide menu cover original view.

If it run as normal, then original view move to right side, and devide
screen with slide menu, but in my atrix, slide menu covered original view
so it is not good to see. (But, hide() method works well.)

I've tried to fix to a lot, but still have no progress. (My atrix is not
custom rom. it's 2.3 version pure rom from motorola)

2012/8/28 stefanreimers [email protected]

Works for me, thanks a lot!


Reply to this email directly or view it on GitHubhttps://github.com//issues/5#issuecomment-8063810.

Best regards,
Seongeun So

@bk138
Copy link
Owner

bk138 commented Aug 28, 2012

Can you please post a screenshot of the hierarchyviewer inspecting the atrix?

@sungeuns
Copy link
Author

Attahed file is screen shot from atrix. Slide menu cover original view.

I've already tried to use hierarchyviewer but doesn't work. It cause error.

2012/8/28 Christian Beier [email protected]

Can you please post a screenshot of the hierarchyviewer inspecting the
atrix?


Reply to this email directly or view it on GitHubhttps://github.com//issues/5#issuecomment-8094290.

Best regards,
Seongeun So

@bk138
Copy link
Owner

bk138 commented Aug 28, 2012

You'll have to upload the image and post a link. Hierarchy viewer only works in debug mode, not normal run mode....

@sungeuns
Copy link
Author

I heard that hierarchy viewer only run on emulator.

Is it work on real device? I searched about that but there's no solution

2012/8/29 Christian Beier [email protected]

You'll have to upload the image and post a link. Hierarchy viewer only
works in debug mode, not normal run mode....


Reply to this email directly or view it on GitHubhttps://github.com//issues/5#issuecomment-8095612.

Best regards,
Seongeun So

@sungeuns
Copy link
Author

I use this:
http://enadroid.blogspot.kr/2011/08/hierarchyviewer-unable-to-debug-device.html

hierarchy viewer works if use that post.

Here is my link:
http://www.flickr.com/photos/86018774@N07/7881131362/

2012/8/29 Seongeun So [email protected]

I heard that hierarchy viewer only run on emulator.

Is it work on real device? I searched about that but there's no solution

2012/8/29 Christian Beier [email protected]

You'll have to upload the image and post a link. Hierarchy viewer only
works in debug mode, not normal run mode....


Reply to this email directly or view it on GitHubhttps://github.com//issues/5#issuecomment-8095612.

Best regards,
Seongeun So

Best regards,
Seongeun So

@bk138
Copy link
Owner

bk138 commented Aug 28, 2012

Hmm, I suspect that the tabhost could be the culprit. Have you tried the included minimal sample app on your Atrix? (Maybe TabHost is not animatable??)

@sungeuns
Copy link
Author

I delete TabHost, and tried again.

This is hierarchy view:
http://www.flickr.com/photos/86018774@N07/7884675224/

Still have a same problem,

2012/8/29 Christian Beier [email protected]

Hmm, I suspect that the tabhost could be the culprit. Have you tried the
included minimal sample app on your Atrix? (Maybe TabHost is not
animatable??)


Reply to this email directly or view it on GitHubhttps://github.com//issues/5#issuecomment-8101726.

Best regards,
Seongeun So

@bk138
Copy link
Owner

bk138 commented Aug 29, 2012

Now there is another child to the phone decor view - what is it?

@UdayHarihar
Copy link

It works fine for android 2.3 to 4.2 .
but when i tried it by installing it in 4.3 latest version of android , the slide menu get crash .
I'm not getting what's the reason ??

Error Log : http://stackoverflow.com/questions/17874416/sliding-menu-is-not-working-in-android-4-3-version

@bk138
Copy link
Owner

bk138 commented Jul 26, 2013

See this report here #18 (comment)

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

4 participants