Giter VIP home page Giter VIP logo

Comments (4)

Staticzll avatar Staticzll commented on June 4, 2024

(N%YZ7FYQ2 J@4S}DZ5740
Y2U%1(ZM7D}V)MML8C3C~S7
在activity中调用startService(Intent(this, MyService::class.java)),就出现lateinit property context has not been initialized,麻烦处理一下这个bug。

from floatingx.

Petterpx avatar Petterpx commented on June 4, 2024

startService(Intent(this, MyService::class.java))

这是多进程原因导致,不过我本地尝试 provider增加multiprocess,并没有生效,可能后续要增加手动设置context。

from floatingx.

Petterpx avatar Petterpx commented on June 4, 2024

(N%YZ7FYQ2 J@4S}DZ5740 Y2U%1(ZM7D}V)MML8C3C~S7 在activity中调用startService(Intent(this, MyService::class.java)),就出现lateinit property context has not been initialized,麻烦处理一下这个bug。

可以先在application里判断一下当前进程,非主进程就不要初始化了,后续这里我再想想该怎么优化去支持多进程。

from floatingx.

Petterpx avatar Petterpx commented on June 4, 2024

已更新,1.2.5,初始化浮窗时,需要手动设置setContext(),从而避免该问题。

from floatingx.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.