SlideShare a Scribd company logo
1 of 32
Download to read offline
builder.setContentTitle("Private notification")
.setContentText("Private notification content")
.setVisibility(Notification.VISIBILITY_PRIVATE)
.setColor(Color.argb(1, 204, 0, 0))
.setPublicVersion(
new Notification.Builder(this)
.setColor(Color.argb(1, 0, 153, 204))
.setSmallIcon(R.drawable.ic_action_web_site)
.setContentText("Public version of private content")
.setContentTitle("Public version")
.build());
builder.setPriority(Notification.PRIORITY_HIGH)
.setContentTitle("High priority")
.setDefaults(Notification.DEFAULT_VIBRATE);
mng.notify(1, builder.build());
PendingIntent pi = PendingIntent.getActivity(this, 0,
new Intent(Intent.ACTION_VIEW).setData(Uri.parse("http://android.com")), 0);
builder.setFullScreenIntent(pi, true)
.setContentIntent(pi)
.setContentTitle("Notification with Fullscreen Intent")
.setContentText("Content text");
Notification notification =
new Notification.Builder(BridgeActivity.this)
.setSmallIcon(R.drawable.ic_launcher)
.setLargeIcon(BitmapFactory.decodeResource(getResources(),
R.drawable.bg_wear_notes))
.setContentTitle("Android.com")
.setContentText("Check out news from android.com!")
.setLocalOnly(!cbBridgeNotification.isChecked())
.setAutoCancel(true)
.build();
// Create wear only action
PendingIntent piw = PendingIntent.getActivity(this, 0,
new Intent(Intent.ACTION_VIEW).setData(Uri.parse("http://android.com/wear")),
PendingIntent.FLAG_UPDATE_CURRENT);
Notification.Action wearOnlyAction =
new Notification.Action.Builder(R.drawable.ic_action_web_site, "Wear only", piw).build();
!
builder.extend(new Notification.WearableExtender().addAction(wearOnlyAction));
remoteInput = new RemoteInput.Builder(VoiceInputResultActivity.KEY_VOICE_INPUT)
.setLabel("Say message")
.setChoices(getResources().getStringArray(R.array.reply_choices))
.build();
!
// 중략
!
Notification.Action replyAction =
new Notification.Action.Builder(R.drawable.ic_action_web_site, "Reply", pi)
.addRemoteInput(remoteInput).build();
!
Notification.Builder builder = new Notification.Builder(this)
.setSmallIcon(R.drawable.ic_action_web_site)
.setLargeIcon(BitmapFactory.decodeResource(getResources(), R.drawable.img_gaejugi))
.setAutoCancel(true)
.setContentTitle("John Doe")
.setContentText("Lunch?")
.extend(new Notification.WearableExtender().addAction(replyAction));
Notification.Builder builder = new Notification.Builder(this);
builder.setSmallIcon(R.drawable.ic_action_web_site)
//… 생략
!
Notification secondPage = new Notification.Builder(this)
// 생략
!
Notification thirdPage = new Notification.Builder(this)
// 생략
!
Notification pagingNotification = new Notification.WearableExtender()
.addPage(secondPage)
.addPage(thirdPage)
.extend(builder).build();
Notification noti1 = new Notification.Builder(this).setGroup(GROUP_MESSAGE)
// 생략
!
Notification noti2 = new Notification.Builder(this).setGroup(GROUP_MESSAGE)
// 생략
!
NotificationManager mng = (NotificationManager) getSystemService(NOTIFICATION_SERVICE);
mng.notify(0, noti1);
mng.notify(1, noti2);
!
Notification summary = new Notification.Builder(this)
// 생략
.setGroup(GROUP_MESSAGE)
.setGroupSummary(true)
.extend(new Notification.WearableExtender()
.setBackground(BitmapFactory.decodeResource(
getResources(), R.drawable.img_gaejugi)))
.build();
!
mng.notify(3, summary);
Notifications for Android L & wear
Notifications for Android L & wear
Notifications for Android L & wear

More Related Content

Similar to Notifications for Android L & wear

Android Wear – IO Extended
Android Wear – IO ExtendedAndroid Wear – IO Extended
Android Wear – IO ExtendedDouglas Drumond
 
Local Notification Tutorial
Local Notification TutorialLocal Notification Tutorial
Local Notification TutorialKetan Raval
 
Getting Ready For Android Wear
Getting Ready For Android WearGetting Ready For Android Wear
Getting Ready For Android WearRaveesh Bhalla
 
