[Tizen] Add KeyEventGeneratedSignal for Get KeyEvent normally
authorJoogab Yun <joogab.yun@samsung.com>
Mon, 8 Jul 2019 07:21:20 +0000 (16:21 +0900)
committerJoogab Yun <joogab.yun@samsung.com>
Mon, 8 Jul 2019 07:21:24 +0000 (16:21 +0900)
This reverts commit 4bfbbd6f98d3f0759d8533b9560e6bc11631cb32.

Change-Id: Iee6c2da990a8cf6956065ac6b8c3e6566ac1bd8f

dali/devel-api/adaptor-framework/window-devel.cpp
dali/devel-api/adaptor-framework/window-devel.h
dali/internal/window-system/common/window-impl.h

index 17a299368d7ec60b10044584dfe77b2a13442c34..dd28579c395c10c5986cf7a85be1d8e47e601797 100644 (file)
@@ -55,6 +55,11 @@ KeyEventSignalType& KeyEventSignal( Window window )
   return GetImplementation( window ).KeyEventSignal();
 }
 
+KeyEventGeneratedSignalType& KeyEventGeneratedSignal( Window window )
+{
+  return GetImplementation( window ).KeyEventGeneratedSignal();
+}
+
 TouchSignalType& TouchSignal( Window window )
 {
   return GetImplementation( window ).TouchSignal();
index 3da549eea7f61dbaa24433791a5a45252f4496da..e61381e1cde3c6a438863242d67be5a5e4af596d 100644 (file)
@@ -35,6 +35,8 @@ typedef Signal< void () > EventProcessingFinishedSignalType;       ///< Event Pr
 
 typedef Signal< void (const KeyEvent&) > KeyEventSignalType;       ///< Key event signal type
 
+typedef Signal< bool (const KeyEvent&) > KeyEventGeneratedSignalType;       ///< Key event generated signal type
+
 typedef Signal< void (const TouchData&) > TouchSignalType;         ///< Touch signal type
 
 typedef Signal< void (const WheelEvent&) > WheelEventSignalType;   ///< Touched signal type
@@ -83,6 +85,18 @@ DALI_ADAPTOR_API EventProcessingFinishedSignalType& EventProcessingFinishedSigna
  */
 DALI_ADAPTOR_API KeyEventSignalType& KeyEventSignal( Window window );
 
+/**
+ * @brief This signal is emitted when key event is received.
+ *
+ * A callback of the following type may be connected:
+ * @code
+ *   bool YourCallbackName(const KeyEvent& event);
+ * @endcode
+ * @param[in] window The window instance
+ * @return The signal to connect to
+ */
+DALI_ADAPTOR_API KeyEventGeneratedSignalType& KeyEventGeneratedSignal( Window window );
+
 /**
  * @brief This signal is emitted when the screen is touched and when the touch ends
  * (i.e. the down & up touch events only).
index 7fd04f96d4da25a4ac05a70d8921ebe1e7b4621e..97fc5758c2e166e27a9a46376f14ba517a0276ff 100644 (file)
@@ -464,6 +464,11 @@ public: // Signals
    */
   Dali::DevelWindow::KeyEventSignalType& KeyEventSignal() { return mScene.KeyEventSignal(); };
 
+    /**
+   * @copydoc Dali::Window::KeyEventGeneratedSignal()
+   */
+  Dali::DevelWindow::KeyEventGeneratedSignalType& KeyEventGeneratedSignal() { return mScene.KeyEventGeneratedSignal(); };
+
   /**
     * @copydoc Dali::Window::TouchSignal()
     */