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