Introduction to Android Wear
Introduction to Android WearIntroduction to Android Wear
Introduction to Android WearPeter Friese
 
Session #8 adding magic to your app
Session #8  adding magic to your appSession #8  adding magic to your app
Session #8 adding magic to your appVitali Pekelis
 
GDG GeorgeTown Devfest 2014 Presentation: Android Wear: A Developer's Perspec...
GDG GeorgeTown Devfest 2014 Presentation: Android Wear: A Developer's Perspec...GDG GeorgeTown Devfest 2014 Presentation: Android Wear: A Developer's Perspec...
GDG GeorgeTown Devfest 2014 Presentation: Android Wear: A Developer's Perspec...mharkus
 
Introduction to Android Wear - Peter Friese
Introduction to Android Wear - Peter FrieseIntroduction to Android Wear - Peter Friese
Introduction to Android Wear - Peter FrieseJAXLondon2014
 
Slightly Advanced Android Wear ;)
Slightly Advanced Android Wear ;)Slightly Advanced Android Wear ;)
Slightly Advanced Android Wear ;)Alfredo Morresi
 
That’s My App - Running in Your Background - Draining Your Battery
That’s My App - Running in Your Background - Draining Your BatteryThat’s My App - Running in Your Background - Draining Your Battery
That’s My App - Running in Your Background - Draining Your BatteryMichael Galpin
 
Introduction to Android Wear
Introduction to Android WearIntroduction to Android Wear
Introduction to Android WearPeter Friese
 
NB Explain Every Line Of Code public class MainActivity.pdf
NB   Explain Every Line Of Code   public class MainActivity.pdfNB   Explain Every Line Of Code   public class MainActivity.pdf
NB Explain Every Line Of Code public class MainActivity.pdfaceindustriesjal
 
create-netflix-clone-04-server-continued.pdf
create-netflix-clone-04-server-continued.pdfcreate-netflix-clone-04-server-continued.pdf
create-netflix-clone-04-server-continued.pdfShaiAlmog1
 
Developing for android wear
Developing for android wearDeveloping for android wear
Developing for android wearThomas Oldervoll
 
Why SOLID matters - even for JavaScript
Why SOLID matters - even for JavaScriptWhy SOLID matters - even for JavaScript
Why SOLID matters - even for JavaScriptmartinlippert
 
Android Wearables ii
Android Wearables iiAndroid Wearables ii
Android Wearables iiKetan Raval
 

Similar to Notifications for Android L & wear (20)

Android Wear – IO Extended
Android Wear – IO ExtendedAndroid Wear – IO Extended
Android Wear – IO Extended
 
Android wear (coding)
Android wear (coding)Android wear (coding)
Android wear (coding)
 
Local Notification Tutorial
Local Notification TutorialLocal Notification Tutorial
Local Notification Tutorial
 
Getting Ready For Android Wear
Getting Ready For Android WearGetting Ready For Android Wear
Getting Ready For Android Wear
 
Introduction to Android Wear
Introduction to Android WearIntroduction to Android Wear
Introduction to Android Wear
 
Androidppt 1
Androidppt 1Androidppt 1
Androidppt 1
 
Session #8 adding magic to your app
Session #8  adding magic to your appSession #8  adding magic to your app
Session #8 adding magic to your app
 
GDG GeorgeTown Devfest 2014 Presentation: Android Wear: A Developer's Perspec...
GDG GeorgeTown Devfest 2014 Presentation: Android Wear: A Developer's Perspec...GDG GeorgeTown Devfest 2014 Presentation: Android Wear: A Developer's Perspec...
GDG GeorgeTown Devfest 2014 Presentation: Android Wear: A Developer's Perspec...
 
Introduction to Android Wear - Peter Friese
Introduction to Android Wear - Peter FrieseIntroduction to Android Wear - Peter Friese
Introduction to Android Wear - Peter Friese
 
Slightly Advanced Android Wear ;)
Slightly Advanced Android Wear ;)Slightly Advanced Android Wear ;)
Slightly Advanced Android Wear ;)
 
That’s My App - Running in Your Background - Draining Your Battery
That’s My App - Running in Your Background - Draining Your BatteryThat’s My App - Running in Your Background - Draining Your Battery
That’s My App - Running in Your Background - Draining Your Battery
 
Android workshop
Android workshopAndroid workshop
Android workshop
 
