How to turn on the screen of the mobile when a mobile application launches a notification?
My application launches this type of notifications depending on specific parameters, I want that apart from vibrating and sounding turn on the screen too, what a pity if I have not made myself understood.
public void carrera(int id, int iconid, String titulo, String contenido) {
Intent intent = new Intent(this, MapsActivity.class);
intent.addFlags(Intent.FLAG_ACTIVITY_BROUGHT_TO_FRONT | Intent.FLAG_ACTIVITY_SINGLE_TOP);
PendingIntent contIntent = PendingIntent.getActivity(MapsActivity.this, 0, intent,PendingIntent.FLAG_UPDATE_CURRENT);
NotificationCompat.Builder builder =
(NotificationCompat.Builder) new NotificationCompat.Builder(this)
.setSmallIcon(iconid)
.setLargeIcon(BitmapFactory.decodeResource(getResources(),
R.mipmap.poder_amarillo))
.setContentTitle(titulo)
.setContentIntent(contIntent)
.setSound((Uri.parse("android.resource://" + getPackageName() + "/" + R.raw.vip)))
//.setVibrate(new long[]{ 1000,500,1000,800,1000,1500 })
.setLights(Color.RED,3000,3000)
.setVisibility(NotificationCompat.VISIBILITY_PUBLIC)
.setPriority(Notification.PRIORITY_MAX)
.setContentText(contenido);
notificacion.notify(id, builder.build());
}