mirror of
https://github.com/ciphervance/supercell-wx.git
synced 2025-10-30 08:10:05 +00:00
Splitting radar logic out of render layer into manager and view classes
This commit is contained in:
parent
59be110c10
commit
30fadcfbb6
12 changed files with 410 additions and 133 deletions
|
|
@ -87,9 +87,17 @@ void MapWidget::changeStyle()
|
|||
|
||||
void MapWidget::AddLayers()
|
||||
{
|
||||
std::shared_ptr<manager::RadarManager> radarManager =
|
||||
std::make_shared<manager::RadarManager>();
|
||||
std::shared_ptr<view::RadarView> radarView =
|
||||
std::make_shared<view::RadarView>(radarManager, p->map_);
|
||||
|
||||
radarManager->Initialize();
|
||||
radarView->Initialize();
|
||||
|
||||
// QMapboxGL::addCustomLayer will take ownership of the QScopedPointer
|
||||
QScopedPointer<QMapbox::CustomLayerHostInterface> pHost(
|
||||
new RadarLayer(p->map_, p->gl_));
|
||||
new RadarLayer(radarView, p->gl_));
|
||||
|
||||
QString before = "ferry";
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue