Android TV 中的 Google Assistant 和应用程序操作出现问题

问题描述 投票:0回答:2

我使用应用程序操作中的自定义意图,执行命令后,助手不会关闭,它仍然以扭曲的颤动保持打开状态,但焦点仍然在我们的应用程序上,要关闭助手,我需要按主页按钮。

actions.xml:

<?xml version ="1.0" encoding ="utf-8"?>
<actions>
    <action
        intentName="custom.actions.intent.OPEN_APP_FEATURE"
        queryPatterns="@array/feature_queries">
        <parameter
            name="action"
            type="https://schema.org/Text" />
        <parameter
            name="text"
            type="https://schema.org/Text" />

        <fulfillment urlTemplate="https://safarov.page.link/open{?item_action,item_text}">
            <parameter-mapping
                intentParameter="action"
                urlParameter="item_action" />
            <parameter-mapping
                intentParameter="text"
                urlParameter="item_text" />
        </fulfillment>
    </action>
</actions>

AndroidManifest.xml:

<intent-filter
    android:autoVerify="true"
    tools:targetApi="m">
    <action android:name="android.intent.action.VIEW" />

    <category android:name="android.intent.category.DEFAULT" />
    <category android:name="android.intent.category.BROWSABLE" />

    <data
        android:host="safarov.page.link"
        android:scheme="https" />
</intent-filter>

意图正确执行,但助手未关闭。

android actions-on-google android-tv app-actions google-assistant
2个回答
1
投票

Android TV 目前不支持应用操作。请继续关注更新。


0
投票

这个还不支持吗?通过新的 Shortcuts.xml 实现,我可以使其适用于移动设备,但不适用于电视。我有一些关于当你尝试在 android studio 上测试时的日志,我可以看到在开始测试之前尝试检查小部件的信息......对于移动设备,数据显示一个值“快捷方式”,当我执行以下操作时同样,在电视上使用相同的代码,值更改为“操作”,并显示错误。

那么也许这还没有准备好用于电视喷气机?

© www.soinside.com 2019 - 2024. All rights reserved.