onStart() and onStartCommand() still called in 2.0 and higher

眉间皱痕 提交于 2019-12-01 05:19:51

On that blog post, the base implementantions of onStart and onStartCommand are not called. Pressumably, one of them is calling the other.

songzhw

The source code of onStartCommand() is:

    public int onStartCommand(Intent intent, int flags, int startId) {
        onStart(intent, startId);
        return mStartCompatibility ? START_STICKY_COMPATIBILITY : START_STICKY;
    }

So it still calls onStart();

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!