/**
* Handles the intent with the notifications information.
*Returns true if the intent was handled.
*/
public boolean HandleIntent(IntentWrapper StartingIntent) {
if (StartingIntent.IsInitialized() == false)
return false;
if (StartingIntent.getAction().equals("b4a_notificationlistener")) {
String event = (String) StartingIntent.GetExtra("event");
StatusBarNotification sbn = StartingIntent.getObject().getParcelableExtra("sbn");
if (event.equals("posted")) {
ba.raiseEvent(this, eventName + "_notificationposted", AbsObjectWrapper.ConvertToWrapper(
new StatusBarNotificationWrapper(), sbn));
}
else if (event.equals("removed")) {
ba.raiseEvent(this, eventName + "_notificationremoved", AbsObjectWrapper.ConvertToWrapper(
new StatusBarNotificationWrapper(), sbn));
}
return true;
}
return false;
}