MCPcopy Create free account
hub / github.com/comaps/comaps / ActivateMapSelection

Method ActivateMapSelection

libs/map/framework.cpp:1983–2014  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1981}
1982
1983void Framework::ActivateMapSelection()
1984{
1985 if (!m_currentPlacePageInfo)
1986 return;
1987
1988 auto & bm = GetBookmarkManager();
1989
1990 bm.ResetRecentlyDeletedBookmark();
1991
1992 if (m_currentPlacePageInfo->GetSelectedObject() == df::SelectionShape::OBJECT_TRACK)
1993 bm.OnTrackSelected(m_currentPlacePageInfo->GetTrackId());
1994 else
1995 bm.OnTrackDeselected();
1996
1997 auto const & featureId = m_currentPlacePageInfo->GetID();
1998
1999 m_searchMarks.SetSelected(featureId);
2000
2001 auto const selObj = m_currentPlacePageInfo->GetSelectedObject();
2002 CHECK_NOT_EQUAL(selObj, df::SelectionShape::OBJECT_EMPTY, ("Empty selections are impossible."));
2003 if (m_drapeEngine)
2004 {
2005 auto const & bi = m_currentPlacePageInfo->GetBuildInfo();
2006 m_drapeEngine->SelectObject(selObj, m_currentPlacePageInfo->GetMercator(), featureId, bi.m_needAnimationOnSelection,
2007 bi.m_isGeometrySelectionAllowed, true);
2008 }
2009
2010 /// @todo Current android logic is strange (see SetPlacePageListeners comments), so skip assert.
2011 // ASSERT(m_onPlacePageOpen, ());
2012 if (m_onPlacePageOpen)
2013 m_onPlacePageOpen();
2014}
2015
2016void Framework::DeactivateMapSelection()
2017{

Callers

nothing calls this directly

Calls 8

OnTrackSelectedMethod · 0.80
OnTrackDeselectedMethod · 0.80
SetSelectedMethod · 0.80
SelectObjectMethod · 0.80
GetSelectedObjectMethod · 0.45
GetTrackIdMethod · 0.45
GetIDMethod · 0.45

Tested by

no test coverage detected