是否可以通过绑定设置可见性?(尺寸.xml)
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:visibility="@whatever/visibility_of_this_view"
android:orientation="horizontal">...
这样我就可以在 dimens.xml 中放入一些内容,例如:
<whatever name="visibility_of_this_view">visible</whatever>
我不想通过代码或不同的布局来做到这一点,只是使用不同的dimens.xml。