Glassware with listed command is not visible in menu after upgrade to XE16

风格不统一 提交于 2019-12-23 02:20:34

问题


My app is using the "play a game" command to be started by voice command and be visible in the Google Glass menu.

After upgrading to XE16 it disappeared from the menu and I could not find any upgrade notes for developers to make it work.

What changes needs to be made for the voice start command to work on the upgraded glass version ?


回答1:


After upgrade to XE16 the following changes must be made for voice activation and enlisting in menu.

Listed voice commands:

Listed commands are commands available by default and they can be found here.

The triggering XML should be changed from:
<trigger keyword="@string/play_a_game" />
to:
<trigger command="PLAY_A_GAME" />

Unlisted voice commands:

Unlisted commands are for development purposes only and you will have to submit your command for approval.

You don't have to change your triggering XML file, but you will have to add the following permission to your AndroidManifest.xml:

<uses-permission android:name="com.google.android.glass.permission.DEVELOPMENT" />

More info about starting glassware: https://developers.google.com/glass/develop/gdk/starting-glassware



来源:https://stackoverflow.com/questions/23287516/glassware-with-listed-command-is-not-visible-in-menu-after-upgrade-to-xe16

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