Merge "Change remote copy intent behavior." into tm-dev am: 4d6f731761
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/18557688 Change-Id: I6d156ce59c0629f6034b3a49ccc7d7f5a2c38baf Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
This commit is contained in:
@@ -635,12 +635,13 @@ public class ClipboardOverlayController {
|
|||||||
}
|
}
|
||||||
|
|
||||||
private Intent getRemoteCopyIntent(ClipData clipData) {
|
private Intent getRemoteCopyIntent(ClipData clipData) {
|
||||||
String remoteCopyPackage = mContext.getString(R.string.config_remoteCopyPackage);
|
|
||||||
if (TextUtils.isEmpty(remoteCopyPackage)) {
|
|
||||||
return null;
|
|
||||||
}
|
|
||||||
Intent nearbyIntent = new Intent(REMOTE_COPY_ACTION);
|
Intent nearbyIntent = new Intent(REMOTE_COPY_ACTION);
|
||||||
nearbyIntent.setComponent(ComponentName.unflattenFromString(remoteCopyPackage));
|
|
||||||
|
String remoteCopyPackage = mContext.getString(R.string.config_remoteCopyPackage);
|
||||||
|
if (!TextUtils.isEmpty(remoteCopyPackage)) {
|
||||||
|
nearbyIntent.setComponent(ComponentName.unflattenFromString(remoteCopyPackage));
|
||||||
|
}
|
||||||
|
|
||||||
nearbyIntent.setClipData(clipData);
|
nearbyIntent.setClipData(clipData);
|
||||||
nearbyIntent.addFlags(Intent.FLAG_GRANT_READ_URI_PERMISSION);
|
nearbyIntent.addFlags(Intent.FLAG_GRANT_READ_URI_PERMISSION);
|
||||||
nearbyIntent.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK | Intent.FLAG_ACTIVITY_CLEAR_TASK);
|
nearbyIntent.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK | Intent.FLAG_ACTIVITY_CLEAR_TASK);
|
||||||
|
|||||||
Reference in New Issue
Block a user