多屏互动

  1. 手机控制TV端  TV端service Demo

        工程  https://github.com/kylinhuang/ClingServiceForAndroid.git

    Cling参考文档

    官方文档:http://4thline.org/projects/cling/core/manual/cling-core-manual.html#section.BinaryLightClient

    中文文档:http://vaero.blog.51cto.com/4350852/1143278

    wiki:http://wikidroid.sinaapp.com/Cling

  问题总结

        1.键值适配  

        new Instrumentation().sendKeyDownUpSync(code);

        使系统进行处理

        

        2.连续按同一按键,只执行一次

        处理:SwitchPower setTarget()中                String targetOldValue = target;

        每次更改如         String targetOldValue = "NO";

        

        Activity propertyChange()中

        arg0.getPropertyName()分别为target,status,_EventedStateVariables,Status




你可能感兴趣的:(多屏互动)