Unable to execute initial Android Wear Hello World App in eclipse

匿名 (未验证) 提交于 2019-12-03 08:46:08

问题:

After intial Eclipse Luna setup when I try to run the intial Hello World app in the Android Wear emulator, its getting stopped showing "You cannot combine swipe dismissal and the action bar" error in logcat.Please help me to solve this issue.

回答1:

I had the same problem yesterday. I solved it by running the application in full screen mode, I do not think this is the best solution, but it worked, although this does not have the action bar.

In you onCreate method add this before the setContentView.

requestWindowFeature(Window.FEATURE_NO_TITLE); getWindow().setFlags(WindowManager.LayoutParams.FLAG_FULLSCREEN, WindowManager.LayoutParams.FLAG_FULLSCREEN); 


回答2:

Make sure you're not using a theme that includes an action bar. Consider using

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


回答3:

You need to use Theme.DeviceDefault as your android:theme

Here the full steps on how to do it using eclipse. https://medium.com/@tangtungai/how-to-develop-and-package-android-wear-app-using-eclipse-ef1b34126a5d



标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!