Introduction to Android Wear
Introduction to Android WearIntroduction to Android Wear
Introduction to Android Wear
 
F2
F2F2
F2
 
NB Explain Every Line Of Code public class MainActivity.pdf
NB   Explain Every Line Of Code   public class MainActivity.pdfNB   Explain Every Line Of Code   public class MainActivity.pdf
NB Explain Every Line Of Code public class MainActivity.pdf
 
create-netflix-clone-04-server-continued.pdf
create-netflix-clone-04-server-continued.pdfcreate-netflix-clone-04-server-continued.pdf
create-netflix-clone-04-server-continued.pdf
 
Developing for android wear
Developing for android wearDeveloping for android wear
Developing for android wear
 
Why SOLID matters - even for JavaScript
Why SOLID matters - even for JavaScriptWhy SOLID matters - even for JavaScript
Why SOLID matters - even for JavaScript
 
Android Wear Development
Android Wear DevelopmentAndroid Wear Development
Android Wear Development
 
Android Wearables ii
Android Wearables iiAndroid Wearables ii
Android Wearables ii
 

More from Taeho Kim

Kotlin: Let's Make Android Great Again
Kotlin: Let's Make Android Great AgainKotlin: Let's Make Android Great Again
Kotlin: Let's Make Android Great AgainTaeho Kim
 
레진코믹스가 코틀린으로 간 까닭은?
레진코믹스가 코틀린으로 간 까닭은?레진코믹스가 코틀린으로 간 까닭은?
레진코믹스가 코틀린으로 간 까닭은?Taeho Kim
 
RxJava in Action
RxJava in ActionRxJava in Action
RxJava in ActionTaeho Kim
 
Android Studio 2.2 - What's new in Android development tools
Android Studio 2.2 - What's new in Android development toolsAndroid Studio 2.2 - What's new in Android development tools
Android Studio 2.2 - What's new in Android development toolsTaeho Kim
 
Multi Window in Android N
Multi Window in Android NMulti Window in Android N
Multi Window in Android NTaeho Kim
 
Material Design with Support Design Library
Material Design with Support Design LibraryMaterial Design with Support Design Library
Material Design with Support Design LibraryTaeho Kim
 

More from Taeho Kim (6)

Kotlin: Let's Make Android Great Again
Kotlin: Let's Make Android Great AgainKotlin: Let's Make Android Great Again
Kotlin: Let's Make Android Great Again
 
레진코믹스가 코틀린으로 간 까닭은?
레진코믹스가 코틀린으로 간 까닭은?레진코믹스가 코틀린으로 간 까닭은?
레진코믹스가 코틀린으로 간 까닭은?
 
RxJava in Action
RxJava in ActionRxJava in Action
RxJava in Action
 
Android Studio 2.2 - What's new in Android development tools
Android Studio 2.2 - What's new in Android development toolsAndroid Studio 2.2 - What's new in Android development tools
Android Studio 2.2 - What's new in Android development tools
 
Multi Window in Android N
Multi Window in Android NMulti Window in Android N
Multi Window in Android N
 
Material Design with Support Design Library
Material Design with Support Design LibraryMaterial Design with Support Design Library
Material Design with Support Design Library
 

Recently uploaded

Python Notes for mca i year students osmania university.docx
Python Notes for mca i year students osmania university.docxPython Notes for mca i year students osmania university.docx
Python Notes for mca i year students osmania university.docxRamakrishna Reddy Bijjam
 
Sensory_Experience_and_Emotional_Resonance_in_Gabriel_Okaras_The_Piano_and_Th...
Sensory_Experience_and_Emotional_Resonance_in_Gabriel_Okaras_The_Piano_and_Th...Sensory_Experience_and_Emotional_Resonance_in_Gabriel_Okaras_The_Piano_and_Th...
Sensory_Experience_and_Emotional_Resonance_in_Gabriel_Okaras_The_Piano_and_Th...Pooja Bhuva
 
QUATER-1-PE-HEALTH-LC2- this is just a sample of unpacked lesson
QUATER-1-PE-HEALTH-LC2- this is just a sample of unpacked lessonQUATER-1-PE-HEALTH-LC2- this is just a sample of unpacked lesson
QUATER-1-PE-HEALTH-LC2- this is just a sample of unpacked lessonhttgc7rh9c
 
OSCM Unit 2_Operations Processes & Systems
OSCM Unit 2_Operations Processes & SystemsOSCM Unit 2_Operations Processes & Systems
OSCM Unit 2_Operations Processes & SystemsSandeep D Chaudhary
 
