Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
一个主要活动调用一个意图来做某事(比如安装某个 apk),并且主要活动有一个接收器来监视意图动作;但问题是,在某些情况下,如果内存不足,主要活动将被杀死,意图接收者也是如此。如何让接收器保持活动状态?
您应该将接收器移出活动状态,并在您的 AndroidManifest.xml 中声明它。