volumen vibracion tono tiene teclado suena sonido samsung quitar porque notificaciones llamada escucha desactivar configurar como celular cambiar app android notifications

vibracion - notificaciones android app



Android: sonido de notificaciones deshabilitado (2)

Bueno, funcionó para mí al hacer esto:

myNotification.defaults = 0;

Pruébalo =)

Tengo una notificación con este código:

Notification notifica = new Notification(); notifica.flags |= Notification.FLAG_AUTO_CANCEL; notifica.icon = R.drawable.serie_notification; notifica.when = System.currentTimeMillis();

con notifica.defaults = notifica.defaults | Notification.DEFAULT_SOUND; Habilito el sonido predeterminado, pero si quiero desactivar el sonido, ¿cómo puedo hacerlo?


Es posible hacer eso Básicamente simplemente habilite todos los demás valores predeterminados de notificación excepto el sonido (que es Notification.DEFAULT_SOUND).

Aquí hay un ejemplo que funcionará para usted:

myNotification.defaults = 0; myNotification.defaults |= Notification.DEFAULT_VIBRATE;

Aquí están todas las opciones disponibles que puede seleccionar:

Notification.DEFAULT_LIGHTS Notification.DEFAULT_VIBRATE Notification.DEFAULT_SOUND Notification.DEFAULT_ALL // This enables all above 3