Jos*_*rty 3 android android-layout
我使用Umano代码创建了一个滑动布局:https: //github.com/umano/AndroidSlidingUpPanel
它工作得很好,但我有一个问题.我的面板应该是部分透明的,因此原始视图在启动时仍然可见.
视图背景设置为#64000000,但它仍然完全不透明,后面没有任何东西可以看到.
这是代码:
<com.sothree.slidinguppanel.SlidingUpPanelLayout
android:id="@+id/sliding_up_panel"
android:layout_height="match_parent"
android:layout_width="match_parent">
<ImageView
android:layout_height="match_parent"
android:layout_width="match_parent"
android:scaleType="fitCenter"
android:id="@+id/images_gallery_image" />
<RelativeLayout
android:layout_width="fill_parent"
android:layout_height="match_parent"
android:background="#64000000">
<!-- MY STUFF (transparent stuff) -->
</RelativeLayout>
</com.sothree.slidinguppanel.SlidingUpPanelLayout>
Run Code Online (Sandbox Code Playgroud)
我想也许问题可能是由于隐藏了扩展面板下面的UI元素,所以我试图在库代码中玩,但它似乎没有关系.
在调试时,我注意到库中第355行的hasOpaqueBackground(View v)确实返回false,正如预期的那样 - 但视图仍然是不透明的.
| 归档时间: |
|
| 查看次数: |
2933 次 |
| 最近记录: |