Merge "VectorImageRenderer: Remove TizenVectorImageRenderer dependency" into devel...
[platform/core/uifw/dali-adaptor.git] / dali / internal / window-system / tizen-wayland / ecore-wl2 / window-base-ecore-wl2.cpp
index d467bb3..aa0d96a 100644 (file)
@@ -55,10 +55,12 @@ const unsigned int PRIMARY_TOUCH_BUTTON_ID  = 1;
 
 const char* DALI_VCONFKEY_SETAPPL_ACCESSIBILITY_FONT_NAME = "db/setting/accessibility/font_name"; // It will be update at vconf-key.h and replaced.
 
+#ifdef DALI_ELDBUS_AVAILABLE
 // DBUS accessibility
 const char* BUS       = "org.enlightenment.wm-screen-reader";
 const char* INTERFACE = "org.tizen.GestureNavigation";
 const char* PATH      = "/org/tizen/GestureNavigation";
+#endif // DALI_ELDBUS_AVAILABLE
 
 struct KeyCodeMap
 {
@@ -1353,9 +1355,9 @@ void WindowBaseEcoreWl2::OnFontSizeChanged()
   mStyleChangedSignal.Emit(StyleChange::DEFAULT_FONT_SIZE_CHANGE);
 }
 
+#ifdef DALI_ELDBUS_AVAILABLE
 void WindowBaseEcoreWl2::OnEcoreElDBusAccessibilityNotification(void* context, const Eldbus_Message* message)
 {
-#ifdef DALI_ELDBUS_AVAILABLE
   AccessibilityInfo info;
 
   // The string defines the arg-list's respective types.
@@ -1365,8 +1367,8 @@ void WindowBaseEcoreWl2::OnEcoreElDBusAccessibilityNotification(void* context, c
   }
 
   mAccessibilitySignal.Emit(info);
-#endif
 }
+#endif // DALI_ELDBUS_AVAILABLE
 
 void WindowBaseEcoreWl2::OnTransitionEffectEvent(WindowEffectState state, WindowEffectType type)
 {
@@ -2513,7 +2515,7 @@ void WindowBaseEcoreWl2::CreateWindow(PositionSize positionSize)
   ecore_wl2_window_type_set(mEcoreWindow, ECORE_WL2_WINDOW_TYPE_TOPLEVEL);
 }
 
-void WindowBaseEcoreWl2::SetParent(WindowBase* parentWinBase)
+void WindowBaseEcoreWl2::SetParent(WindowBase* parentWinBase, bool belowParent)
 {
   Ecore_Wl2_Window* ecoreParent = NULL;
   if(parentWinBase)
@@ -2521,7 +2523,7 @@ void WindowBaseEcoreWl2::SetParent(WindowBase* parentWinBase)
     WindowBaseEcoreWl2* winBaseEcore2 = static_cast<WindowBaseEcoreWl2*>(parentWinBase);
     ecoreParent                       = winBaseEcore2->mEcoreWindow;
   }
-  ecore_wl2_window_parent_set(mEcoreWindow, ecoreParent);
+  ecore_wl2_window_transient_parent_set(mEcoreWindow, ecoreParent, belowParent);
 }
 
 int WindowBaseEcoreWl2::CreateFrameRenderedSyncFence()
@@ -2720,6 +2722,30 @@ bool WindowBaseEcoreWl2::IsFloatingModeEnabled() const
   return ecore_wl2_window_floating_mode_get(mEcoreWindow);
 }
 
+void WindowBaseEcoreWl2::IncludeInputRegion(const Rect<int>& inputRegion)
+{
+  Eina_Rectangle rect;
+  rect.x = inputRegion.x;
+  rect.y = inputRegion.y;
+  rect.w = inputRegion.width;
+  rect.h = inputRegion.height;
+
+  ecore_wl2_window_input_rect_add(mEcoreWindow, &rect);
+  ecore_wl2_window_commit(mEcoreWindow, EINA_TRUE);
+}
+
+void WindowBaseEcoreWl2::ExcludeInputRegion(const Rect<int>& inputRegion)
+{
+  Eina_Rectangle rect;
+  rect.x = inputRegion.x;
+  rect.y = inputRegion.y;
+  rect.w = inputRegion.width;
+  rect.h = inputRegion.height;
+
+  ecore_wl2_window_input_rect_subtract(mEcoreWindow, &rect);
+  ecore_wl2_window_commit(mEcoreWindow, EINA_TRUE);
+}
+
 } // namespace Adaptor
 
 } // namespace Internal