3

I am using this code to the third party applications :

 List<ApplicationInfo> packages = pm.getInstalledApplications(PackageManager.GET_META_DATA);

    for (ApplicationInfo appInfo : packages)
    {
        if ((appInfo.flags & ApplicationInfo.FLAG_SYSTEM) != 0)
        {
            // IS A SYSTEM APP
        }
        else
        {
            // Third Party Applications
        }
    }

This code is almost working fine , but I am not getting some third party applications. Like Gmail , Google Play Store. Some applications which I am getting are Google Play Services , Skype.

What could be the problem ? Am I missing some flags ?

4

1 回答 1

3

我找到了答案,我错过了这个标志

ApplicationInfo.FLAG_UPDATED_SYSTEM_APP
于 2013-07-01T10:12:58.340 回答