【问题标题】:Hide/show Actionbar when tap on MapView in Android在 Android 中点击 MapView 时隐藏/显示操作栏
【发布时间】:2012-02-24 11:48:54
【问题描述】:

我想在平板电脑上的 Gallery App 中实现 Android 操作栏的功能。点击地图 - 隐藏操作栏,点击地图第二次 - 显示操作栏。但我仍然想用两根手指和双击缩放地图。请帮我解决这个问题,我在这个问题上花了很多时间。

【问题讨论】:

  • 只需抓住 onclick 检查点击并隐藏或显示,然后将 onClick 传递给超级
  • 你能举一些代码例子吗?

标签: android android-mapview android-actionbar tap


【解决方案1】:

您可以按照此处给出的示例代码来检测点击:https://stackoverflow.com/a/4833271/396381 并根据其可见状态调用 actionbar.show() 或 .hide()。

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 2013-02-25
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2014-03-18
    • 2014-10-14
    • 1970-01-01
    相关资源
    最近更新 更多