Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mapsme/omim.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorr.kuznetsov <r.kuznetsov@corp.mail.ru>2015-05-14 09:44:00 +0300
committerr.kuznetsov <r.kuznetsov@corp.mail.ru>2015-11-30 16:07:43 +0300
commit8b4f680455ba89172913b4179f9bff58819cbf40 (patch)
treec71bbc5c8f62cc2bbd84a7a6af0f2f095e9947e9 /drape/overlay_handle.hpp
parentf7d97541aee552acb84f2f4c0aa43ac623c59860 (diff)
Added handling of gui taps
Diffstat (limited to 'drape/overlay_handle.hpp')
-rw-r--r--drape/overlay_handle.hpp12
1 files changed, 11 insertions, 1 deletions
diff --git a/drape/overlay_handle.hpp b/drape/overlay_handle.hpp
index 2ee3bec2f7..2dca2863cc 100644
--- a/drape/overlay_handle.hpp
+++ b/drape/overlay_handle.hpp
@@ -13,9 +13,13 @@
#include "base/buffer_vector.hpp"
+#include "std/function.hpp"
+
namespace dp
{
+using TOverlayHandler = function<void ()>;
+
class OverlayHandle
{
public:
@@ -34,9 +38,15 @@ public:
virtual void Update(ScreenBase const & /*screen*/) {}
virtual m2::RectD GetPixelRect(ScreenBase const & screen) const = 0;
-
virtual void GetPixelShape(ScreenBase const & screen, Rects & rects) const = 0;
+ virtual bool IsTapped(m2::PointD const & pt) const { return false; }
+ virtual void OnTapBegin(){}
+ virtual void OnTap(){}
+ virtual void OnTapEnd(){}
+
+ void FinishTapEvent(bool executeAction);
+
bool IsIntersect(ScreenBase const & screen, ref_ptr<OverlayHandle> const h) const;
virtual bool IndexesRequired() const { return true; }