- iOS/Objective-C 元类和类别
- objective-c - -1001 错误,当 NSURLSession 通过 httpproxy 和/etc/hosts
- java - 使用网络类获取 url 地址
- ios - 推送通知中不播放声音
我正在使用 umano AndroidSlidingUpPanel在我的安卓项目中。在这里我使用谷歌地图作为我的主要内容。以下是相关的 XML 文件。
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
tools:context=".DemoActivity" >
<com.mypkg.name.SlidingUpPanelLayout
xmlns:sothree="http://schemas.android.com/apk/res-auto"
android:id="@+id/sliding_layout"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_gravity="bottom"
sothree:collapsedHeight="78dp"
sothree:dragView="@+id/linLayout"
sothree:shadowHeight="4dp" >
<FrameLayout
android:id="@+id/activity_single_fragment_content"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="#0000FF" >
<fragment
android:id="@+id/map_fragment"
android:name="com.google.android.gms.maps.SupportMapFragment"
android:layout_width="match_parent"
android:layout_height="match_parent" />
</FrameLayout>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="#eee"
android:clickable="true"
android:focusable="false"
android:orientation="vertical" >
<RelativeLayout
android:id="@+id/drawerListItemProfile_relativeLayout"
android:layout_width="match_parent"
android:layout_height="80dp"
android:background="@drawable/drawer_profile_selector" >
<FrameLayout
android:id="@+id/imgFrameLayout"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentLeft="true"
android:layout_centerVertical="true"
android:layout_margin="5dp" >
<ImageView
android:id="@+id/drawerListItemProfile_imageView"
android:layout_width="@dimen/nav_profile_circle_size"
android:layout_height="@dimen/nav_profile_circle_size"
android:contentDescription="@string/contentDescription_drawer_profile_pic"
android:scaleType="centerCrop"
android:src="@drawable/profilepic" />
</FrameLayout>
</RelativeLayout>
<ImageView
android:layout_width="match_parent"
android:layout_height="0dp"
android:layout_weight="1"
android:scaleType="fitStart"
android:src="@null" >
</ImageView>
</LinearLayout>
</com.mypkg.name.SlidingUpPanelLayout>
</RelativeLayout>
但是当 Activity 开始时,我将面板的默认高度设置为 0。
slidingUpPanelLayout.setPanelHeight(0);
当点击 map 上的标记时,我将面板设置为默认高度。
slidingUpPanelLayout.setPanelHeight(defaultPanelHeight);
再次,当我单击 map (而不是标记)时,面板高度设置为 0。当我这样做时, map 正在重新调整大小。我怎么能阻止它。我希望此功能在 Android 移动设备中像在 Google map 中一样工作。
最佳答案
Bazinga ;) 我做到了。
只需在 ( https://github.com/umano/AndroidSlidingUpPanel/blob/master/library/src/com/sothree/slidinguppanel/SlidingUpPanelLayout.java) 中注释 495 行即可;
height -= panelHeight;
然后你就可以开始了。但是当你使用谷歌地图放大缩小按钮时,你可能会遇到缺点。也就是说,向上滑动的抽屉将覆盖这些按钮。但在真正的 Google map 中,它不会发生。
关于android - 当面板设置为默认面板高度时如何停止 umano AndroidSlidingUpPanel 的主要内容重新调整大小,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/21905562/
我正在探索 https://github.com/umano/AndroidSlidingUpPanel图书馆。当我滑动底部面板时,在幻灯片完成时它会获取完整的屏幕区域。 任何人都可以帮助我,如何将底
已解决: 显然源已更新以添加此功能。在那之前,我 fork 了源代码来做到这一点,并有一个标志来关闭方向变化。我的 fork 位于 github.com/Style87/AndroidSlidingU
我的应用有一个 map fragment 。在单击标记时,从底部到屏幕的一半会显示一个向上滑动的动画。然后再次点击标记向下滑动。 I want : Slide up menu should be cl
我正在使用 umano AndroidSlidingUpPanel在我的安卓项目中。在这里我使用谷歌地图作为我的主要内容。以下是相关的 XML 文件。
所以我开始使用 Umano 的 AndroidSlidingUpPanel 库,它非常有用。我设法从底部实现了一个滑动面板,效果很好。但是我想实现两个滑动面板(顶部和底部),如下所示: 这是我目前所拥
这个问题在这里已经有了答案: ListView inside ScrollView is not scrolling on Android (28 个答案) 关闭上个月。 我小时候有一个带有 Lis
我有一个关于 Umano AndroidSlidingUpPanel 的问题,我似乎没有找到解决方案。我想要两个 View ,一个在另一个之上,可以选择上下滚动,就像在 https://github.
我已经在我的应用程序中实现了 AndroidSlidingUpPanel 库,一切正常,但我希望滑动布局滑动直到它进入我的应用程序栏下方。 谢谢 Link to the Library 最佳答案 你可
我正在尝试使用 AndroidSlidingUpPanel library (在 Eclipse 中)我有这个错误: 04-19 20:09:48.413: E/AndroidRuntime(1376
我使用 Gradle 在 IntelliJ IDEA 上创建了一个项目,并尝试将 AndroidSlidingUpPanel 添加到其中( https://github.com/umano/Andro
我已经做了好几个小时了,但我仍然无法让 Umano 的向上滑动面板库在 android studio 中工作(https://github.com/umano/AndroidSlidingUpPane
我是一名优秀的程序员,十分优秀!