Java 类com.squareup.leakcanary.internal.RequestStoragePermissionActivity 实例源码

项目:leakcannary    文件:DefaultLeakDirectoryProvider.java   
@Override public void requestWritePermissionNotification() {
  if (hasStoragePermission()) {
    return;
  }
  PendingIntent pendingIntent = RequestStoragePermissionActivity.createPendingIntent(context);
  String contentTitle = context.getString(R.string.leak_canary_permission_notification_title);
  CharSequence packageName = context.getPackageName();
  String contentText =
      context.getString(R.string.leak_canary_permission_notification_text, packageName);
  showNotification(context, contentTitle, contentText, pendingIntent);
}
项目:LeakCanary4Eclipse    文件:DefaultLeakDirectoryProvider.java   
@Override public void requestWritePermissionNotification() {
  if (hasStoragePermission()) {
    return;
  }
  PendingIntent pendingIntent = RequestStoragePermissionActivity.createPendingIntent(context);
  String contentTitle = context.getString(R.string.leak_canary_permission_notification_title);
  CharSequence packageName = context.getPackageName();
  String contentText =
      context.getString(R.string.leak_canary_permission_notification_text, packageName);
  showNotification(context, contentTitle, contentText, pendingIntent);
}
项目:leakcanary    文件:DefaultLeakDirectoryProvider.java   
private void requestWritePermissionNotification() {
  if (permissionNotificationDisplayed) {
    return;
  }
  permissionNotificationDisplayed = true;

  PendingIntent pendingIntent = RequestStoragePermissionActivity.createPendingIntent(context);
  String contentTitle = context.getString(R.string.leak_canary_permission_notification_title);
  CharSequence packageName = context.getPackageName();
  String contentText =
      context.getString(R.string.leak_canary_permission_notification_text, packageName);
  showNotification(context, contentTitle, contentText, pendingIntent, 0xDEAFBEEF);
}