[Call UI] Update UCL files (hot-fix). 90/158390/1
authorIgor Nazarov <i.nazarov@samsung.com>
Tue, 31 Oct 2017 12:35:56 +0000 (14:35 +0200)
committerIgor Nazarov <i.nazarov@samsung.com>
Tue, 31 Oct 2017 12:41:15 +0000 (14:41 +0200)
sync-point: [UCL] I2652985ac67c31434608ba8c6804fa3ea3c41313

Change-Id: Iad5d40c78c501a351a3e9750ad5d13f61de01d69

ucl/include/ucl/gui/Atspi.h
ucl/include/ucl/gui/Widget.h
ucl/include/ucl/gui/Widget.hpp
ucl/include/ucl/mvp/ListItemPresenter.h

index adea58d2da2c9107df0eb9649d5d2785c8ee0787..56a0bf85b08a5581c15feca45fad7bbc3821ad1f 100644 (file)
@@ -130,14 +130,14 @@ namespace ucl {
                Elm_Atspi_Role getRole() const;
 
                /**
-                * @brief Sets highlight ability status
-                * @param[in] value New highlight ability status
+                * @brief Sets higlightability status
+                * @param[in] value New higlightability status
                 */
                void setHighlightable(bool value);
 
                /**
-                * @brief Gets highlight ability status
-                * @return Current highlight ability status
+                * @brief Gets higlightability status
+                * @return Current higlightability status
                 */
                bool isHighlightable() const;
 
@@ -236,21 +236,21 @@ namespace ucl {
         */
        template <class T>
        inline auto as_ao(const T &ptr) -> typename std::enable_if<
-                       std::is_convertible<T, bool>::value, decltype(as_ao(*ptr))>::type
+                       std::is_constructible<bool, T>::value, decltype(as_ao(*ptr))>::type
        {
                return (ptr ? as_ao(*ptr) : nullptr);
        }
 
        /**
         * @brief Gets Access object from iterator
-        * @param[in] ptr Target object iterator
+        * @param[in] it Target object iterator
         * @return Pointer to Access object or NULL
         */
        template <class T>
-       inline auto as_ao(const T &iter) -> typename std::enable_if<
-                       !std::is_convertible<T, bool>::value, decltype(as_ao(*iter))>::type
+       inline auto as_ao(const T &it) -> typename std::enable_if<
+                       !std::is_constructible<bool, T>::value, decltype(as_ao(*it))>::type
        {
-               return as_ao(*iter);
+               return as_ao(*it);
        }
 
        /**
index e6506ab9ceb77735c5eb046f4330e8c091f2c91d..df4713e5f1d4170f6c61ba95d2b026af40b22cc0 100644 (file)
@@ -440,11 +440,38 @@ namespace ucl {
         * @return Pointer to Evas object or NULL
         */
        template <class T>
-       inline auto as_eo(const T &ptr) -> decltype(as_eo(*ptr))
+       inline auto as_eo(const T &ptr) -> typename std::enable_if<
+                       std::is_constructible<bool, T>::value, decltype(as_eo(*ptr))>::type
        {
                return (ptr ? as_eo(*ptr) : nullptr);
        }
 
+       /**
+        * @brief Gets Evas object from iterator
+        * @param[in] it Target object iterator
+        * @return Pointer to Evas object or NULL
+        */
+       template <class T>
+       inline auto as_eo(const T &it) -> typename std::enable_if<
+                       !std::is_constructible<bool, T>::value, decltype(as_eo(*it))>::type
+       {
+               return as_eo(*it);
+       }
+
+       /**
+        * @brief Passes through original Evas object pointer
+        * @param[in] eo Evas object pointer
+        * @return Evas object pointer
+        */
+       Evas_Object *as_eo(Evas_Object *eo);
+
+       /**
+        * @brief Passes through original constant Evas object pointer
+        * @param[in] eo Constant Evas object pointer
+        * @return Constant Evas object pointer
+        */
+       const Evas_Object *as_eo(const Evas_Object *eo);
+
        /**
         * @brief Gets position of the widget
         * @param[in] widget Reference to target widget
index 9e98bfdbc15e602da5372de5f915d462d347fc5f..4d2cf29b6346e8091d2a76776f30d6facb06ed82 100644 (file)
@@ -206,6 +206,16 @@ namespace ucl {
                return widget.m_eo;
        }
 
+       inline Evas_Object *as_eo(Evas_Object *const eo)
+       {
+               return eo;
+       }
+
+       inline const Evas_Object *as_eo(const Evas_Object *const eo)
+       {
+               return eo;
+       }
+
        inline void getPosition(const Widget &widget, int *x, int *y)
        {
                widget.getGeometry(x, y, nullptr, nullptr);
index bda4546c06b2fd419525d8d93dba0d62f93abff4..690623e42a42d3fe8df1461509822d24dc8af654 100644 (file)
@@ -287,7 +287,7 @@ namespace ucl {
                                const ItemPickModeParams &params);
 
                /**
-                * @brief Return GUI item insertion parameters
+                * @brief Gets GUI item insertion parameters
                 * @details Called just before item is added to list
                 * @return Item insertion params structure
                 */