Do not show "My position" header in yopme.

This commit is contained in:
Dmitry Kunin 2013-09-23 10:29:20 +03:00 committed by Alex Zolotarev
parent 17baa366bc
commit 49be282781
2 changed files with 7 additions and 1 deletions

View file

@ -16,6 +16,7 @@ import android.os.Bundle;
import android.os.Environment;
import android.os.Handler;
import android.preference.PreferenceManager;
import android.text.TextUtils;
import android.util.Log;
import android.view.View;
import android.widget.ImageView;
@ -417,9 +418,13 @@ public class BackscreenActivity extends BSActivity implements LocationListener
hideWaitMessage();
if (mMode == Mode.POI)
{
mPoiText.setText(mPoint.getName());
mPoiInfo.setVisibility(TextUtils.isEmpty(mPoint.getName()) ? View.GONE : View.VISIBLE);
}
}
private void calculateDistance()
{
if (mLocation != null && mPoint != null)

View file

@ -373,7 +373,8 @@ public class MapObjectFragment extends Fragment
else if (itemId == MENU_P2B)
{
final boolean addLastKnown = MWMApplication.get().getLocationState().hasPosition();
Yota.showPoi(getActivity(), mLat, mLon, Framework.getDrawScale(), mName, addLastKnown);
Yota.showPoi(getActivity(), mLat, mLon, Framework.getDrawScale(),
mType == MapObjectType.MY_POSITION ? "" : mName, addLastKnown);
}
return super.onOptionsItemSelected(item);