LinearLayout 布局使用选择器需要注意

来源:互联网 发布:javaweb注册登陆源码 编辑:程序博客网 时间:2024/06/16 22:20

相信看到这里已经有很多人遇到了同样的问题了就是使用LinearLayout布局而不能使用选择器的问题其实是可以的ok我下面就说一下怎么使用

其实就是在要使用选择器的LinearLayout布局中加入一个<pre name="code" class="html" style="color: rgb(132, 176, 216); font-size: 11px;">android:clickable="true"
就可以实现选择器的功能了

 <LinearLayout        android:id="@+id/ll"        android:layout_width="match_parent"        android:layout_height="wrap_content"        android:background="@drawable/alert_left_bg"        android:clickable="true"        android:orientation="vertical" >    </LinearLayout>


1 0
原创粉丝点击