- notification.contentIntent = PendingIntent.getActivity(getContext().getApplicationContext(), (int)System.currentTimeMillis(), explanationIntent, 0);
- notification.setLatestEventInfo(getContext().getApplicationContext(),
- getContext().getString(R.string.sync_foreign_files_forgotten_ticker),
- String.format(getContext().getString(R.string.sync_foreign_files_forgotten_content), mForgottenLocalFiles.size(), getContext().getString(R.string.app_name)),
- notification.contentIntent);
- ((NotificationManager) getContext().getSystemService(Context.NOTIFICATION_SERVICE)).notify(R.string.sync_foreign_files_forgotten_ticker, notification);
+ notificationBuilder
+ .setContentIntent(PendingIntent.getActivity(
+ getContext(), (int) System.currentTimeMillis(), explanationIntent, 0
+ ))
+ .setContentTitle(i18n(R.string.sync_foreign_files_forgotten_ticker))
+ .setContentText(i18n(R.string.sync_foreign_files_forgotten_content, mForgottenLocalFiles.size(), i18n(R.string.app_name)));