Modified to skip outdated touch events
[platform/core/uifw/libscl-ui.git] / scl / gwes / efl / sclwindows-efl.cpp
index 9fd8b93..b8a8c8c 100644 (file)
@@ -64,6 +64,11 @@ extern std::vector<TextCache> g_TextCache;
 #else
 #endif
 
+/* When the base window is resized, any mouse events generated before this timestamp value
+ * that are waiting in the event queue, could be considered as outdated so we are going to
+ * skip those events */
+unsigned int g_timestamp_last_base_window_resized = 0;
+
 /**
  * Constructor
  */
@@ -810,6 +815,8 @@ CSCLWindowsImplEfl::resize_window(const sclwindow window, scl16 width, scl16 hei
     if (windows && window) {
         if (window != windows->get_base_window()) {
             evas_object_resize(win, width, height);
+        } else {
+            g_timestamp_last_base_window_resized = (unsigned int)(ecore_loop_time_get() * 1000.0f);
         }
 
         if (window == windows->get_dim_window()) {