Jak sprawić, aby aplikacja otrzymywała transmisję, gdy inne aplikacje są zainstalowane lub usunięte

Chcę stworzyć aplikację, która może odbierać transmisję, gdy inne aplikacje na urządzeniu są zainstalowane lub usunięte.

mój kod

w zbiorze:

<receiver android:name=".apps.AppListener">
    <intent-filter android:priority="100">
         <action android:name="android.intent.action.PACKAGE_INSTALL"/>
         <action android:name="android.intent.action.PACKAGE_ADDED"/>  
         <action android:name="android.intent.action.PACKAGE_REMOVED"/>
    </intent-filter>
</receiver>

w AppListener:

import android.content.BroadcastReceiver;
import android.content.Context;
import android.content.Intent;
import android.util.Log;

public class AppListener extends BroadcastReceiver {

@Override
public void onReceive(Context context, Intent arg1) {
    // TODO Auto-generated method stub
    Log.v(TAG, "there is a broadcast");
    }
}

ale nie mogę odbierać żadnej transmisji. Myślę, że ten problem wynika z uprawnień do aplikacji, jakiegokolwiek pomysłu?

Dzięki za pomoc.

questionAnswers(3)

yourAnswerToTheQuestion