Google Cloud Messaging for Chrome - Multiple messages

136 views Asked by At

I am currently working on a Chrome extension which uses the chrome.pushMessaging API provided by Chrome.

I register push messaging callback in the background page of the extension:

chrome.pushMessaging.onMessage.addListener(pushMessageReceivedCallback);

The problem is that the pushMessageReceivedCallback gets hit immediately with the last four messages that were sent to the extensions channel ID. This behaviour seems the same on on computer I use.

Is there some way if consuming GCM messages? Once I have seen the message once, I don't want it to keep arriving every time the extension is loaded.

Thanks.

0

There are 0 answers