How to Add a Tool Tip to a Field in Odoo 17
How to Add a Tool Tip to a Field in Odoo 17How to Add a Tool Tip to a Field in Odoo 17
How to Add a Tool Tip to a Field in Odoo 17Celine George
 
UGC NET Paper 1 Unit 7 DATA INTERPRETATION.pdf
UGC NET Paper 1 Unit 7 DATA INTERPRETATION.pdfUGC NET Paper 1 Unit 7 DATA INTERPRETATION.pdf
UGC NET Paper 1 Unit 7 DATA INTERPRETATION.pdfNirmal Dwivedi
 
dusjagr & nano talk on open tools for agriculture research and learning
dusjagr & nano talk on open tools for agriculture research and learningdusjagr & nano talk on open tools for agriculture research and learning
dusjagr & nano talk on open tools for agriculture research and learningMarc Dusseiller Dusjagr
 
Simple, Complex, and Compound Sentences Exercises.pdf
Simple, Complex, and Compound Sentences Exercises.pdfSimple, Complex, and Compound Sentences Exercises.pdf
Simple, Complex, and Compound Sentences Exercises.pdfstareducators107
 
Beyond_Borders_Understanding_Anime_and_Manga_Fandom_A_Comprehensive_Audience_...
Beyond_Borders_Understanding_Anime_and_Manga_Fandom_A_Comprehensive_Audience_...Beyond_Borders_Understanding_Anime_and_Manga_Fandom_A_Comprehensive_Audience_...
Beyond_Borders_Understanding_Anime_and_Manga_Fandom_A_Comprehensive_Audience_...Pooja Bhuva
 
FSB Advising Checklist - Orientation 2024
FSB Advising Checklist - Orientation 2024FSB Advising Checklist - Orientation 2024
FSB Advising Checklist - Orientation 2024Elizabeth Walsh
 
Play hard learn harder: The Serious Business of Play
Play hard learn harder:  The Serious Business of PlayPlay hard learn harder:  The Serious Business of Play
Play hard learn harder: The Serious Business of PlayPooky Knightsmith
 
Towards a code of practice for AI in AT.pptx
Towards a code of practice for AI in AT.pptxTowards a code of practice for AI in AT.pptx
Towards a code of practice for AI in AT.pptxJisc
 
Wellbeing inclusion and digital dystopias.pptx
Wellbeing inclusion and digital dystopias.pptxWellbeing inclusion and digital dystopias.pptx
Wellbeing inclusion and digital dystopias.pptxJisc
 
PANDITA RAMABAI- Indian political thought GENDER.pptx
PANDITA RAMABAI- Indian political thought GENDER.pptxPANDITA RAMABAI- Indian political thought GENDER.pptx
PANDITA RAMABAI- Indian political thought GENDER.pptxakanksha16arora
 
Unit 3 Emotional Intelligence and Spiritual Intelligence.pdf
Unit 3 Emotional Intelligence and Spiritual Intelligence.pdfUnit 3 Emotional Intelligence and Spiritual Intelligence.pdf
Unit 3 Emotional Intelligence and Spiritual Intelligence.pdfDr Vijay Vishwakarma
 
How to Manage Call for Tendor in Odoo 17
How to Manage Call for Tendor in Odoo 17How to Manage Call for Tendor in Odoo 17
How to Manage Call for Tendor in Odoo 17Celine George
 
NO1 Top Black Magic Specialist In Lahore Black magic In Pakistan Kala Ilam Ex...
NO1 Top Black Magic Specialist In Lahore Black magic In Pakistan Kala Ilam Ex...NO1 Top Black Magic Specialist In Lahore Black magic In Pakistan Kala Ilam Ex...
NO1 Top Black Magic Specialist In Lahore Black magic In Pakistan Kala Ilam Ex...Amil baba
 

Recently uploaded (20)

Python Notes for mca i year students osmania university.docx
Python Notes for mca i year students osmania university.docxPython Notes for mca i year students osmania university.docx
Python Notes for mca i year students osmania university.docx
 
Sensory_Experience_and_Emotional_Resonance_in_Gabriel_Okaras_The_Piano_and_Th...
Sensory_Experience_and_Emotional_Resonance_in_Gabriel_Okaras_The_Piano_and_Th...Sensory_Experience_and_Emotional_Resonance_in_Gabriel_Okaras_The_Piano_and_Th...
Sensory_Experience_and_Emotional_Resonance_in_Gabriel_Okaras_The_Piano_and_Th...
 
VAMOS CUIDAR DO NOSSO PLANETA! .
VAMOS CUIDAR DO NOSSO PLANETA!                    .VAMOS CUIDAR DO NOSSO PLANETA!                    .
VAMOS CUIDAR DO NOSSO PLANETA! .
 
QUATER-1-PE-HEALTH-LC2- this is just a sample of unpacked lesson
QUATER-1-PE-HEALTH-LC2- this is just a sample of unpacked lessonQUATER-1-PE-HEALTH-LC2- this is just a sample of unpacked lesson
QUATER-1-PE-HEALTH-LC2- this is just a sample of unpacked lesson
 
OSCM Unit 2_Operations Processes & Systems
OSCM Unit 2_Operations Processes & SystemsOSCM Unit 2_Operations Processes & Systems
OSCM Unit 2_Operations Processes & Systems
 
How to Add a Tool Tip to a Field in Odoo 17
How to Add a Tool Tip to a Field in Odoo 17How to Add a Tool Tip to a Field in Odoo 17
How to Add a Tool Tip to a Field in Odoo 17
 
UGC NET Paper 1 Unit 7 DATA INTERPRETATION.pdf
UGC NET Paper 1 Unit 7 DATA INTERPRETATION.pdfUGC NET Paper 1 Unit 7 DATA INTERPRETATION.pdf
UGC NET Paper 1 Unit 7 DATA INTERPRETATION.pdf
 
dusjagr & nano talk on open tools for agriculture research and learning
dusjagr & nano talk on open tools for agriculture research and learningdusjagr & nano talk on open tools for agriculture research and learning
dusjagr & nano talk on open tools for agriculture research and learning
 
Simple, Complex, and Compound Sentences Exercises.pdf
Simple, Complex, and Compound Sentences Exercises.pdfSimple, Complex, and Compound Sentences Exercises.pdf
Simple, Complex, and Compound Sentences Exercises.pdf
 
Beyond_Borders_Understanding_Anime_and_Manga_Fandom_A_Comprehensive_Audience_...
Beyond_Borders_Understanding_Anime_and_Manga_Fandom_A_Comprehensive_Audience_...Beyond_Borders_Understanding_Anime_and_Manga_Fandom_A_Comprehensive_Audience_...
Beyond_Borders_Understanding_Anime_and_Manga_Fandom_A_Comprehensive_Audience_...
 
OS-operating systems- ch05 (CPU Scheduling) ...
OS-operating systems- ch05 (CPU Scheduling) ...OS-operating systems- ch05 (CPU Scheduling) ...
OS-operating systems- ch05 (CPU Scheduling) ...
 
Our Environment Class 10 Science Notes pdf
Our Environment Class 10 Science Notes pdfOur Environment Class 10 Science Notes pdf
Our Environment Class 10 Science Notes pdf
 
FSB Advising Checklist - Orientation 2024
FSB Advising Checklist - Orientation 2024FSB Advising Checklist - Orientation 2024
FSB Advising Checklist - Orientation 2024
 
Play hard learn harder: The Serious Business of Play
Play hard learn harder:  The Serious Business of PlayPlay hard learn harder:  The Serious Business of Play
Play hard learn harder: The Serious Business of Play
 
Towards a code of practice for AI in AT.pptx
Towards a code of practice for AI in AT.pptxTowards a code of practice for AI in AT.pptx
Towards a code of practice for AI in AT.pptx
 
Wellbeing inclusion and digital dystopias.pptx
Wellbeing inclusion and digital dystopias.pptxWellbeing inclusion and digital dystopias.pptx
Wellbeing inclusion and digital dystopias.pptx
 
PANDITA RAMABAI- Indian political thought GENDER.pptx
PANDITA RAMABAI- Indian political thought GENDER.pptxPANDITA RAMABAI- Indian political thought GENDER.pptx
PANDITA RAMABAI- Indian political thought GENDER.pptx
 
Unit 3 Emotional Intelligence and Spiritual Intelligence.pdf
Unit 3 Emotional Intelligence and Spiritual Intelligence.pdfUnit 3 Emotional Intelligence and Spiritual Intelligence.pdf
Unit 3 Emotional Intelligence and Spiritual Intelligence.pdf
 
How to Manage Call for Tendor in Odoo 17
How to Manage Call for Tendor in Odoo 17How to Manage Call for Tendor in Odoo 17
How to Manage Call for Tendor in Odoo 17
 
