Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(297)

Side by Side Diff: android_webview/glue/java/src/com/android/webview/chromium/WebViewChromiumFactoryProvider.java

Issue 2392293002: Disable thread checking for LGE email app (Closed)
Patch Set: Created 4 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 package com.android.webview.chromium; 5 package com.android.webview.chromium;
6 6
7 import android.Manifest; 7 import android.Manifest;
8 import android.app.ActivityManager; 8 import android.app.ActivityManager;
9 import android.content.ComponentCallbacks2; 9 import android.content.ComponentCallbacks2;
10 import android.content.Context; 10 import android.content.Context;
(...skipping 504 matching lines...) Expand 10 before | Expand all | Expand 10 after
515 } 515 }
516 } 516 }
517 return mStaticMethods; 517 return mStaticMethods;
518 } 518 }
519 519
520 @Override 520 @Override
521 public WebViewProvider createWebView(WebView webView, WebView.PrivateAccess privateAccess) { 521 public WebViewProvider createWebView(WebView webView, WebView.PrivateAccess privateAccess) {
522 return new WebViewChromium(this, webView, privateAccess, mShouldDisableT hreadChecking); 522 return new WebViewChromium(this, webView, privateAccess, mShouldDisableT hreadChecking);
523 } 523 }
524 524
525 // Check this as a workaround for https://crbug.com/622151. 525 // Check this as a workaround for crbug.com/622151, crbug.com/651706
526 private boolean shouldDisableThreadChecking(Context context) { 526 private boolean shouldDisableThreadChecking(Context context) {
527 final String lgeMailPackageId = "com.lge.email";
528 if (lgeMailPackageId.equals(context.getPackageName())) {
529 // TODO(changwan): need to do version check once LGE notifies us.
aelias_OOO_until_Jul13 2016/10/05 23:01:53 Can you fill in the code with placeholder version
Changwan Ryu 2016/10/06 05:31:41 Done.
530 return true;
531 }
527 if (Build.VERSION.SDK_INT > Build.VERSION_CODES.M) return false; 532 if (Build.VERSION.SDK_INT > Build.VERSION_CODES.M) return false;
528 final String htcMailPackageId = "com.htc.android.mail"; 533 final String htcMailPackageId = "com.htc.android.mail";
529 if (!htcMailPackageId.equals(context.getPackageName())) return false; 534 if (!htcMailPackageId.equals(context.getPackageName())) return false;
530 try { 535 try {
531 PackageInfo packageInfo = 536 PackageInfo packageInfo =
532 context.getPackageManager().getPackageInfo(htcMailPackageId, 0); 537 context.getPackageManager().getPackageInfo(htcMailPackageId, 0);
533 if (packageInfo == null) return false; 538 if (packageInfo == null) return false;
534 539
535 // These values are provided by HTC. 540 // These values are provided by HTC.
536 if (Build.VERSION.SDK_INT < Build.VERSION_CODES.M 541 if (Build.VERSION.SDK_INT < Build.VERSION_CODES.M
(...skipping 117 matching lines...) Expand 10 before | Expand all | Expand 10 after
654 mWebViewDatabase = new WebViewDatabaseAdapter(this, awDatabase); 659 mWebViewDatabase = new WebViewDatabaseAdapter(this, awDatabase);
655 } 660 }
656 } 661 }
657 return mWebViewDatabase; 662 return mWebViewDatabase;
658 } 663 }
659 664
660 WebViewDelegate getWebViewDelegate() { 665 WebViewDelegate getWebViewDelegate() {
661 return mWebViewDelegate; 666 return mWebViewDelegate;
662 } 667 }
663 } 668 }
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698