Read clipboard item mimetype from description
Currently we construct the clipboard model by calling
contentResolver.getType on the main thread, which can cause problems
because that call can hang.
This change switches to reading the mimeType set in the clip description
instead (which should be set correctly per-item).
Bug: 357197236
Flag: com.android.systemui.clipboard_use_description_mimetype
Test: manual with flag on/off, atest ClipboardModelTest
Change-Id: I78550105f9c4f9b3ee1cf69a732b075397cdf4ac
diff --git a/packages/SystemUI/aconfig/systemui.aconfig b/packages/SystemUI/aconfig/systemui.aconfig
index 02e8cd6..47ddae7 100644
--- a/packages/SystemUI/aconfig/systemui.aconfig
+++ b/packages/SystemUI/aconfig/systemui.aconfig
@@ -582,6 +582,16 @@
}
flag {
+ name: "clipboard_use_description_mimetype"
+ namespace: "systemui"
+ description: "Read item mimetype from description rather than checking URI"
+ bug: "357197236"
+ metadata {
+ purpose: PURPOSE_BUGFIX
+ }
+}
+
+flag {
name: "screenshot_action_dismiss_system_windows"
namespace: "systemui"
description: "Dismiss existing system windows when starting action from screenshot UI"