forked from organicmaps/organicmaps
[ios] Determine if it's long tap for place_page::Info.
This commit is contained in:
parent
f200c20e0c
commit
7a5e1b11ec
3 changed files with 4 additions and 0 deletions
|
@ -1891,6 +1891,7 @@ void Framework::OnTapEvent(df::TapInfo const & tapInfo)
|
|||
df::SelectionShape::ESelectedObject const selection = OnTapEventImpl(tapInfo, info);
|
||||
if (selection != df::SelectionShape::OBJECT_EMPTY)
|
||||
{
|
||||
info.m_isLongTap = tapInfo.m_isLong;
|
||||
// Back up last tap event to recover selection in case of Drape reinitialization.
|
||||
m_lastTapEvent.reset(new df::TapInfo(tapInfo));
|
||||
|
||||
|
|
|
@ -16,6 +16,7 @@ bool Info::IsMyPosition() const { return m_isMyPosition; }
|
|||
bool Info::HasApiUrl() const { return !m_apiUrl.empty(); }
|
||||
bool Info::IsEditable() const { return m_isEditable; }
|
||||
bool Info::HasWifi() const { return GetInternet() == osm::Internet::Wlan; }
|
||||
bool Info::IsLongTap() const { return m_isLongTap; }
|
||||
|
||||
string Info::FormatNewBookmarkName() const
|
||||
{
|
||||
|
|
|
@ -24,6 +24,7 @@ public:
|
|||
bool IsFeature() const;
|
||||
bool IsBookmark() const;
|
||||
bool IsMyPosition() const;
|
||||
bool IsLongTap() const;
|
||||
/// @returns true if Back API button should be displayed.
|
||||
bool HasApiUrl() const;
|
||||
/// @returns true if Edit Place button should be displayed.
|
||||
|
@ -64,6 +65,7 @@ public:
|
|||
|
||||
bool m_isMyPosition = false;
|
||||
bool m_isEditable = false;
|
||||
bool m_isLongTap = false;
|
||||
|
||||
// TODO(AlexZ): Temporary solution. It's better to use a wifi icon in UI instead of text.
|
||||
string m_localizedWifiString;
|
||||
|
|
Loading…
Add table
Reference in a new issue