There is the problem with android push notifications (GCM) on android 3.1 : when my app is CLOSED - broadcast receiver which should handle GCM push messages (Intents) is never called.
In lower versions of android everything works just fine. Broadcast reciever is always called (even when app is closed).
I know that from Android 3.1 there is new concept: when application is not running it is in "stopped" state: http://developer.android.com/about/versions/android-3.1.html#launchcontrols
So if you want to start "stopped" application via Intent - you should add FLAG_INCLUDE_STOPPED_PACKAGES flag to Intent.
But problem is that i can't add FLAG_INCLUDE_STOPPED_PACKAGES flag to GCM Intent because GCM Intents (i mean "com.google.android.c2dm.intent.RECEIVE" and "com.google.android.c2dm.intent.REGISTRATION") are thrown by the OS.
So my question is: how can i handle push messages (on android 3.1) from GCM via broadcast reciever in situation when application (in which broadcastreceiver is registered) is closed (is in "stopped" state) ?