summaryrefslogtreecommitdiff
path: root/navit/graphics
diff options
context:
space:
mode:
authorPierre Grandin <grandinp@gmail.com>2017-12-20 12:35:41 -0800
committerPierre Grandin <grandinp@gmail.com>2017-12-20 12:35:41 -0800
commitb682873275460e63bed3ff15c92d890fd8265e40 (patch)
treebaeaef1c26e3c23a1dc1ad755bd74b2dd95c4338 /navit/graphics
parent030eb7b38f3d8531c2d6052cd8d67995e23de4d1 (diff)
downloadnavit-b682873275460e63bed3ff15c92d890fd8265e40.tar.gz
Fix:add missing watchEvent slot implementation
Diffstat (limited to 'navit/graphics')
-rw-r--r--navit/graphics/qt5/event_qt5.cpp11
1 files changed, 11 insertions, 0 deletions
diff --git a/navit/graphics/qt5/event_qt5.cpp b/navit/graphics/qt5/event_qt5.cpp
index 5eae821f6..08fb6e525 100644
--- a/navit/graphics/qt5/event_qt5.cpp
+++ b/navit/graphics/qt5/event_qt5.cpp
@@ -43,6 +43,7 @@ extern "C" {
#if defined(WINDOWS) || defined(WIN32) || defined(HAVE_API_WIN32_CE)
#include <windows.h>
#endif
+
#include "event_qt5.h"
#include "event_qt5.moc"
#include "graphics_qt5.h"
@@ -65,6 +66,16 @@ qt5_navit_timer::qt5_navit_timer(QObject* parent)
dbg(lvl_debug, "qt5_navit_timer object created\n");
}
+void qt5_navit_timer::watchEvent(int id)
+{
+ struct event_watch* ret = g_new0(struct event_watch, 1);
+ ret = (struct event_watch*)g_hash_table_lookup(watches, (void*)(long)id);
+ if (ret) {
+ dbg(lvl_debug, "callback found, calling it\n");
+ callback_call_0(ret->cb);
+ }
+}
+
void qt5_navit_timer::timerEvent(QTimerEvent* event)
{
int id = event->timerId();