如果,而且在Activity里通过 findViewById(R.id.xxx)获取不到控件xml:
     <com.tailfun.entity.Key
        android:id="@+id/powerKey"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:layout_x="30px"
        android:layout_y="30px"
        android:visibility="gone" />
activity:Key powerKey=(Key) (findViewById(R.id.powerKey));这里powerKey就是null,我没有写属性配置文件attr.xml,会是这个问题么?