本文整理汇总了C++中ref_ptr::GetPreferredZoomLevel方法的典型用法代码示例。如果您正苦于以下问题:C++ ref_ptr::GetPreferredZoomLevel方法的具体用法?C++ ref_ptr::GetPreferredZoomLevel怎么用?C++ ref_ptr::GetPreferredZoomLevel使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类ref_ptr
的用法示例。
在下文中一共展示了ref_ptr::GetPreferredZoomLevel方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: AcceptMessage
//.........这里部分代码省略.........
m_guiRenderer = move(renderer);
else
m_guiRenderer->Merge(make_ref(renderer));
break;
}
case Message::GuiLayerLayout:
{
ASSERT(m_guiRenderer != nullptr, ());
m_guiRenderer->SetLayout(ref_ptr<GuiLayerLayoutMessage>(message)->GetLayoutInfo());
break;
}
case Message::StopRendering:
{
ProcessStopRenderingMessage();
break;
}
case Message::MyPositionShape:
{
ref_ptr<MyPositionShapeMessage> msg = message;
m_myPositionController->SetRenderShape(msg->AcceptShape());
m_selectionShape = msg->AcceptSelection();
}
break;
case Message::ChangeMyPostitionMode:
{
ref_ptr<ChangeMyPositionModeMessage> msg = message;
switch (msg->GetChangeType())
{
case ChangeMyPositionModeMessage::TYPE_NEXT:
m_myPositionController->NextMode(msg->GetPreferredZoomLevel());
break;
case ChangeMyPositionModeMessage::TYPE_STOP_FOLLOW:
m_myPositionController->StopLocationFollow();
break;
case ChangeMyPositionModeMessage::TYPE_INVALIDATE:
m_myPositionController->Invalidate();
break;
case ChangeMyPositionModeMessage::TYPE_CANCEL:
m_myPositionController->TurnOff();
break;
default:
ASSERT(false, ("Unknown change type:", static_cast<int>(msg->GetChangeType())));
break;
}
break;
}
case Message::CompassInfo:
{
ref_ptr<CompassInfoMessage> msg = message;
m_myPositionController->OnCompassUpdate(msg->GetInfo(), m_userEventStream.GetCurrentScreen());
break;
}
case Message::GpsInfo:
{
ref_ptr<GpsInfoMessage> msg = message;
m_myPositionController->OnLocationUpdate(msg->GetInfo(), msg->IsNavigable(),
m_userEventStream.GetCurrentScreen());
location::RouteMatchingInfo const & info = msg->GetRouteInfo();
if (info.HasDistanceFromBegin())