@nativescript/android 8.2.0-alpha.2 → 8.2.0-alpha.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -512,15 +512,15 @@ def explodeAar(File compileDependency, File outputDir) {
512
512
  Enumeration enumEntries = jar.entries()
513
513
  while (enumEntries.hasMoreElements()) {
514
514
  JarEntry file = (JarEntry) enumEntries.nextElement()
515
+ if (file.isDirectory()) {
516
+ continue
517
+ }
515
518
  if (file.name.endsWith(".jar")) {
516
519
  def targetFile = new File(outputDir, file.name)
517
520
  InputStream inputStream = jar.getInputStream(file)
518
521
  new File(targetFile.parent).mkdirs()
519
522
  Files.copy(inputStream, targetFile.toPath(), StandardCopyOption.REPLACE_EXISTING)
520
523
  }
521
- if (file.isDirectory()) {
522
- continue
523
- }
524
524
  }
525
525
  jar.close()
526
526
  } else if (compileDependency.name.endsWith(".jar")) {
@@ -154,7 +154,13 @@ class ErrorReport implements TabLayout.OnTabSelectedListener {
154
154
  }
155
155
 
156
156
  static void startPendingErrorActivity(Context context, Intent intent) throws CanceledException {
157
- PendingIntent pendingIntent = PendingIntent.getActivity(context, 0, intent, PendingIntent.FLAG_CANCEL_CURRENT);
157
+ int flags = PendingIntent.FLAG_CANCEL_CURRENT;
158
+ if (Build.VERSION.SDK_INT >= 31) {
159
+ int FLAG_MUTABLE = 1<<25;
160
+ flags = PendingIntent.FLAG_CANCEL_CURRENT | FLAG_MUTABLE;
161
+ }
162
+
163
+ PendingIntent pendingIntent = PendingIntent.getActivity(context, 0, intent, flags);
158
164
 
159
165
  pendingIntent.send(context, 0, intent);
160
166
  }
@@ -35,6 +35,7 @@ public class ErrorReportActivity extends AppCompatActivity {
35
35
 
36
36
  // @Override
37
37
  public void onRequestPermissionsResult(int requestCode, @NonNull String[] permissions, @NonNull int[] grantResults) {
38
+ super.onRequestPermissionsResult(requestCode, permissions, grantResults);
38
39
  try {
39
40
  Method onRequestPermissionsResultMethod = AppCompatActivity.class.getMethod("onRequestPermissionsResult", int.class, permissions.getClass(), grantResults.getClass());
40
41
  onRequestPermissionsResultMethod.invoke(new AppCompatActivity() /* never do this */, requestCode, permissions, grantResults);