Dumping the excoded view hierarchy instead of the default activity dump

> Encoded hierarchy is smaller is size and has a lot more information about the views

Bug: 79861035
Change-Id: I84316b1b0031282b0579f3aaac22d8d8f00d8bcb
diff --git a/src/com/android/launcher3/BaseActivity.java b/src/com/android/launcher3/BaseActivity.java
index 3e4589d..4219667 100644
--- a/src/com/android/launcher3/BaseActivity.java
+++ b/src/com/android/launcher3/BaseActivity.java
@@ -30,8 +30,10 @@
 
 import com.android.launcher3.DeviceProfile.OnDeviceProfileChangeListener;
 import com.android.launcher3.logging.UserEventDispatcher;
+import com.android.launcher3.uioverrides.UiFactory;
 import com.android.launcher3.util.SystemUiController;
 
+import java.io.FileDescriptor;
 import java.io.PrintWriter;
 import java.lang.annotation.Retention;
 import java.util.ArrayList;
@@ -224,6 +226,13 @@
         void onMultiWindowModeChanged(boolean isInMultiWindowMode);
     }
 
+    @Override
+    public void dump(String prefix, FileDescriptor fd, PrintWriter writer, String[] args) {
+        if (!UiFactory.dumpActivity(this, writer)) {
+            super.dump(prefix, fd, writer, args);
+        }
+    }
+
     protected void dumpMisc(PrintWriter writer) {
         writer.println(" deviceProfile isTransposed=" + getDeviceProfile().isVerticalBarLayout());
         writer.println(" orientation=" + getResources().getConfiguration().orientation);