67

GitHub - zhangke3016/VirtualUETool: Show/edit any view's attributions, a...

 5 years ago
source link: https://github.com/zhangke3016/VirtualUETool
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.

README.md

VirtualUETool platform

UETool's extension. Show/edit any view's attributions, any app.

VirtualUETool

介绍

VirtualUETool 扩展自UETool实现,底层基于VirtualApp的实现。可以作用于任何App在屏幕上显示的 view,比如 Activity/Fragment/Dialog/PopupWindow 等等。

目前 VirtualUETool 基本可实现 UETool 的所有功能,可直接查看已安装APP:

  • 移动屏幕上的任意 view,如果重复选中一个 view,将会选中其父 view
  • 查看/修改常用控件的属性,比如修改 TextView 的文本内容、文本大小、文本颜色等等
  • 如果你的项目里正在使用 Fresco 的 DraweeView 来呈现图片,那么 UETool 将会提供更多的属性比如图片 URI、默认占位图、圆角大小等等
  • 你可以很轻松的定制任何 view 的属性,比如你想查看一些额外的业务参数
  • 有的时候 UETool 为你选中的 view 并不是你想要的,你可以选择打开 ValidView,然后选中你需要的 View
  • 显示两个 view 的相对位置关系
  • 显示网格栅栏,方便查看控件是否对齐

下载体验

效果

VirtualUETool

自定义实现你的 View 的属性

注意:自定义实现View 的属性时,与 UETool 的方式一致

// step 1, implements IAttrs

public class UETFresco implements IAttrs {
  @Override public List<Item> getAttrs(Element element) {

  }
}

// step 2, put in UETool  must in  MyComponentDelegate.beforeApplicationCreate

UETool.putAttrsProviderClass(Class customizeClazz);

UETool.putAttrsProviderClass(String customizeClassName);

需在MyComponentDelegate.beforeApplicationCreate方法内调用,保证在每个App的独立进程中生效

Thanks

UETool

VirtualApp


About Joyk


Aggregate valuable and interesting links.
Joyk means Joy of geeK