elusive map zoom controls


Last Updated:

  1. drake

    drake Member This Topic's Starter

    Joined:
    Dec 7, 2009
    Messages:
    10
    Likes Received:
    0
    I don't think this has been asked on this forum yet, but if it has, I apologize, but has anyone else had trouble with bringing up the zoom controls?

    I have tried the walkthrough for them on the mapview tutorial on Android.com and things like

    mMyMapView.setBuiltInZoomControls(true);
    mMapView.getZoomControls().setEnabled(true);

    (yes, i know getZoomControls() is depreciated)

    I know through a little if statement that the controls are not visible.

    does anyone have any ideas? i mean, i see in the depreciation message in eclipse that in a map view they should be visible by default, but they're clearly not. this isn't a huge deal, but its aggravating that something that should just work isn't....
     

    Advertisement
  2. JoshKraker

    JoshKraker Member

    Joined:
    Dec 3, 2009
    Messages:
    21
    Likes Received:
    0
    mMyMapView.setBuiltInZoomControls(true); is what you need codeside, but check you xml for the following properties as well

    android:enabled="true"
    android:clickable="true"
     
  3. drake

    drake Member This Topic's Starter

    Joined:
    Dec 7, 2009
    Messages:
    10
    Likes Received:
    0
    i have both of those lines in my layout xml file. even using the Maps demo code i do not get the zoom controls.

    any idea why the sample code would not do this?
     

Share This Page

Loading...