Auxiliary message is sent by display server.
When client application added the window's auxiliary hint and if the auxiliary is changed,
display server send the auxiliary message.
Auxiliary message has the key, value and options.
Change-Id: I128cefc8b678fe239a74615f114a8e2611e2fc71
return GetImplementation(window).KeyboardRepeatSettingsChangedSignal();
}
+AuxiliaryMessageSignalType& AuxiliaryMessageSignal(Window window)
+{
+ return GetImplementation(window).AuxiliaryMessageSignal();
+}
+
void SetParent(Window window, Window parent)
{
GetImplementation(window).SetParent(parent);
namespace DevelWindow
{
+
typedef Signal<void()> EventProcessingFinishedSignalType; ///< Event Processing finished signal type
typedef Signal<void(const KeyEvent&)> KeyEventSignalType; ///< Key event signal type
typedef Signal<void()> KeyboardRepeatSettingsChangedSignalType; ///< Keyboard repeat settings changed signal type
+typedef Signal<void(const std::string&, const std::string&, const Property::Array&)> AuxiliaryMessageSignalType; ///< Auxiliary message signal type
+
/**
* @brief Creates an initialized handle to a new Window.
*
DALI_ADAPTOR_API KeyboardRepeatSettingsChangedSignalType& KeyboardRepeatSettingsChangedSignal(Window window);
/**
+ * @brief This signal is emitted when window's auxiliary was changed then display server sent the message.
+ *
+ * Auxiliary message is sent by display server.
+ * When client application added the window's auxiliary hint and if the auxiliary is changed,
+ * display server send the auxiliary message.
+ * Auxiliary message has the key, value and options.
+ *
+ * @param[in] window The window instance
+ * @return The signal to connect to
+ */
+DALI_ADAPTOR_API AuxiliaryMessageSignalType& AuxiliaryMessageSignal(Window window);
+
+/**
* @brief Sets parent window of the window.
*
* After setting that, these windows do together when raise-up, lower and iconified/deiconified.
mAccessibilitySignal(),
mTransitionEffectEventSignal(),
mKeyboardRepeatSettingsChangedSignal(),
- mUpdatePositionSizeSignal()
+ mUpdatePositionSizeSignal(),
+ mAuxiliaryMessageSignal()
{
}
return mUpdatePositionSizeSignal;
}
+WindowBase::AuxiliaryMessageSignalType& WindowBase::AuxiliaryMessageSignal()
+{
+ return mAuxiliaryMessageSignal;
+}
+
} // namespace Adaptor
} // namespace Internal
typedef Signal<void()> KeyboardRepeatSettingsChangedSignalType;
typedef Signal<void()> WindowRedrawRequestSignalType;
typedef Signal<void(Dali::PositionSize&)> UpdatePositionSizeType;
+ typedef Signal<void(const std::string&, const std::string&, const Property::Array&)> AuxiliaryMessageSignalType;
// Input events
typedef Signal<void(Integration::Point&, uint32_t)> TouchEventSignalType;
*/
UpdatePositionSizeType& UpdatePositionSizeSignal();
+ /**
+ * @brief This signal is emitted when the window is received the auxiliary message from display server.
+ */
+ AuxiliaryMessageSignalType& AuxiliaryMessageSignal();
+
protected:
// Undefined
WindowBase(const WindowBase&) = delete;
KeyboardRepeatSettingsChangedSignalType mKeyboardRepeatSettingsChangedSignal;
WindowRedrawRequestSignalType mWindowRedrawRequestSignal;
UpdatePositionSizeType mUpdatePositionSizeSignal;
+ AuxiliaryMessageSignalType mAuxiliaryMessageSignal;
};
} // namespace Adaptor
mResizeSignal(),
mVisibilityChangedSignal(),
mTransitionEffectEventSignal(),
- mKeyboardRepeatSettingsChangedSignal()
+ mKeyboardRepeatSettingsChangedSignal(),
+ mAuxiliaryMessageSignal()
{
}
mWindowBase->KeyboardRepeatSettingsChangedSignal().Connect(this, &Window::OnKeyboardRepeatSettingsChanged);
mWindowBase->WindowRedrawRequestSignal().Connect(this, &Window::OnWindowRedrawRequest);
mWindowBase->UpdatePositionSizeSignal().Connect(this, &Window::OnUpdatePositionSize);
+ mWindowBase->AuxiliaryMessageSignal().Connect(this, &Window::OnAuxiliaryMessage);
mWindowSurface->OutputTransformedSignal().Connect(this, &Window::OnOutputTransformed);
mSurface->SetFullSwapNextFrame();
}
+void Window::OnAuxiliaryMessage(const std::string& key, const std::string& value, const Property::Array& options)
+{
+ mAuxiliaryMessageSignal.Emit(key, value, options);
+}
+
void Window::RecalculateTouchPosition(Integration::Point& point)
{
Vector2 position = point.GetScreenPosition();
typedef Dali::DevelWindow::VisibilityChangedSignalType VisibilityChangedSignalType;
typedef Dali::DevelWindow::TransitionEffectEventSignalType TransitionEffectEventSignalType;
typedef Dali::DevelWindow::KeyboardRepeatSettingsChangedSignalType KeyboardRepeatSettingsChangedSignalType;
+ typedef Dali::DevelWindow::AuxiliaryMessageSignalType AuxiliaryMessageSignalType;
typedef Signal<void()> SignalType;
/**
void OnUpdatePositionSize(Dali::PositionSize& positionSize);
/**
+ * @brief Called when display server sent the auxiliary message.
+ *
+ * @param[in] key the auxiliary message's key.
+ * @param[in] value the auxiliary message's value.
+ * @param[in] options the auxiliary message's options. This is the list of string.
+ */
+ void OnAuxiliaryMessage(const std::string& key, const std::string& value, const Property::Array& options);
+
+ /**
* @brief Set available orientation to window base.
*/
void SetAvailableAnlges(const std::vector<int>& angles);
return mKeyboardRepeatSettingsChangedSignal;
}
+ /**
+ * @copydoc Dali::DevelWindow::AuxiliaryMessageSignal()
+ */
+ AuxiliaryMessageSignalType& AuxiliaryMessageSignal()
+ {
+ return mAuxiliaryMessageSignal;
+ }
+
private:
WindowRenderSurface* mWindowSurface; ///< The window rendering surface
WindowBase* mWindowBase;
VisibilityChangedSignalType mVisibilityChangedSignal;
TransitionEffectEventSignalType mTransitionEffectEventSignal;
KeyboardRepeatSettingsChangedSignalType mKeyboardRepeatSettingsChangedSignal;
+ AuxiliaryMessageSignalType mAuxiliaryMessageSignal;
};
} // namespace Adaptor
}
/////////////////////////////////////////////////////////////////////////////////////////////////
+// Window Auxiliary Message Callbacks
+/////////////////////////////////////////////////////////////////////////////////////////////////
+static Eina_Bool EcoreEventWindowAuxiliaryMessage(void *data, int type, void *event)
+{
+ WindowBaseEcoreWl2* windowBase = static_cast<WindowBaseEcoreWl2*>(data);
+ DALI_LOG_INFO(gWindowBaseLogFilter, Debug::General, "WindowBaseEcoreWl2::EcoreEventWindowAuxiliaryMessage, window[ %d ]\n", windowAuxiliaryMessage->win);
+ if(windowBase)
+ {
+ windowBase->OnEcoreEventWindowAuxiliaryMessage(event);
+ }
+ return ECORE_CALLBACK_RENEW;
+}
+
+/////////////////////////////////////////////////////////////////////////////////////////////////
// ElDBus Accessibility Callbacks
/////////////////////////////////////////////////////////////////////////////////////////////////
// Register Window redraw request event
mEcoreEventHandler.PushBack(ecore_event_handler_add(ECORE_WL2_EVENT_WINDOW_REDRAW_REQUEST, EcoreEventWindowRedrawRequest, this));
+ // Register Window auxiliary event
+ mEcoreEventHandler.PushBack(ecore_event_handler_add(ECORE_WL2_EVENT_AUX_MESSAGE, EcoreEventWindowAuxiliaryMessage, this));
+
// Register Vconf notify - font name and size
vconf_notify_key_changed(DALI_VCONFKEY_SETAPPL_ACCESSIBILITY_FONT_NAME, VconfNotifyFontNameChanged, this);
vconf_notify_key_changed(VCONFKEY_SETAPPL_ACCESSIBILITY_FONT_SIZE, VconfNotifyFontSizeChanged, this);
mWindowRedrawRequestSignal.Emit();
}
+void WindowBaseEcoreWl2::OnEcoreEventWindowAuxiliaryMessage(void* event)
+{
+ Ecore_Wl2_Event_Aux_Message *message = static_cast<Ecore_Wl2_Event_Aux_Message*>(event);
+ if(message)
+ {
+ DALI_LOG_RELEASE_INFO("WindowBaseEcoreWl2::OnEcoreEventWindowAuxiliaryMessage, key:%s, value:%s \n",message->key, message->val);
+ std::string key(message->key);
+ std::string value(message->val);
+ Dali::Property::Array options;
+
+ if(message->options)
+ {
+ Eina_List *l;
+ void* data;
+ EINA_LIST_FOREACH(message->options, l, data)
+ {
+ DALI_LOG_RELEASE_INFO("WindowBaseEcoreWl2::OnEcoreEventWindowAuxiliaryMessage, option: %s\n",(char*)data);
+ std::string option(static_cast<char*>(data));
+ options.Add(option);
+ }
+ }
+
+ mAuxiliaryMessageSignal.Emit(key, value, options);
+ }
+}
+
+
void WindowBaseEcoreWl2::KeymapChanged(void* data, int type, void* event)
{
Ecore_Wl2_Event_Seat_Keymap_Changed* changed = static_cast<Ecore_Wl2_Event_Seat_Keymap_Changed*>(event);
*/
void OnEcoreEventWindowRedrawRequest();
+ /**
+ * @brief Called when window's auxiliary is changed then display server send the changed message.
+ *
+ * @param[in] auxiliary's message data. It has key, value and integer list data.
+ */
+ void OnEcoreEventWindowAuxiliaryMessage(void* event);
+
+
#ifdef DALI_ELDBUS_AVAILABLE
/**
* @brief Called when Ecore ElDBus accessibility event is received.