Skip to content

Commit

Permalink
fix whitespace
Browse files Browse the repository at this point in the history
  • Loading branch information
mjaruzel committed Oct 1, 2021
1 parent 4bc2cb9 commit 0d2a82b
Showing 1 changed file with 14 additions and 13 deletions.
27 changes: 14 additions & 13 deletions src/android/com/adobe/phonegap/push/FCMService.java
Original file line number Diff line number Diff line change
Expand Up @@ -384,16 +384,16 @@ private void showNotificationIfPossible (Context context, Bundle extras) {
}

public void createNotification (Context context, Bundle extras) {
Log.d(LOG_TAG, "create notification");
Log.d(LOG_TAG, "create notification");
NotificationManager mNotificationManager = (NotificationManager) getSystemService(Context.NOTIFICATION_SERVICE);
String appName = getAppName(this);
String packageName = context.getPackageName();
Resources resources = context.getResources();
boolean fullScreenIntent = extras.getString(FULL_SCREEN_NOTIFICATION, "").equals("1");
Log.d(LOG_TAG, "fullScreenIntent = " + fullScreenIntent);
boolean fullScreenIntent = extras.getString(FULL_SCREEN_NOTIFICATION, "").equals("1");
Log.d(LOG_TAG, "fullScreenIntent = " + fullScreenIntent);
int notId = parseInt(NOT_ID, extras);
Class<? extends Activity> activityClass = fullScreenIntent ? FullScreenActivity.class : PushHandlerActivity.class;
Intent notificationIntent = new Intent(this, activityClass);
Class<? extends Activity> activityClass = fullScreenIntent ? FullScreenActivity.class : PushHandlerActivity.class;
Intent notificationIntent = new Intent(this, activityClass);
notificationIntent.addFlags(Intent.FLAG_ACTIVITY_SINGLE_TOP | Intent.FLAG_ACTIVITY_CLEAR_TOP);
notificationIntent.putExtra(PUSH_BUNDLE, extras);
notificationIntent.putExtra(NOT_ID, notId);
Expand Down Expand Up @@ -436,7 +436,7 @@ public void createNotification (Context context, Bundle extras) {
}
mBuilder = new NotificationCompat.Builder(context, channelID);
}
Log.d(LOG_TAG, "Using channel ID = " + channelID);
Log.d(LOG_TAG, "Using channel ID = " + channelID);
} else {
mBuilder = new NotificationCompat.Builder(context);
}
Expand All @@ -447,13 +447,14 @@ public void createNotification (Context context, Bundle extras) {
.setContentIntent(contentIntent)
.setDeleteIntent(deleteIntent)
.setAutoCancel(true);
if (fullScreenIntent) {
mBuilder
.setFullScreenIntent(contentIntent, true)
.setPriority(NotificationCompat.PRIORITY_HIGH);
} else {
mBuilder.setContentIntent(contentIntent);
}

if (fullScreenIntent) {
mBuilder
.setFullScreenIntent(contentIntent, true)
.setPriority(NotificationCompat.PRIORITY_HIGH);
} else {
mBuilder.setContentIntent(contentIntent);
}

SharedPreferences prefs = context.getSharedPreferences(
PushPlugin.COM_ADOBE_PHONEGAP_PUSH,
Expand Down

0 comments on commit 0d2a82b

Please sign in to comment.