Copy/Paste on RemoteInputView

Also fixes a bug where the remote input view stays focused
when the inline settings open.

Also prevents sharing from contexts that are not activities,
and prevents text processing when the device is not provisioned.

Bug: 27633360
Change-Id: I8b6e7f661bd873d88e7e2460d043c2aa5f849516
diff --git a/packages/SystemUI/src/com/android/systemui/statusbar/ExpandableNotificationRow.java b/packages/SystemUI/src/com/android/systemui/statusbar/ExpandableNotificationRow.java
index 93cb952..de292d6 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/ExpandableNotificationRow.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/ExpandableNotificationRow.java
@@ -579,6 +579,11 @@
         }
     }
 
+    public void closeRemoteInput() {
+        mPrivateLayout.closeRemoteInput();
+        mPublicLayout.closeRemoteInput();
+    }
+
     public interface ExpansionLogger {
         public void logNotificationExpansion(String key, boolean userAction, boolean expanded);
     }