Disable all incoming message notifications in Symbian S60v3

How to programmatically disable these notifications when a message pops up on my Symbian S60v3 phone:

  • Message tone (I think I have one)
  • Flashing LEDs
  • Phone vibration
  • The screen lights up
  • Message icon (I think I got it too)

and which SDK can I use? I prefer to use Python, but I don't think the Python SDK for Symbian is too complete, so I think I should use C ++

Any help is greatly appreciated, thanks

+2


source to share


2 answers


The bad news is that you cannot rely on using the message center APIs to view messages to process them before notifying the user. Often you will be able to process them quickly enough, but on phones with faster processors, the user sometimes sees some kind of notification - either a beep, or the screen lights up, etc. I used this method, then on N95 the phone is still sent when receiving SMS.

The good news is that if you are only concerned about SMS messages, there is a more reliable way to intercept them so that the user never sees any notifications. You can use a socket to receive a message before the message center receives it.



Here's an example: http://symbian.devtricks.mobi/tricks/silent_receiving_of_sms_messages/

I switched my code to something like this and found it works much better. As far as I know, there is no way to do this with Python.

+1


source


I was able to disable all notifications by creating MMsvSessionObserver and doing the following in HandleSessionEventL:



TMsvId* entryId = STATIC_CAST(TMsvId*, aArg2);

CMsvEntry* msvEntry = myMsvSession->GetEntryL(entryId); 
TMsvEntry entry = msvEntry->Entry();

entry.SetNew(EFalse);
entry.SetUnread(EFalse);
entry.SetVisible(EFalse);

msvEntry->ChangeL(entry);

      

+2


source







All Articles