在制作按钮时,奇怪的工件看起来像API 21中的Spinners

DMI*_*DMI 5 android android-layout android-support-library material-design android-5.0-lollipop

我有一个应用程序,我正在使用Android支持库更新为Material Design样式.在应用程序中,我有一些实际上是Buttons的元素,但样式看起来像Spinners.单击时,它们会弹出日期或时间选择器,并在选择完成后更新文本.

创建这些元素的布局XML片段是:

<LinearLayout
    android:layout_width="match_parent"
    android:layout_height="wrap_content"
    android:orientation="horizontal">

    <Button
        android:id="@+id/start_date"
        style="?android:attr/spinnerStyle"
        android:layout_width="0dp"
        android:layout_weight="3"
        android:hint="@string/hint_start_date"
        android:layout_height="wrap_content"/>

    <Button
        android:id="@+id/start_time"
        style="?android:attr/spinnerStyle"
        android:layout_width="0dp"
        android:layout_weight="1"
        android:layout_height="wrap_content"/>

</LinearLayout>

<LinearLayout
    android:layout_width="match_parent"
    android:layout_height="wrap_content"
    android:orientation="horizontal">

    <Button
        android:id="@+id/end_date"
        style="?android:attr/spinnerStyle"
        android:hint="@string/hint_end_date"
        android:layout_width="0dp"
        android:layout_weight="3"
        android:layout_height="wrap_content"/>

    <Button
        android:id="@+id/end_time"
        style="?android:attr/spinnerStyle"
        android:layout_width="0dp"
        android:layout_weight="1"
        android:layout_height="wrap_content"/>

</LinearLayout>
Run Code Online (Sandbox Code Playgroud)

这与以前的版本相比没有变化,它可以正常工作.从棒棒糖开始,不是像我期望的那样渲染,而是出现一个奇怪的灰色边框(例如在Nexus 6上):

我在设备上看到的内容

当按压并保持元件时,内部形状的底部收缩,因此灰色三角形变宽.

我已经尝试重写该样式以使用我自己的(略微修改过的)原始AppCompat Library drawables的副本作为背景.我试图强制背景@null,并且工件仍在那里.Android Studio中呈现的预览在元素的左侧显示灰色边框,我也无法删除:

Android Studio中的怪异

我真的不知道这是从哪里来的.有什么建议?或者也许想要使用不同的UI模式?

  • 测试设备:Nexus 6,Android 5.0
  • Android studio版本:1.0.2
  • 构建工具版本:21.1.2
  • AppCompat-v7库版本:21.0.3
  • 编译SDK版本:21
  • 最低SDK版本:15
  • 目标SDK版本:21