更新时间:2023-02-11 19:21:16
的的在这里的 是很好的例子,addview的服务,你也可以使用监听器,如果你想在服务。
here is nice example to addview in Service and also you can use listeners if you want in services.
我也在寻找服务听众执行,终于找到了。
i was also looking for the listeners implementation in service and finally found it.
记得加权限
<uses-permission android:name="android.permission.SYSTEM_ALERT_WINDOW"/>
和增加服务类
<application>
.
.
<service android:name=".YourServiceClass"></service>
.
.
</application>
在AndroidManifest.xml中。
in AndroidManifest.xml.