forked from organicmaps/organicmaps
fix for updating model-view matrix
This commit is contained in:
parent
f08b054e40
commit
3327a811e1
2 changed files with 6 additions and 3 deletions
|
@ -2,15 +2,17 @@
|
|||
|
||||
#include "../std/bind.hpp"
|
||||
|
||||
void OverlayTree::StartOverlayPlacing(ScreenBase const & screen)
|
||||
void OverlayTree::StartOverlayPlacing(ScreenBase const & screen, bool canOverlap)
|
||||
{
|
||||
m_modelView = screen;
|
||||
m_canOverlap = canOverlap;
|
||||
ASSERT(m_tree.empty(), ());
|
||||
}
|
||||
|
||||
void OverlayTree::Add(RefPointer<OverlayHandle> handle)
|
||||
{
|
||||
handle->SetIsVisible(false);
|
||||
handle->SetIsVisible(m_canOverlap);
|
||||
handle->Update(m_modelView);
|
||||
m2::RectD pixelRect = handle->GetPixelRect(m_modelView);
|
||||
|
||||
find_result_t elements;
|
||||
|
|
|
@ -10,7 +10,7 @@
|
|||
class OverlayTree
|
||||
{
|
||||
public:
|
||||
void StartOverlayPlacing(ScreenBase const & screen);
|
||||
void StartOverlayPlacing(ScreenBase const & screen, bool canOverlap = false);
|
||||
void Add(RefPointer<OverlayHandle> handle);
|
||||
void EndOverlayPlacing();
|
||||
|
||||
|
@ -30,6 +30,7 @@ private:
|
|||
ScreenBase m_modelView;
|
||||
typedef KDTree::KDTree<4, Node> tree_t;
|
||||
tree_t m_tree;
|
||||
bool m_canOverlap;
|
||||
|
||||
private:
|
||||
typedef buffer_vector<Node const *, 8> find_result_t;
|
||||
|
|
Loading…
Add table
Reference in a new issue