@@ -69,41 +69,48 @@ public static NotificationActionData fromNotificationActionEnum(
6969 switch (selectedAction ) {
7070 case NotificationConstants .PREVIOUS :
7171 return new NotificationActionData (ACTION_PLAY_PREVIOUS ,
72- ctx .getString (R .string .exo_controls_previous_description ), baseActionIcon );
72+ ctx .getString (com .google .android .exoplayer2 .ui .R .string
73+ .exo_controls_previous_description ), baseActionIcon );
7374
7475 case NotificationConstants .NEXT :
7576 return new NotificationActionData (ACTION_PLAY_NEXT ,
76- ctx .getString (R .string .exo_controls_next_description ), baseActionIcon );
77+ ctx .getString (com .google .android .exoplayer2 .ui .R .string
78+ .exo_controls_next_description ), baseActionIcon );
7779
7880 case NotificationConstants .REWIND :
7981 return new NotificationActionData (ACTION_FAST_REWIND ,
80- ctx .getString (R .string .exo_controls_rewind_description ), baseActionIcon );
82+ ctx .getString (com .google .android .exoplayer2 .ui .R .string
83+ .exo_controls_rewind_description ), baseActionIcon );
8184
8285 case NotificationConstants .FORWARD :
8386 return new NotificationActionData (ACTION_FAST_FORWARD ,
84- ctx .getString (R .string . exo_controls_fastforward_description ),
85- baseActionIcon );
87+ ctx .getString (com . google . android . exoplayer2 . ui . R .string
88+ . exo_controls_fastforward_description ), baseActionIcon );
8689
8790 case NotificationConstants .SMART_REWIND_PREVIOUS :
8891 if (player .getPlayQueue () != null && player .getPlayQueue ().size () > 1 ) {
8992 return new NotificationActionData (ACTION_PLAY_PREVIOUS ,
90- ctx .getString (R .string .exo_controls_previous_description ),
91- R .drawable .exo_notification_previous );
93+ ctx .getString (com .google .android .exoplayer2 .ui .R .string
94+ .exo_controls_previous_description ),
95+ com .google .android .exoplayer2 .ui .R .drawable .exo_notification_previous );
9296 } else {
9397 return new NotificationActionData (ACTION_FAST_REWIND ,
94- ctx .getString (R .string .exo_controls_rewind_description ),
95- R .drawable .exo_controls_rewind );
98+ ctx .getString (com .google .android .exoplayer2 .ui .R .string
99+ .exo_controls_rewind_description ),
100+ com .google .android .exoplayer2 .ui .R .drawable .exo_controls_rewind );
96101 }
97102
98103 case NotificationConstants .SMART_FORWARD_NEXT :
99104 if (player .getPlayQueue () != null && player .getPlayQueue ().size () > 1 ) {
100105 return new NotificationActionData (ACTION_PLAY_NEXT ,
101- ctx .getString (R .string .exo_controls_next_description ),
102- R .drawable .exo_notification_next );
106+ ctx .getString (com .google .android .exoplayer2 .ui .R .string
107+ .exo_controls_next_description ),
108+ com .google .android .exoplayer2 .ui .R .drawable .exo_notification_next );
103109 } else {
104110 return new NotificationActionData (ACTION_FAST_FORWARD ,
105- ctx .getString (R .string .exo_controls_fastforward_description ),
106- R .drawable .exo_controls_fastforward );
111+ ctx .getString (com .google .android .exoplayer2 .ui .R .string
112+ .exo_controls_fastforward_description ),
113+ com .google .android .exoplayer2 .ui .R .drawable .exo_controls_fastforward );
107114 }
108115
109116 case NotificationConstants .PLAY_PAUSE_BUFFERING :
@@ -119,45 +126,56 @@ public static NotificationActionData fromNotificationActionEnum(
119126 case NotificationConstants .PLAY_PAUSE :
120127 if (player .getCurrentState () == Player .STATE_COMPLETED ) {
121128 return new NotificationActionData (ACTION_PLAY_PAUSE ,
122- ctx .getString (R .string .exo_controls_pause_description ),
129+ ctx .getString (com .google .android .exoplayer2 .ui .R .string
130+ .exo_controls_pause_description ),
123131 R .drawable .ic_replay );
124132 } else if (player .isPlaying ()
125133 || player .getCurrentState () == Player .STATE_PREFLIGHT
126134 || player .getCurrentState () == Player .STATE_BLOCKED
127135 || player .getCurrentState () == Player .STATE_BUFFERING ) {
128136 return new NotificationActionData (ACTION_PLAY_PAUSE ,
129- ctx .getString (R .string .exo_controls_pause_description ),
130- R .drawable .exo_notification_pause );
137+ ctx .getString (com .google .android .exoplayer2 .ui .R .string
138+ .exo_controls_pause_description ),
139+ com .google .android .exoplayer2 .ui .R .drawable .exo_notification_pause );
131140 } else {
132141 return new NotificationActionData (ACTION_PLAY_PAUSE ,
133- ctx .getString (R .string .exo_controls_play_description ),
134- R .drawable .exo_notification_play );
142+ ctx .getString (com .google .android .exoplayer2 .ui .R .string
143+ .exo_controls_play_description ),
144+ com .google .android .exoplayer2 .ui .R .drawable .exo_notification_play );
135145 }
136146
137147 case NotificationConstants .REPEAT :
138148 if (player .getRepeatMode () == REPEAT_MODE_ALL ) {
139149 return new NotificationActionData (ACTION_REPEAT ,
140- ctx .getString (R .string .exo_controls_repeat_all_description ),
141- R .drawable .exo_media_action_repeat_all );
150+ ctx .getString (com .google .android .exoplayer2 .ui .R .string
151+ .exo_controls_repeat_all_description ),
152+ com .google .android .exoplayer2 .ext .mediasession .R .drawable
153+ .exo_media_action_repeat_all );
142154 } else if (player .getRepeatMode () == REPEAT_MODE_ONE ) {
143155 return new NotificationActionData (ACTION_REPEAT ,
144- ctx .getString (R .string .exo_controls_repeat_one_description ),
145- R .drawable .exo_media_action_repeat_one );
156+ ctx .getString (com .google .android .exoplayer2 .ui .R .string
157+ .exo_controls_repeat_one_description ),
158+ com .google .android .exoplayer2 .ext .mediasession .R .drawable
159+ .exo_media_action_repeat_one );
146160 } else /* player.getRepeatMode() == REPEAT_MODE_OFF */ {
147161 return new NotificationActionData (ACTION_REPEAT ,
148- ctx .getString (R .string .exo_controls_repeat_off_description ),
149- R .drawable .exo_media_action_repeat_off );
162+ ctx .getString (com .google .android .exoplayer2 .ui .R .string
163+ .exo_controls_repeat_off_description ),
164+ com .google .android .exoplayer2 .ext .mediasession .R .drawable
165+ .exo_media_action_repeat_off );
150166 }
151167
152168 case NotificationConstants .SHUFFLE :
153169 if (player .getPlayQueue () != null && player .getPlayQueue ().isShuffled ()) {
154170 return new NotificationActionData (ACTION_SHUFFLE ,
155- ctx .getString (R .string .exo_controls_shuffle_on_description ),
156- R .drawable .exo_controls_shuffle_on );
171+ ctx .getString (com .google .android .exoplayer2 .ui .R .string
172+ .exo_controls_shuffle_on_description ),
173+ com .google .android .exoplayer2 .ui .R .drawable .exo_controls_shuffle_on );
157174 } else {
158175 return new NotificationActionData (ACTION_SHUFFLE ,
159- ctx .getString (R .string .exo_controls_shuffle_off_description ),
160- R .drawable .exo_controls_shuffle_off );
176+ ctx .getString (com .google .android .exoplayer2 .ui .R .string
177+ .exo_controls_shuffle_off_description ),
178+ com .google .android .exoplayer2 .ui .R .drawable .exo_controls_shuffle_off );
161179 }
162180
163181 case NotificationConstants .CLOSE :
0 commit comments