NO1 Top Black Magic Specialist In Lahore Black magic In Pakistan Kala Ilam Ex...
NO1 Top Black Magic Specialist In Lahore Black magic In Pakistan Kala Ilam Ex...NO1 Top Black Magic Specialist In Lahore Black magic In Pakistan Kala Ilam Ex...
NO1 Top Black Magic Specialist In Lahore Black magic In Pakistan Kala Ilam Ex...
 

Notifications for Android L & wear

  • 1.
  • 2.
  • 3.
  • 4.
  • 5.
  • 6.
  • 7. builder.setContentTitle("Private notification") .setContentText("Private notification content") .setVisibility(Notification.VISIBILITY_PRIVATE) .setColor(Color.argb(1, 204, 0, 0)) .setPublicVersion( new Notification.Builder(this) .setColor(Color.argb(1, 0, 153, 204)) .setSmallIcon(R.drawable.ic_action_web_site) .setContentText("Public version of private content") .setContentTitle("Public version") .build());
  • 8.
  • 9.
  • 10.
  • 12. PendingIntent pi = PendingIntent.getActivity(this, 0, new Intent(Intent.ACTION_VIEW).setData(Uri.parse("http://android.com")), 0); builder.setFullScreenIntent(pi, true) .setContentIntent(pi) .setContentTitle("Notification with Fullscreen Intent") .setContentText("Content text");
  • 13.
  • 14.
  • 15.
  • 16. Notification notification = new Notification.Builder(BridgeActivity.this) .setSmallIcon(R.drawable.ic_launcher) .setLargeIcon(BitmapFactory.decodeResource(getResources(), R.drawable.bg_wear_notes)) .setContentTitle("Android.com") .setContentText("Check out news from android.com!") .setLocalOnly(!cbBridgeNotification.isChecked()) .setAutoCancel(true) .build();
  • 17.
  • 18.
  • 19.
  • 20. // Create wear only action PendingIntent piw = PendingIntent.getActivity(this, 0, new Intent(Intent.ACTION_VIEW).setData(Uri.parse("http://android.com/wear")), PendingIntent.FLAG_UPDATE_CURRENT); Notification.Action wearOnlyAction = new Notification.Action.Builder(R.drawable.ic_action_web_site, "Wear only", piw).build(); ! builder.extend(new Notification.WearableExtender().addAction(wearOnlyAction));
  • 21.
  • 22.
  • 23.
  • 24. remoteInput = new RemoteInput.Builder(VoiceInputResultActivity.KEY_VOICE_INPUT) .setLabel("Say message") .setChoices(getResources().getStringArray(R.array.reply_choices)) .build(); ! // 중략 ! Notification.Action replyAction = new Notification.Action.Builder(R.drawable.ic_action_web_site, "Reply", pi) .addRemoteInput(remoteInput).build(); ! Notification.Builder builder = new Notification.Builder(this) .setSmallIcon(R.drawable.ic_action_web_site) .setLargeIcon(BitmapFactory.decodeResource(getResources(), R.drawable.img_gaejugi)) .setAutoCancel(true) .setContentTitle("John Doe") .setContentText("Lunch?") .extend(new Notification.WearableExtender().addAction(replyAction));
  • 25.
  • 26. Notification.Builder builder = new Notification.Builder(this); builder.setSmallIcon(R.drawable.ic_action_web_site) //… 생략 ! Notification secondPage = new Notification.Builder(this) // 생략 ! Notification thirdPage = new Notification.Builder(this) // 생략 ! Notification pagingNotification = new Notification.WearableExtender() .addPage(secondPage) .addPage(thirdPage) .extend(builder).build();
  • 27.
  • 28.
  • 29. Notification noti1 = new Notification.Builder(this).setGroup(GROUP_MESSAGE) // 생략 ! Notification noti2 = new Notification.Builder(this).setGroup(GROUP_MESSAGE) // 생략 ! NotificationManager mng = (NotificationManager) getSystemService(NOTIFICATION_SERVICE); mng.notify(0, noti1); mng.notify(1, noti2); ! Notification summary = new Notification.Builder(this) // 생략 .setGroup(GROUP_MESSAGE) .setGroupSummary(true) .extend(new Notification.WearableExtender() .setBackground(BitmapFactory.decodeResource( getResources(), R.drawable.img_gaejugi))) .build(); ! mng.notify(3, summary);