Add error types to get Error code using get_last_result() in app. 87/94887/7
authorWoochan Lee <wc0917.lee@samsung.com>
Wed, 2 Nov 2016 02:23:35 +0000 (11:23 +0900)
committerWoochan Lee <wc0917.lee@samsung.com>
Wed, 2 Nov 2016 05:54:58 +0000 (14:54 +0900)
Change-Id: I2f1810ee6abd9545ac7137f1d1a82308c75e6fae

23 files changed:
src/include/efl/UiBaseView.h
src/include/efl/UiBaseViewmgr.h
src/include/efl/mobile/UiMenu.h
src/include/efl/mobile/UiPopup.h
src/include/efl/mobile/UiStandardView.h
src/include/efl/mobile/UiView.h
src/include/efl/mobile/c/ui_application.h
src/include/efl/mobile/c/ui_menu.h
src/include/efl/mobile/c/ui_popup.h
src/include/efl/mobile/c/ui_standard_view.h
src/include/efl/mobile/c/ui_view.h
src/include/efl/mobile/c/ui_viewmgr.h
src/include/interface/UiIfaceOverlay.h
src/include/interface/UiIfaceView.h
src/include/interface/UiIfaceViewmgr.h
src/lib/efl/mobile/UiStandardView.cpp
src/lib/efl/mobile/c/ui_menu.cpp
src/lib/efl/mobile/c/ui_popup.cpp
src/lib/efl/mobile/c/ui_standard_view.cpp
src/lib/efl/mobile/c/ui_view.cpp
src/lib/efl/mobile/c/ui_viewmgr.cpp
src/lib/interface/UiIfaceView.cpp
src/lib/interface/UiIfaceViewmgr.cpp

index 076e4ef..a0c188c 100644 (file)
@@ -33,6 +33,7 @@ class UiBaseView: public ui_viewmanager::UiIfaceView
 public:
        /**
         *  @brief This is a constructor for initializing this view resources.
+        *  @remarks if you don't set a view name, you could not look up the view with it's name. @see ui_viewmgr_get_view_by_name().
         *
         *  @param[in] name view name.
         */
@@ -52,18 +53,21 @@ public:
        virtual int setContent(Eo *content) override;
 
        /**
-        *  @brief This is for unsetting a content of the view.
+        *  @brief Unsets a content of view.
         *
-        *  @return A previous content. If it wasn't, return @c nullptr.
+        *  @return A previous content. If it wasn't, return @c nullptr
+        *
+        *  @see setContent()
+        *  @see getContent()
         */
        virtual Eo *unsetContent() override;
 
        /**
-        *  @brief Get a base object of ui_view.
+        *  @brief Gets a base object of view.
         *
-        *  @note Normally, this base object can be used for a parent of a view content.
+        *  @remarks Normally, this base object can be used for a parent of a view content.
         *
-        *  @return The base object of ui_view.
+        *  @return The base object of view
         */
        virtual Eo *getBase();
 
@@ -98,9 +102,9 @@ public:
        virtual int setAvailableRotations(const int *rotations, unsigned int count) override;
 
        /**
-        *  @brief Get current view's degree.
+        *  @brief Gets the current view's degree.
         *
-        *  @return Current rotation degree, -1 if it fails to get degree information.
+        *  @return Current rotation degree, -1 if it fails to get degree information
         */
        virtual int getDegree() override;
 
index e4e7b41..ebe4bed 100644 (file)
@@ -142,14 +142,24 @@ public:
        /**
         *  @brief Return a last(top) view.
         *
+        *  @remarks The specific error code can be obtained using the get_last_result() method.
+        *           Error codes are described in Exception section.
+        *
         *  @return The view which is last view of the viewmgr view list.
-        *          If there were no views name matched, @c nullptr will be returned.
+        *          If there were no views, @c nullptr will be returned.
+        *  @exception #UI_VIEWMGR_ERROR_NONE Successfully added
+        *  @exception #UI_VIEWMGR_ERROR_NOT_PERMITTED @a viewmgr has no view
+        *
+        *  @see get_last_result()
         */
        UiBaseView *getLastView();
 
        /**
         *  @brief Return a view which is matched with the index @a idx.
         *
+        *  @remarks The specific error code can be obtained using the get_last_result() method.
+        *           Error codes are described in Exception section.
+        *
         *  @param[in] idx A index of the view which you are looking for.
         *
         *  @return The view which index is matched with @a idx.
@@ -158,22 +168,32 @@ public:
         *  @note You could use the index as the page numbers of the views.
         *  @warning the index number of views are variable since the view list is variable.
         *
+        *  @exception #UI_VIEWMGR_ERROR_NONE Successfully added
+        *  @exception #UI_VIEWMGR_ERROR_INVALID_PARAMETER Wrong index
+        *
         *  @see getViewIndex()
         *  @see getViewCount()
+        *  @see get_last_result()
         */
        UiBaseView *getView(unsigned int idx);
 
        /**
         *  @brief Return a view which is matched with the @a name.
         *
+        *  @remarks The specific error code can be obtained using the get_last_result() method.
+        *           Error codes are described in Exception section.
+        *
         *  @note Every view have their names as their own identifiers.
         *
         *  @param[in] name The name of the view which you are looking for.
         *
         *  @return The view which name is matched with @a name.
         *          If there were no views name matched, @c nullptr will be returned.
+        *  @exception #UI_VIEWMGR_ERROR_NONE Successfully added
+        *  @exception #UI_VIEWMGR_ERROR_INVALID_PARAMETER @a name is nullptr, otherwise there is no matched name
         *
         *  @see UiIfaceView::setName()
+        *  @see get_last_result()
         */
        UiBaseView *getView(const char *name);
 
index 5047cf4..692ad39 100644 (file)
@@ -74,16 +74,19 @@ public:
        virtual int setContent(Elm_Ctxpopup* ctxpopup) override;
 
        /**
-        *  @brief This is for unsetting a content of the menu.
+        *  @brief Unsets a content of menu.
         *
-        *  @return A previous content. If it wasn't, return value will be @c nullptr.
+        *  @return A previous content. If it wasn't, return @c nullptr
+        *
+        *  @see setContent()
+        *  @see getContent()
         */
        virtual Elm_Ctxpopup *unsetContent() override;
 
        /**
-        *  @brief Return the active status of menu.
+        *  @brief Returns the active status of menu.
         *
-        *  @return @c true if menu is activated, @c false otherwise.
+        *  @return @c true if menu is activated, @c false otherwise
         *
         *  @see activate()
         *  @see deactivate()
@@ -91,10 +94,10 @@ public:
        virtual bool isActivated() override;
 
        /**
-        *  @brief Get a base object of a UiMenu.
+        *  @brief Gets a base object of menu.
+        *  @details Normally, A base object can be used for a parent of menu content.
         *
-        *  @note Normally, A base object can be used for a parent of UiMenu content.
-        *  @return base object of UiMenu.
+        *  @return base object of menu
         */
        virtual Eo *getBase();
 
index 7d2e62f..3334325 100644 (file)
@@ -86,16 +86,21 @@ public:
        virtual int setContent(Elm_Popup* popup) override;
 
        /**
-        *  @brief This is for unsetting a content of the popup.
+        *  @brief Unsets an popup content.
         *
-        *  @return A previous content. If it wasn't, return value will be @c nullptr.
+        *  @return A previous content. If it wasn't, return @c nullptr
+        *
+        *  @see getContent()
+        *  @see setContent()
         */
        virtual Elm_Popup *unsetContent() override;
 
        /**
-        *  @brief Return the active status of popup.
+        *  @brief Returns the active status of popup.
+        *
+        *  @param[in] popup An popup instance
         *
-        *  @return @c true if overlay is activated, @c false otherwise.
+        *  @return @c true if popup is activated, @c false otherwise
         *
         *  @see activate()
         *  @see deactivate()
@@ -103,11 +108,10 @@ public:
        virtual bool isActivated() override;
 
        /**
-        *  @brief Get a base object of an UiPopup.
-        *
-        * @note Normally, A base object can be used for a parent of UiPopup content.
+        *  @brief Gets a base object of popup.
+        *  @details Normally, A base object can be used for a parent of popup content.
         *
-        *  @return base object of UiPopup.
+        *  @return base object of popup
         */
        virtual Eo *getBase();
 
index 3c7c353..c2e3bb0 100644 (file)
@@ -147,44 +147,83 @@ public:
        Eo *unsetContent() override;
 
        /**
-        *  @brief Unset a title left button of title area.
+        *  @brief Unsets a title left button of title area.
         *
-        *  @return A previous content. If it wasn't, return @c nullptr.
+        *  @remarks The specific error code can be obtained using the get_last_result() method.
+        *           Error codes are described in Exception section.
+        *
+        *  @return A previous content. If it wasn't, return @c nullptr
+        *  @exception #UI_VIEWMGR_ERROR_NONE Successfully added
+        *  @exception #UI_VIEWMGR_ERROR_NOT_PERMITTED @a left button was not set
+        *  @exception #UI_VIEWMGR_ERROR_RESULT_OUT_OF_RANGE Instance is corrupted. Maybe base object is broken.
+        *
+        *  @see getTitleLeftBtn()
+        *  @see setTitleLeftBtn()
+        *  @see get_last_result()
         */
        Elm_Button *unsetTitleLeftBtn();
 
        /**
-        *  @brief Unset a title right button of title area.
+        *  @brief Unsets a title right button of title area.
         *
-        *  @return A previous content. If it wasn't, return @c nullptr.
+        *  @remarks The specific error code can be obtained using the get_last_result() method.
+        *           Error codes are described in Exception section.
+        *
+        *  @return A previous content. If it wasn't, return @c nullptr
+        *  @exception #UI_VIEWMGR_ERROR_NONE Successfully added
+        *  @exception #UI_VIEWMGR_ERROR_NOT_PERMITTED @a right button was not set
+        *  @exception #UI_VIEWMGR_ERROR_RESULT_OUT_OF_RANGE Instance is corrupted. Maybe base object is broken.
+        *
+        *  @see getTitleRightBtn()
+        *  @see setTitleRightBtn()
+        *  @see get_last_result()
         */
        Elm_Button *unsetTitleRightBtn();
 
        /**
-        *  @brief Unset a toolbar.
+        *  @brief Unsets a toolbar.
         *
-        *  @return A previous content. If it wasn't, return @c nullptr.
+        *  @remarks The specific error code can be obtained using the get_last_result() method.
+        *           Error codes are described in Exception section.
+        *
+        *  @return A previous content. If it wasn't, return @c nullptr
+        *  @exception #UI_VIEWMGR_ERROR_NONE Successfully added
+        *  @exception #UI_VIEWMGR_ERROR_NOT_PERMITTED @a toolbar was not set
+        *  @exception #UI_VIEWMGR_ERROR_INVALID_PARAMETER @a view is invalid
+        *
+        *  @see ui_standard_view_get_toolbar()
+        *  @see ui_standard_view_set_toolbar()
+        *  @see get_last_result()
         */
        Elm_Toolbar *unsetToolbar();
 
        /**
-        *  @brief Return a title left button of the view.
+        *  @brief Returns a title left button of the view.
         *
-        *  @return title left button of the view.
+        *  @return title left button of the view
+        *
+        *  @see setTitleLeftBtn()
+        *  @see unsetTitleLeftBtn()
         */
        Elm_Button *getTitleLeftBtn();
 
        /**
-        *  @brief Return a title right button of the view.
+        *  @brief Returns a title right button of the view.
+        *
+        *  @return title right button of the view
         *
-        *  @return title right button of the view.
+        *  @see setTitleRightBtn()
+        *  @see unsetTitleRightBtn()
         */
        Elm_Button *getTitleRightBtn();
 
        /**
-        *  @brief Return a toolbar of the view.
+        *  @brief Returns a toolbar of the view.
+        *
+        *  @return toolbar of the view
         *
-        *  @return toolbar of the view.
+        *  @see setToolbar()
+        *  @see unsetToolbar()
         */
        Elm_Toolbar *getToolbar();
 
index e5649a7..5abc1fd 100644 (file)
@@ -36,12 +36,18 @@ class UiKeyListener;
 class UiView: public efl_viewmanager::UiBaseView
 {
 public:
-       /**
-        *  @brief This is a constructor for initializing this view resources.
-        *
-        *  @param[in] name view name.
-        *
-        *  @warning if you don't set a view name, you could not look up the view with its name. @see ui_viewmgr_view_get_by_name()
+      /**
+       *  @brief This is a constructor for initializing this view resources.
+       *  @remarks if you don't set a view name, you could not look up the view with it's name. @see ui_viewmgr_get_view_by_name().
+       *           The specific error code can be obtained using the get_last_result() method.
+       *           Error codes are described in Exception section.
+       *
+       *  @param[in] name view name.
+       *
+       *  @exception #UI_VIEWMGR_ERROR_NONE Successfully added
+       *  @exception #UI_VIEWMGR_ERROR_OUT_OF_MEMORY Fail to create new instance
+        *
+       *  @see get_last_result()
         */
        explicit UiView(const char *name = nullptr);
 
@@ -49,16 +55,18 @@ public:
        virtual ~UiView();
 
        /**
-        *  @brief Get menu object.
+        *  @brief Gets a menu instance.
         *
         *  @return The menu object that connected with this view. If it doesn't, @c nullptr will be returned.
         */
        const UiMenu *getMenu();
 
        /**
-        *  @brief Get current view's orientation mode.
+        *  @brief Gets current view's orientation mode.
+        *
+        *  @return Current orientation mode, one of #UiViewOrientationMode
         *
-        *  @return Current orientation mode, one of #UiViewOrientationMode.
+        *  @see UiViewOrientationMode
         */
        virtual UiViewOrientationMode getOrientationMode() override;
 
index 41c7f1d..cb8109f 100644 (file)
@@ -64,10 +64,10 @@ typedef struct
  * @param[in] pkg The name of package
  * @param[in] locale_dir The path of locale directory
  *
- * @return @c 0 on success, otherwise a negative error value.
+ * @return @c 0 on success, otherwise a negative error value
  * @retval #UI_VIEWMGR_ERROR_NONE Successful
- * @retval #UI_VIEWMGR_ERROR_ALREADY_IN_PROGRESS Initialization was already done.
- * @retval #UI_VIEWMGR_ERROR_OUT_OF_MEMORY Fails to allocate memory.
+ * @retval #UI_VIEWMGR_ERROR_ALREADY_IN_PROGRESS Initialization was already done
+ * @retval #UI_VIEWMGR_ERROR_OUT_OF_MEMORY Fails to allocate memory
  *
  * @see ui_application_term()
  * @see ui_application_run()
@@ -84,12 +84,12 @@ EAPI int ui_application_init(const char *pkg, const char *locale_dir);
  * @param[in] events Event callback list
  * @param[in] user_data User data for event callbacks
  *
- * @return @c 0 on success, otherwise a negative error value.
+ * @return @c 0 on success, otherwise a negative error value
  * @retval #UI_VIEWMGR_ERROR_NONE Successful
  * @retval #UI_VIEWMGR_ERROR_INVALID_PARAMETER Invalid parameters
  * @retval #UI_VIEWMGR_ERROR_APPLICATION The application is illegally launched, not launched by the launch system.
- * @retval #UI_VIEWMGR_ERROR_ALREADY_IN_PROGRESS The main loop already starts.
- * @retval #UI_VIEWMGR_ERROR_NOT_PERMITTED If Initialization was not performed yet.
+ * @retval #UI_VIEWMGR_ERROR_ALREADY_IN_PROGRESS The main loop already starts
+ * @retval #UI_VIEWMGR_ERROR_NOT_PERMITTED If Initialization was not performed yet
  *
  * @pre Call ui_application_init() before calling this function.
  *
@@ -104,7 +104,7 @@ EAPI int ui_application_run(int argc, char **argv, ui_application_event_s *event
  * @brief Deinitializes ui_application.
  * @since_tizen 3.0
  *
- * @return @c 0 on success, otherwise a negative error value.
+ * @return @c 0 on success, otherwise a negative error value
  * @retval #UI_VIEWMGR_ERROR_NONE Successful
  *
  * @pre Call ui_application_init() before calling this function.
index b73db06..14808ae 100644 (file)
@@ -19,9 +19,9 @@ extern "C" {
  * @param[in] menu An ui_menu object
  * @param[in] ctxpopup ctxpopup object. It allows @c NULL for canceling the previous content
  *
- * @return @c 0 on success, otherwise a negative error value.
+ * @return @c 0 on success, otherwise a negative error value
  * @retval #UI_VIEWMGR_ERROR_NONE Successful
- * @retval #UI_VIEWMGR_ERROR_INVALID_PARAMETER @a menu is invalid or @a content is not a type of Elm_Ctxpopup.
+ * @retval #UI_VIEWMGR_ERROR_INVALID_PARAMETER @a menu is invalid or @a content is not a type of Elm_Ctxpopup
  *
  * @see ui_menu_get_content()
  * @see ui_menu_unset_content()
@@ -31,26 +31,36 @@ EAPI int ui_menu_set_content(ui_menu *menu, Elm_Ctxpopup *content);
 /**
  * @brief Returns an ui_menu content.
  * @since_tizen 3.0
+ * @remarks The specific error code can be obtained using the get_last_result() method.
+ *          Error codes are described in Exception section.
  *
  * @param[in] menu An ui_menu instance
  *
  * @return A content of ui_menu
+ * @exception #UI_VIEWMGR_ERROR_NONE Successfully added
+ * @exception #UI_VIEWMGR_ERROR_INVALID_PARAMETER @a menu is invalid
  *
  * @see ui_menu_set_content()
  * @see ui_menu_unset_content()
+ * @see get_last_result()
  */
 EAPI Elm_Ctxpopup *ui_menu_get_content(ui_menu *menu);
 
 /**
  * @brief Unsets an ui_menu content.
  * @since_tizen 3.0
+ * @remarks The specific error code can be obtained using the get_last_result() method.
+ *          Error codes are described in Exception section.
  *
  * @param[in] menu An ui_menu instance
  *
  * @return A previous content. If it wasn't, return @c NULL
+ * @exception #UI_VIEWMGR_ERROR_NONE Successfully added
+ * @exception #UI_VIEWMGR_ERROR_INVALID_PARAMETER @a menu is invalid
  *
  * @see ui_menu_set_content()
  * @see ui_menu_get_content()
+ * @see get_last_result()
  */
 EAPI Elm_Ctxpopup *ui_menu_unset_content(ui_menu *menu);
 
@@ -61,10 +71,10 @@ EAPI Elm_Ctxpopup *ui_menu_unset_content(ui_menu *menu);
  *
  * @param[in] menu An ui_menu instance
  *
- * @return @c 0 on success, otherwise a negative error value.
+ * @return @c 0 on success, otherwise a negative error value
  * @retval #UI_VIEWMGR_ERROR_NONE Successful
- * @retval #UI_VIEWMGR_ERROR_NOT_PERMITTED menu instance is not set up yet.
- * @retval #UI_VIEWMGR_ERROR_INVALID_PARAMETER @a menu is invalid.
+ * @retval #UI_VIEWMGR_ERROR_NOT_PERMITTED menu instance is not set up yet
+ * @retval #UI_VIEWMGR_ERROR_INVALID_PARAMETER @a menu is invalid
  *
  * @see ui_menu_deactivate()
  */
@@ -77,10 +87,10 @@ EAPI int ui_menu_activate(ui_menu *menu);
  *
  * @param[in] menu An ui_menu instance
  *
- * @return @c 0 on success, otherwise a negative error value.
+ * @return @c 0 on success, otherwise a negative error value
  * @retval #UI_VIEWMGR_ERROR_NONE Successful
- * @retval #UI_VIEWMGR_ERROR_NOT_PERMITTED menu instance is not set up yet.
- * @retval #UI_VIEWMGR_ERROR_INVALID_PARAMETER @a menu is invalid.
+ * @retval #UI_VIEWMGR_ERROR_NOT_PERMITTED menu instance is not set up yet
+ * @retval #UI_VIEWMGR_ERROR_INVALID_PARAMETER @a menu is invalid
  *
  * @see ui_menu_activate()
  */
@@ -89,13 +99,18 @@ EAPI int ui_menu_deactivate(ui_menu *menu);
 /**
  * @brief Returns the active status of ui_menu.
  * @since_tizen 3.0
+ * @remarks The specific error code can be obtained using the get_last_result() method.
+ *          Error codes are described in Exception section.
  *
  * @param[in] menu An ui_menu instance
  *
  * @return @c true if menu is activated, @c false otherwise
+ * @exception #UI_VIEWMGR_ERROR_NONE Successfully added
+ * @exception #UI_VIEWMGR_ERROR_INVALID_PARAMETER @a menu is invalid
  *
  * @see ui_menu_activate()
  * @see ui_menu_deactivate()
+ * @see get_last_result()
  */
 EAPI bool ui_menu_get_activated(ui_menu *menu);
 
@@ -103,30 +118,48 @@ EAPI bool ui_menu_get_activated(ui_menu *menu);
  * @brief Gets a base object of an ui_menu.
  * @details Normally, A base object can be used for a parent of ui_menu content.
  * @since_tizen 3.0
+ * @remarks The specific error code can be obtained using the get_last_result() method.
+ *          Error codes are described in Exception section.
  *
  * @param[in] menu An ui_menu instance
  *
  * @return base object of ui_menu
+ * @exception #UI_VIEWMGR_ERROR_NONE Successfully added
+ * @exception #UI_VIEWMGR_ERROR_INVALID_PARAMETER @a menu is invalid
+ *
+ * @see get_last_result()
  */
 EAPI Eo *ui_menu_get_base(ui_menu *menu);
 
 /**
  * @brief Gets a current ui_menu's degree.
  * @since_tizen 3.0
+ * @remarks The specific error code can be obtained using the get_last_result() method.
+ *          Error codes are described in Exception section.
  *
  * @param[in] menu An ui_menu instance
  *
  * @return Current rotation degree, -1 if it fails to get degree information
+ * @exception #UI_VIEWMGR_ERROR_NONE Successfully added
+ * @exception #UI_VIEWMGR_ERROR_INVALID_PARAMETER @a menu is invalid
+ *
+ * @see get_last_result()
  */
 EAPI int ui_menu_get_degree(ui_menu *menu);
 
 /**
  * @brief Returns a view which is matched with this ui_menu.
  * @since_tizen 3.0
+ * @remarks The specific error code can be obtained using the get_last_result() method.
+ *          Error codes are described in Exception section.
  *
  * @param[in] menu An ui_menu instance
  *
  * @return The view which is matched with ui_menu
+ * @exception #UI_VIEWMGR_ERROR_NONE Successfully added
+ * @exception #UI_VIEWMGR_ERROR_INVALID_PARAMETER @a menu is invalid
+ *
+ * @see get_last_result()
  */
 EAPI ui_view *ui_menu_get_view(ui_menu *menu);
 
index 7b787b4..8239f79 100644 (file)
@@ -17,10 +17,15 @@ extern "C" {
  * @since_tizen 3.0
  * @remarks The instance of ui_popup is subordinated to the given @a ui_view. If the given @a ui_view is hidden or deactivated, this ui_popup will be also do
  *          same followed to its ui_view behaviors. The instance of ui_popup will be destroyed automatically when the ui_view is destroyed.
+ *          The specific error code can be obtained using the get_last_result() method.
+ *          Error codes are described in Exception section.
  *
  * @param[in] view An instance of ui_view
  *
  * @return An ui_popup instance
+ * @exception #UI_VIEWMGR_ERROR_NONE Successfully added
+ * @exception #UI_VIEWMGR_ERROR_OUT_OF_MEMORY Fail to create new instance
+ * @exception #UI_VIEWMGR_ERROR_INVALID_PARAMETER @a popup is invalid
  *
  * @see ui_popup_destroy()
  */
@@ -33,9 +38,9 @@ EAPI ui_popup *ui_popup_create(ui_view *view);
  *
  * @param[in] popup An ui_popup instance
  *
- * @return @c 0 on success, otherwise a negative error value.
+ * @return @c 0 on success, otherwise a negative error value
  * @retval #UI_VIEWMGR_ERROR_NONE Successful
- * @retval #UI_VIEWMGR_ERROR_INVALID_PARAMETER @a popup is invalid.
+ * @retval #UI_VIEWMGR_ERROR_INVALID_PARAMETER @a popup is invalid
  *
  * @see ui_popup_create()
  */
@@ -48,9 +53,9 @@ EAPI int ui_popup_destroy(ui_popup *popup);
  * @param[in] popup An ui_popup instance
  * @param[in] content popup object. It allows @c NULL for canceling the previous content
  *
- * @return @c 0 on success, otherwise a negative error value.
+ * @return @c 0 on success, otherwise a negative error value
  * @retval #UI_VIEWMGR_ERROR_NONE Successful
- * @retval #UI_VIEWMGR_ERROR_INVALID_PARAMETER @a popup is invalid or @a content is not a type of Elm_Popup.
+ * @retval #UI_VIEWMGR_ERROR_INVALID_PARAMETER @a popup is invalid or @a content is not a type of Elm_Popup
  *
  * @see ui_popup_get_content()
  * @see ui_popup_unset_content()
@@ -60,26 +65,36 @@ EAPI int ui_popup_set_content(ui_popup *popup, Elm_Popup *content);
 /**
  * @brief Returns a content object of ui_popup.
  * @since_tizen 3.0
+ * @remarks The specific error code can be obtained using the get_last_result() method.
+ *          Error codes are described in Exception section.
  *
  * @param[in] popup An ui_popup instance
  *
  * @return A content of ui_popup
+ * @exception #UI_VIEWMGR_ERROR_NONE Successfully added
+ * @exception #UI_VIEWMGR_ERROR_INVALID_PARAMETER @a popup is invalid
  *
  * @see ui_popup_set_content()
  * @see ui_popup_unset_content()
+ * @see get_last_result()
  */
 EAPI Elm_Popup *ui_popup_get_content(ui_popup *popup);
 
 /**
  * @brief Unsets an ui_popup content.
  * @since_tizen 3.0
+ * @remarks The specific error code can be obtained using the get_last_result() method.
+ *          Error codes are described in Exception section.
  *
  * @param[in] popup An ui_popup instance
  *
  * @return A previous content. If it wasn't, return @c NULL
+ * @exception #UI_VIEWMGR_ERROR_NONE Successfully added
+ * @exception #UI_VIEWMGR_ERROR_INVALID_PARAMETER @a popup is invalid
  *
  * @see ui_popup_get_content()
  * @see ui_popup_set_content()
+ * @see get_last_result()
  */
 EAPI Elm_Popup *ui_popup_unset_content(ui_popup *popup);
 
@@ -90,10 +105,10 @@ EAPI Elm_Popup *ui_popup_unset_content(ui_popup *popup);
  *
  * @param[in] popup An ui_popup instance
  *
- * @return @c 0 on success, otherwise a negative error value.
+ * @return @c 0 on success, otherwise a negative error value
  * @retval #UI_VIEWMGR_ERROR_NONE Successful
- * @retval #UI_VIEWMGR_ERROR_NOT_PERMITTED popup instance is not set up yet.
- * @retval #UI_VIEWMGR_ERROR_INVALID_PARAMETER @a popup is invalid.
+ * @retval #UI_VIEWMGR_ERROR_NOT_PERMITTED popup instance is not set up yet
+ * @retval #UI_VIEWMGR_ERROR_INVALID_PARAMETER @a popup is invalid
  *
  * @see ui_popup_deactivate()
  * @see ui_popup_get_activated()
@@ -109,8 +124,8 @@ EAPI int ui_popup_activate(ui_popup *popup);
  *
  * @return @c 0 on success, otherwise a negative error value.
  * @retval #UI_VIEWMGR_ERROR_NONE Successful
- * @retval #UI_VIEWMGR_ERROR_NOT_PERMITTED popup instance is not set up yet.
- * @retval #UI_VIEWMGR_ERROR_INVALID_PARAMETER @a popup is invalid.
+ * @retval #UI_VIEWMGR_ERROR_NOT_PERMITTED popup instance is not set up yet
+ * @retval #UI_VIEWMGR_ERROR_INVALID_PARAMETER @a popup is invalid
  *
  * @see ui_popup_activate()
  * @see ui_popup_get_activated()
@@ -120,13 +135,18 @@ EAPI int ui_popup_deactivate(ui_popup *popup);
 /**
  * @brief Returns the active status of ui_popup.
  * @since_tizen 3.0
+ * @remarks The specific error code can be obtained using the get_last_result() method.
+ *          Error codes are described in Exception section.
  *
  * @param[in] popup An ui_popup instance
  *
  * @return @c true if ui_popup is activated, @c false otherwise
+ * @exception #UI_VIEWMGR_ERROR_NONE Successfully added
+ * @exception #UI_VIEWMGR_ERROR_INVALID_PARAMETER @a popup is invalid
  *
  * @see ui_popup_activate()
  * @see ui_popup_deactivate()
+ * @see get_last_result()
  */
 EAPI bool ui_popup_get_activated(ui_popup *popup);
 
@@ -134,31 +154,48 @@ EAPI bool ui_popup_get_activated(ui_popup *popup);
  * @brief Gets a base object of an ui_popup.
  * @details Normally, A base object can be used for a parent of ui_popup content.
  * @since_tizen 3.0
+ * @remarks The specific error code can be obtained using the get_last_result() method.
+ *          Error codes are described in Exception section.
+ *
+ * @param[in] popup An ui_popup instance
  *
- * @param[in] menu An ui_popup instance
+ * @return base object of popup
+ * @exception #UI_VIEWMGR_ERROR_NONE Successfully added
+ * @exception #UI_VIEWMGR_ERROR_INVALID_PARAMETER @a popup is invalid
  *
- * @return base object of ui_popup
-
+ * @see get_last_result()
  */
 EAPI Eo *ui_popup_get_base(ui_popup *popup);
 
 /**
  * @brief Gets current ui_popup's degree.
  * @since_tizen 3.0
+ * @remarks The specific error code can be obtained using the get_last_result() method.
+ *          Error codes are described in Exception section.
  *
  * @param[in] popup An ui_popup instance
  *
  * @return Current rotation degree, -1 if it fails to get degree information
+ * @exception #UI_VIEWMGR_ERROR_NONE Successfully added
+ * @exception #UI_VIEWMGR_ERROR_INVALID_PARAMETER @a popup is invalid
+ *
+ * @see get_last_result()
  */
 EAPI int ui_popup_get_degree(ui_popup *popup);
 
 /**
  * @brief Returns a view which is matched with the ui_popup.
  * @since_tizen 3.0
+ * @remarks The specific error code can be obtained using the get_last_result() method.
+ *          Error codes are described in Exception section.
  *
  * @param[in] popup An ui_popup instance
  *
  * @return The view which is matched with ui_popup
+ * @exception #UI_VIEWMGR_ERROR_NONE Successfully added
+ * @exception #UI_VIEWMGR_ERROR_INVALID_PARAMETER @a popup is invalid
+ *
+ * @see get_last_result()
  */
 EAPI ui_view *ui_popup_get_view(ui_popup *popup);
 
index a60d051..e97377a 100644 (file)
@@ -15,13 +15,18 @@ extern "C" {
 /**
  * @brief Creates an ui_standard_view.
  * @since_tizen 3.0
- * @remarks if you don't set a view name, you could not look up the view with its name. @see ui_viewmgr_get_view_by_name().
+ * @remarks if you don't set a view name, you could not look up the view with it's name. @see ui_viewmgr_get_view_by_name().
+ *          The specific error code can be obtained using the get_last_result() method.
+ *          Error codes are described in Exception section.
  *
  * @param[in] name view name
  *
- * @return view An ui_standard_view instance
+ * @return The ui_view instance. NULL if failed
+ * @exception #UI_VIEWMGR_ERROR_NONE Successfully added
+ * @exception #UI_VIEWMGR_ERROR_OUT_OF_MEMORY Fail to create new instance
  *
  * @see ui_view_destroy()
+ * @see get_last_result()
  */
 EAPI ui_standard_view *ui_standard_view_create(const char *name);
 
@@ -32,10 +37,10 @@ EAPI ui_standard_view *ui_standard_view_create(const char *name);
  * @param[in] view An ui_standard_view instance
  * @param[in] text The label in the title area
  *
- * @return @c 0 on success, otherwise a negative error value.
+ * @return @c 0 on success, otherwise a negative error value
  * @retval #UI_VIEWMGR_ERROR_NONE Successful
- * @retval #UI_VIEWMGR_ERROR_INVALID_PARAMETER if @a view is invalid.
- * @retval #UI_VIEWMGR_ERROR_RESULT_OUT_OF_RANGE Instance is corrupted. Maybe base object is broken.
+ * @retval #UI_VIEWMGR_ERROR_INVALID_PARAMETER if @a view is invalid
+ * @retval #UI_VIEWMGR_ERROR_RESULT_OUT_OF_RANGE Instance is corrupted. Maybe base object is broken
  *
  * @see ui_standard_view_get_title()
  */
@@ -48,10 +53,10 @@ EAPI int ui_standard_view_set_title(ui_standard_view *view, const char *text);
  * @param[in] view An ui_standard_view instance
  * @param[in] text The label in the subtitle area
  *
- * @return @c 0 on success, otherwise a negative error value.
+ * @return @c 0 on success, otherwise a negative error value
  * @retval #UI_VIEWMGR_ERROR_NONE Successful
- * @retval #UI_VIEWMGR_ERROR_INVALID_PARAMETER if @a view is invalid.
- * @retval #UI_VIEWMGR_ERROR_RESULT_OUT_OF_RANGE Instance is corrupted. Maybe base object is broken.
+ * @retval #UI_VIEWMGR_ERROR_INVALID_PARAMETER if @a view is invalid
+ * @retval #UI_VIEWMGR_ERROR_RESULT_OUT_OF_RANGE Instance is corrupted. Maybe base object is broken
  *
  * @see ui_standard_view_get_sub_title()
  */
@@ -64,10 +69,10 @@ EAPI int ui_standard_view_set_sub_title(ui_standard_view *view, const char *text
  * @param[in] view An ui_standard_view instance
  * @param[in] text The label in the title badge area
  *
- * @return @c 0 on success, otherwise a negative error value.
+ * @return @c 0 on success, otherwise a negative error value
  * @retval #UI_VIEWMGR_ERROR_NONE Successful
- * @retval #UI_VIEWMGR_ERROR_INVALID_PARAMETER if @a view is invalid.
- * @retval #UI_VIEWMGR_ERROR_RESULT_OUT_OF_RANGE Instance is corrupted. Maybe base object is broken.
+ * @retval #UI_VIEWMGR_ERROR_INVALID_PARAMETER if @a view is invalid
+ * @retval #UI_VIEWMGR_ERROR_RESULT_OUT_OF_RANGE Instance is corrupted. Maybe base object is broken
  *
  * @see ui_standard_view_get_title_badge()
  */
@@ -80,11 +85,11 @@ EAPI int ui_standard_view_set_title_badge(ui_standard_view *view, const char *ba
  * @param[in] view An ui_standard_view instance
  * @param[in] title_right_btn The button in the right part of title area
  *
- * @return @c 0 on success, otherwise a negative error value.
+ * @return @c 0 on success, otherwise a negative error value
  * @retval #UI_VIEWMGR_ERROR_NONE Successful
- * @retval #UI_VIEWMGR_ERROR_INVALID_PARAMETER if @a view is invalid.
- * @retval #UI_VIEWMGR_ERROR_ALREADY_IN_PROGRESS if @a title_right_btn is same with the existing one.
- * @retval #UI_VIEWMGR_ERROR_RESULT_OUT_OF_RANGE Instance is corrupted. Maybe base object is broken.
+ * @retval #UI_VIEWMGR_ERROR_INVALID_PARAMETER if @a view is invalid
+ * @retval #UI_VIEWMGR_ERROR_ALREADY_IN_PROGRESS if @a title_right_btn is same with the existing one
+ * @retval #UI_VIEWMGR_ERROR_RESULT_OUT_OF_RANGE Instance is corrupted. Maybe base object is broken
  *
  * @see ui_standard_view_get_title_right_btn()
  * @see ui_standard_view_unset_title_right_btn()
@@ -94,26 +99,37 @@ EAPI int ui_standard_view_set_title_right_btn(ui_standard_view *view, Elm_Button
 /**
  * @brief Returns a title right button of the view.
  * @since_tizen 3.0
+ * @remarks The specific error code can be obtained using the get_last_result() method.
+ *          Error codes are described in Exception section.
  *
  * @param[in] view An ui_standard_view instance
  *
  * @return title right button of the view
+ * @exception #UI_VIEWMGR_ERROR_NONE Successfully added
+ * @exception #UI_VIEWMGR_ERROR_INVALID_PARAMETER @a view is invalid
  *
  * @see ui_standard_view_set_title_right_btn()
  * @see ui_standard_view_unset_title_right_btn()
+ * @see get_last_result()
  */
 EAPI Elm_Button *ui_standard_view_get_title_right_btn(ui_standard_view *view);
 
 /**
  * @brief Unsets a title right button of title area.
  * @since_tizen 3.0
+ * @remarks The specific error code can be obtained using the get_last_result() method.
+ *          Error codes are described in Exception section.
  *
  * @param[in] view An ui_standard_view instance
  *
  * @return A previous content. If it wasn't, return @c NULL
+ * @exception #UI_VIEWMGR_ERROR_NONE Successfully added
+ * @exception #UI_VIEWMGR_ERROR_INVALID_PARAMETER @a view is invalid
+ * @exception #UI_VIEWMGR_ERROR_RESULT_OUT_OF_RANGE Instance is corrupted. Maybe base object is broken
  *
  * @see ui_standard_view_get_title_right_btn()
  * @see ui_standard_view_set_title_right_btn()
+ * @see get_last_result()
  */
 EAPI Elm_Button *ui_standard_view_unset_title_right_btn(ui_standard_view *view);
 
@@ -126,9 +142,9 @@ EAPI Elm_Button *ui_standard_view_unset_title_right_btn(ui_standard_view *view);
  *
  * @return @c 0 on success, otherwise a negative error value.
  * @retval #UI_VIEWMGR_ERROR_NONE Successful
- * @retval #UI_VIEWMGR_ERROR_INVALID_PARAMETER if @a view is invalid.
- * @retval #UI_VIEWMGR_ERROR_ALREADY_IN_PROGRESS if @a title_left_btn is same with the existing one.
- * @retval #UI_VIEWMGR_ERROR_RESULT_OUT_OF_RANGE Instance is corrupted. Maybe base object is broken.
+ * @retval #UI_VIEWMGR_ERROR_INVALID_PARAMETER if @a view is invalid
+ * @retval #UI_VIEWMGR_ERROR_ALREADY_IN_PROGRESS if @a title_left_btn is same with the existing one
+ * @retval #UI_VIEWMGR_ERROR_RESULT_OUT_OF_RANGE Instance is corrupted. Maybe base object is broken
  *
  * @see ui_standard_view_get_title_left_btn()
  * @see ui_standard_view_unset_title_left_btn()
@@ -138,26 +154,37 @@ EAPI int ui_standard_view_set_title_left_btn(ui_standard_view *view, Elm_Button
 /**
  * @brief Returns a title left button of the view.
  * @since_tizen 3.0
+ * @remarks The specific error code can be obtained using the get_last_result() method.
+ *          Error codes are described in Exception section.
  *
  * @param[in] view An ui_standard_view instance
+ * @exception #UI_VIEWMGR_ERROR_NONE Successfully added
+ * @exception #UI_VIEWMGR_ERROR_INVALID_PARAMETER @a view is invalid
  *
  * @return title left button of the view
  *
  * @see ui_standard_view_set_title_left_btn()
  * @see ui_standard_view_unset_title_left_btn()
+ * @see get_last_result()
  */
 EAPI Elm_Button *ui_standard_view_get_title_left_btn(ui_standard_view *view);
 
 /**
- * @brief Unsets a title right button of title area.
+ * @brief Unsets a title left button of title area.
  * @since_tizen 3.0
+ * @remarks The specific error code can be obtained using the get_last_result() method.
+ *          Error codes are described in Exception section.
  *
  * @param[in] view An ui_standard_view instance
  *
  * @return A previous content. If it wasn't, return @c NULL
+ * @exception #UI_VIEWMGR_ERROR_NONE Successfully added
+ * @exception #UI_VIEWMGR_ERROR_INVALID_PARAMETER @a view is invalid
+ * @exception #UI_VIEWMGR_ERROR_RESULT_OUT_OF_RANGE Instance is corrupted. Maybe base object is broken
  *
  * @see ui_standard_view_get_title_left_btn()
  * @see ui_standard_view_set_title_left_btn()
+ * @see get_last_result()
  */
 EAPI Elm_Button *ui_standard_view_unset_title_left_btn(ui_standard_view *view);
 
@@ -168,40 +195,51 @@ EAPI Elm_Button *ui_standard_view_unset_title_left_btn(ui_standard_view *view);
  * @param[in] view An ui_standard_view instance
  * @param[in] toolbar Toolbar object
  *
- * @return @c 0 on success, otherwise a negative error value.
+ * @return @c 0 on success, otherwise a negative error value
  * @retval #UI_VIEWMGR_ERROR_NONE Successful
- * @retval #UI_VIEWMGR_ERROR_INVALID_PARAMETER if @a view is invalid.
- * @retval #UI_VIEWMGR_ERROR_ALREADY_IN_PROGRESS if @a toolbar is already existing.
- * @retval #UI_VIEWMGR_ERROR_RESULT_OUT_OF_RANGE Instance is corrupted. Maybe base object is broken.
+ * @retval #UI_VIEWMGR_ERROR_INVALID_PARAMETER if @a view is invalid
+ * @retval #UI_VIEWMGR_ERROR_ALREADY_IN_PROGRESS if @a toolbar is already existing
+ * @retval #UI_VIEWMGR_ERROR_RESULT_OUT_OF_RANGE Instance is corrupted. Maybe base object is broken
  *
  * @see ui_standard_view_get_toolbar()
  * @see ui_standard_view_unset_toolbar()
+ * @see get_last_result()
  */
 EAPI int ui_standard_view_set_toolbar(ui_standard_view *view, Elm_Toolbar *toolbar);
 
 /**
  * @brief Returns a toolbar of the view.
  * @since_tizen 3.0
+ * @remarks The specific error code can be obtained using the get_last_result() method.
+ *          Error codes are described in Exception section.
  *
  * @param[in] view An ui_standard_view instance
  *
  * @return The toolbar of the given @a view
+ * @exception #UI_VIEWMGR_ERROR_NONE Successfully added
+ * @exception #UI_VIEWMGR_ERROR_INVALID_PARAMETER @a view is invalid
  *
  * @see ui_standard_view_set_toolbar()
  * @see ui_standard_view_unset_toolbar()
+ * @see get_last_result()
  */
 EAPI Elm_Toolbar *ui_standard_view_get_toolbar(ui_standard_view *view);
 
 /**
  * @brief Unsets a toolbar.
  * @since_tizen 3.0
+ * @remarks The specific error code can be obtained using the get_last_result() method.
+ *          Error codes are described in Exception section.
  *
  * @param[in] view An ui_standard_view instance
  *
  * @return A previous content. If it wasn't, return @c NULL
+ * @exception #UI_VIEWMGR_ERROR_NONE Successfully added
+ * @exception #UI_VIEWMGR_ERROR_INVALID_PARAMETER @a view is invalid
  *
  * @see ui_standard_view_get_toolbar()
  * @see ui_standard_view_set_toolbar()
+ * @see get_last_result()
  */
 EAPI Elm_Toolbar *ui_standard_view_unset_toolbar(ui_standard_view *view);
 
@@ -213,10 +251,10 @@ EAPI Elm_Toolbar *ui_standard_view_unset_toolbar(ui_standard_view *view);
  * @param[in] visible title state set as visible if the given param is @c true, otherwise title area set as invisible
  * @param[in] anim title area will be shown with animation if the given param is @c true, otherwise title area will be shown without animation
  *
- * @return @c 0 on success, otherwise a negative error value.
+ * @return @c 0 on success, otherwise a negative error value
  * @retval #UI_VIEWMGR_ERROR_NONE Successful
- * @retval #UI_VIEWMGR_ERROR_INVALID_PARAMETER if @a view is invalid.
- * @retval #UI_VIEWMGR_ERROR_RESULT_OUT_OF_RANGE Instance is corrupted. Maybe base object is broken.
+ * @retval #UI_VIEWMGR_ERROR_INVALID_PARAMETER if @a view is invalid
+ * @retval #UI_VIEWMGR_ERROR_RESULT_OUT_OF_RANGE Instance is corrupted. Maybe base object is broken
  */
 EAPI int ui_standard_view_set_title_visible(ui_standard_view *view, bool visible, bool anim);
 
index b385b91..56bff07 100644 (file)
@@ -66,12 +66,17 @@ typedef enum
  * @brief Creates an ui_view.
  * @since_tizen 3.0
  * @remarks if you don't set a view name, you could not look up the view with it's name. @see ui_viewmgr_get_view_by_name().
+ *          The specific error code can be obtained using the get_last_result() method.
+ *          Error codes are described in Exception section.
  *
  * @param[in] name view name
  *
- * @return The ui_view instance.
+ * @return The ui_view instance. @c NULL if failed
+ * @exception #UI_VIEWMGR_ERROR_NONE Successfully added
+ * @exception #UI_VIEWMGR_ERROR_OUT_OF_MEMORY Fail to create new instance
  *
  * @see ui_view_destroy()
+ * @see get_last_result()
  */
 EAPI ui_view *ui_view_create(const char *name);
 
@@ -82,9 +87,9 @@ EAPI ui_view *ui_view_create(const char *name);
  * @param[in] view An ui_view instance
  * @param[in] content A new content. It allows @c NULL for canceling the previous content
  *
- * @return @c 0 on success, otherwise a negative error value.
+ * @return @c 0 on success, otherwise a negative error value
  * @retval #UI_VIEWMGR_ERROR_NONE Successful
- * @retval #UI_VIEWMGR_ERROR_INVALID_PARAMETER if @a view is invalid.
+ * @retval #UI_VIEWMGR_ERROR_INVALID_PARAMETER if @a view is invalid
  *
  * @see ui_view_get_content()
  * @see ui_view_unset_content()
@@ -94,26 +99,36 @@ EAPI int ui_view_set_content(ui_view *view, Eo *content);
 /**
  * @brief Returns a content of this view.
  * @since_tizen 3.0
+ * @remarks The specific error code can be obtained using the get_last_result() method.
+ *          Error codes are described in Exception section.
  *
  * @param[in] view An ui_view instance
  *
  * @return content of @a view. If no contents set yet, @c NULL
+ * @exception #UI_VIEWMGR_ERROR_NONE Successfully added
+ * @exception #UI_VIEWMGR_ERROR_INVALID_PARAMETER @a view is invalid
  *
  * @see ui_view_set_content()
  * @see ui_view_unset_content()
+ * @see get_last_result()
  */
 EAPI Eo *ui_view_get_content(ui_view *view);
 
 /**
  * @brief Unsets a ui_view content.
  * @since_tizen 3.0
+ * @remarks The specific error code can be obtained using the get_last_result() method.
+ *          Error codes are described in Exception section.
  *
  * @param[in] view An ui_view instance
  *
  * @return A previous content. If it wasn't, return @c NULL
+ * @exception #UI_VIEWMGR_ERROR_NONE Successfully added
+ * @exception #UI_VIEWMGR_ERROR_INVALID_PARAMETER @a view is invalid
  *
  * @see ui_view_set_content()
  * @see ui_view_get_content()
+ * @see get_last_result()
  */
 EAPI Eo *ui_view_unset_content(ui_view *view);
 
@@ -126,9 +141,9 @@ EAPI Eo *ui_view_unset_content(ui_view *view);
  * @param[in] event_cb The set of callback functions to handle view events
  * @param[in] user_data The user data to be passed to the given @a event_callback functions
  *
- * @return @c 0 on success, otherwise a negative error value.
+ * @return @c 0 on success, otherwise a negative error value
  * @retval #UI_VIEWMGR_ERROR_NONE Successful
- * @retval #UI_VIEWMGR_ERROR_INVALID_PARAMETER if @a view is invalid.
+ * @retval #UI_VIEWMGR_ERROR_INVALID_PARAMETER if @a view is invalid
  *
  * @see ui_view_event_type_e
  */
@@ -138,10 +153,16 @@ EAPI int ui_view_set_event_cb(ui_view *view, ui_view_event_type_e event_type, ui
  * @brief Gets a base object of ui_view.
  * @since_tizen 3.0
  * @remarks Normally, this base object can be used for a parent of a view content.
+ *          The specific error code can be obtained using the get_last_result() method.
+ *          Error codes are described in Exception section.
  *
  * @param[in] view An ui_view instance
  *
  * @return The base object of ui_view
+ * @exception #UI_VIEWMGR_ERROR_NONE Successfully added
+ * @exception #UI_VIEWMGR_ERROR_INVALID_PARAMETER @a view is invalid
+ *
+ * @see get_last_result()
  */
 EAPI Eo* ui_view_get_base(ui_view *view);
 
@@ -152,10 +173,10 @@ EAPI Eo* ui_view_get_base(ui_view *view);
  * @param[in] view An ui_view instance
  * @param[in] indicator The mode to set, one of #ui_view_indicator
  *
- * @return @c 0 on success, otherwise a negative error value.
+ * @return @c 0 on success, otherwise a negative error value
  * @retval #UI_VIEWMGR_ERROR_NONE Successful
- * @retval #UI_VIEWMGR_ERROR_INVALID_PARAMETER Invalid Parameters.
- * @retval #UI_VIEWMGR_ERROR_NOT_PERMITTED Current view manager system is not set up.
+ * @retval #UI_VIEWMGR_ERROR_INVALID_PARAMETER Invalid Parameters
+ * @retval #UI_VIEWMGR_ERROR_NOT_PERMITTED Current view manager system is not set up
  *
  * @see ui_view_indicator
  * @see ui_view_get_indicator()
@@ -165,12 +186,17 @@ EAPI int ui_view_set_indicator(ui_view *view, ui_view_indicator indicator);
 /**
  * @brief Returns the indicator mode of this view.
  * @since_tizen 3.0
+ * @remarks The specific error code can be obtained using the get_last_result() method.
+ *          Error codes are described in Exception section.
  *
  * @param view An ui_view instance
  *
  * @return indicator state of the given @a view
+ * @exception #UI_VIEWMGR_ERROR_NONE Successfully added
+ * @exception #UI_VIEWMGR_ERROR_INVALID_PARAMETER @a view is invalid
  *
  * @see ui_view_get_indicator()
+ * @see get_last_result()
  */
 EAPI ui_view_indicator ui_view_get_indicator(ui_view *view);
 
@@ -183,11 +209,11 @@ EAPI ui_view_indicator ui_view_get_indicator(ui_view *view);
  * @param[in] rotations The array of rotation values
  * @param[in] count The number of arrays of rotations
  *
- * @return @c 0 on success, otherwise a negative error value.
+ * @return @c 0 on success, otherwise a negative error value
  * @retval #UI_VIEWMGR_ERROR_NONE Successful
- * @retval #UI_VIEWMGR_ERROR_INVALID_PARAMETER If @a view is invalid or @a count is less than 1 or @a rotations is invalid pointer.
+ * @retval #UI_VIEWMGR_ERROR_INVALID_PARAMETER If @a view is invalid or @a count is less than 1 or @a rotations is invalid pointer
  * @retval #UI_VIEWMGR_ERROR_OUT_OF_MEMORY Out of Memory
- * @retval #UI_VIEWMGR_ERROR_NOT_PERMITTED Current view manager system is not set up.
+ * @retval #UI_VIEWMGR_ERROR_NOT_PERMITTED Current view manager system is not set up
  *
  * @see ui_view_get_available_rotations()
  */
@@ -196,15 +222,19 @@ EAPI int ui_view_set_available_rotations(ui_view *view, const int *rotations, un
 /**
  * @brief Gets the array of view's available rotations.
  * @since_tizen 3.0
+ * @remarks @c NULL will be returned if @a view or @a count is invalid.
+ *          The specific error code can be obtained using the get_last_result() method.
+ *          Error codes are described in Exception section.
  *
  * @param[in] view An ui_view instance
  * @param[out] count The number of arrays of rotations
  *
  * @return The array of rotation values
- *
- * @warning @c NULL will be returned if @a view or @a count is invalid.
+ * @exception #UI_VIEWMGR_ERROR_NONE Successfully added
+ * @exception #UI_VIEWMGR_ERROR_INVALID_PARAMETER @a view is invalid
  *
  * @see ui_view_set_available_rotations()
+ * @see get_last_result()
  */
 EAPI const int *ui_view_get_available_rotations(ui_view *view, unsigned int *count);
 
@@ -217,9 +247,9 @@ EAPI const int *ui_view_get_available_rotations(ui_view *view, unsigned int *cou
  *
  * @warning You should not remove a view content manually on unload status if removable content is set
  *
- * @return @c 0 on success, otherwise a negative error value.
+ * @return @c 0 on success, otherwise a negative error value
  * @retval #UI_VIEWMGR_ERROR_NONE Successful
- * @retval #UI_VIEWMGR_ERROR_INVALID_PARAMETER If @a view is invalid or @a count is less than 1 or @a rotations is invalid pointer.
+ * @retval #UI_VIEWMGR_ERROR_INVALID_PARAMETER If @a view is invalid or @a count is less than 1 or @a rotations is invalid pointer
  *
  * @see ui_view_get_removable_content()
  */
@@ -228,34 +258,50 @@ EAPI int ui_view_set_removable_content(ui_view *view, bool remove);
 /**
  * @brief Returns a state of removable content.
  * @since_tizen 3.0
+ * @remarks The specific error code can be obtained using the get_last_result() method.
+ *          Error codes are described in Exception section.
  *
  * @param[in] view An ui_view instance
  *
  * @return @c true if the view's content is removable, otherwise @c false
+ * @exception #UI_VIEWMGR_ERROR_NONE Successfully added
+ * @exception #UI_VIEWMGR_ERROR_INVALID_PARAMETER @a view is invalid
  *
  * @see ui_view_get_removable_content()
+ * @see get_last_result()
  */
 EAPI bool ui_view_get_removable_content(ui_view *view);
 
 /**
  * @brief Gets the current view's degree.
  * @since_tizen 3.0
+ * @remarks The specific error code can be obtained using the get_last_result() method.
+ *          Error codes are described in Exception section.
  *
  * @param[in] view An ui_view instance
  *
  * @return Current rotation degree, -1 if it fails to get degree information
+ * @exception #UI_VIEWMGR_ERROR_NONE Successfully added
+ * @exception #UI_VIEWMGR_ERROR_INVALID_PARAMETER @a view is invalid
+ *
+ * @see get_last_result()
  */
 EAPI int ui_view_get_degree(ui_view *view);
 
 /**
  * @brief Gets current view's orientation mode.
  * @since_tizen 3.0
+ * @remarks The specific error code can be obtained using the get_last_result() method.
+ *          Error codes are described in Exception section.
  *
  * @param[in] view An ui_view instance
  *
  * @return Current orientation mode, one of #ui_view_orientation_mode
+ * @exception #UI_VIEWMGR_ERROR_NONE Successfully added
+ * @exception #UI_VIEWMGR_ERROR_INVALID_PARAMETER @a view is invalid
  *
  * @see ui_view_orientation_mode
+ * @see get_last_result()
  */
 EAPI ui_view_orientation_mode ui_view_get_orientation_mode(ui_view *view);
 
@@ -270,9 +316,9 @@ EAPI ui_view_orientation_mode ui_view_get_orientation_mode(ui_view *view);
  * @param[in] view An ui_view instance
  * @param[in] style a transition style name
  *
- * @return @c 0 on success, otherwise a negative error value.
+ * @return @c 0 on success, otherwise a negative error value
  * @retval #UI_VIEWMGR_ERROR_NONE Successful
- * @retval #UI_VIEWMGR_ERROR_INVALID_PARAMETER @a view is invalid or @a style is not supported.
+ * @retval #UI_VIEWMGR_ERROR_INVALID_PARAMETER @a view is invalid or @a style is not supported
  *
  * @see ui_view_get_transition_style()
  */
@@ -281,44 +327,66 @@ EAPI int ui_view_set_transition_style(ui_view *view, const char *style);
 /**
  * @brief Returns a style name of this view.
  * @since_tizen 3.0
+ * @remarks The specific error code can be obtained using the get_last_result() method.
+ *          Error codes are described in Exception section.
  *
  * @param[in] view An ui_view instance
  *
  * @return style name of view
+ * @exception #UI_VIEWMGR_ERROR_NONE Successfully added
+ * @exception #UI_VIEWMGR_ERROR_INVALID_PARAMETER @a view is invalid
  *
  * @see ui_view_set_transition_style()
+ * @see get_last_result()
  */
 EAPI const char *ui_view_get_transition_style(ui_view *view);
 
 /**
  * @brief Gets a ui_menu instance.
  * @since_tizen 3.0
+ * @remarks The specific error code can be obtained using the get_last_result() method.
+ *          Error codes are described in Exception section.
  *
  * @param[in] view An ui_view instance
  *
  * @return The ui_menu that connected with given @a view
+ * @exception #UI_VIEWMGR_ERROR_NONE Successfully added
+ * @exception #UI_VIEWMGR_ERROR_INVALID_PARAMETER @a view is invalid
+ *
+ * @get_last_result()
  */
 EAPI ui_menu *ui_view_get_menu(ui_view *view);
 
 /**
  * @brief Returns a name of this view.
  * @since_tizen 3.0
+ * @remarks The specific error code can be obtained using the get_last_result() method.
+ *          Error codes are described in Exception section.
  *
  * @param[in] view An ui_view instance
  *
  * @return name of @a view
+ * @exception #UI_VIEWMGR_ERROR_NONE Successfully added
+ * @exception #UI_VIEWMGR_ERROR_INVALID_PARAMETER @a view is invalid
+ *
+ * @get_last_result()
  */
 EAPI const char *ui_view_get_name(ui_view *view);
 
 /**
  * @brief Returns a state of this view.
  * @since_tizen 3.0
+ * @remarks The specific error code can be obtained using the get_last_result() method.
+ *          Error codes are described in Exception section.
  *
  * @param[in] view An ui_view instance
  *
  * @return current state of @a view
+ * @exception #UI_VIEWMGR_ERROR_NONE Successfully added
+ * @exception #UI_VIEWMGR_ERROR_INVALID_PARAMETER @a view is invalid
  *
  * @see ui_view_state
+ * @see get_last_result()
  */
 EAPI ui_view_state ui_view_get_state(ui_view *view);
 
@@ -328,9 +396,9 @@ EAPI ui_view_state ui_view_get_state(ui_view *view);
  *
  * @param[in] view An ui_view instance
  *
- * @return @c 0 on success, otherwise a negative error value.
+ * @return @c 0 on success, otherwise a negative error value
  * @retval #UI_VIEWMGR_ERROR_NONE Successful
- * @retval #UI_VIEWMGR_ERROR_INVALID_PARAMETER @a view is invalid.
+ * @retval #UI_VIEWMGR_ERROR_INVALID_PARAMETER @a view is invalid
  *
  * @see ui_view_create()
  * @see ui_standard_view_create()
index 2d216f6..fc07562 100644 (file)
@@ -22,9 +22,9 @@ extern "C" {
  *
  * @param[in] view An ui_view to insert in the ui_viewmgr view list
  *
- * @return @c 0 on success, otherwise a negative error value.
- * @retval #UI_VIEWMGR_ERROR_INVALID_PARAMETER @a view is not valid.
- * @retval #UI_VIEWMGR_ERROR_NOT_PERMITTED @a view was already inserted.
+ * @return @c 0 on success, otherwise a negative error value
+ * @retval #UI_VIEWMGR_ERROR_INVALID_PARAMETER @a view is not valid
+ * @retval #UI_VIEWMGR_ERROR_NOT_PERMITTED @a view was already inserted
  *
  * @see ui_viewmgr_activate()
  * @see ui_viewmgr_insert_view_before()
@@ -40,10 +40,10 @@ EAPI int ui_viewmgr_push_view(ui_view *view);
  * @param[in] view An ui_view to insert in the ui_viewmgr view list
  * @param[in] before An ui_view that will be just inserted after @a view. If you pass @c NULL, @a view will be inserted at the front of the view list
  *
- * @return @c 0 on success, otherwise a negative error value.
+ * @return @c 0 on success, otherwise a negative error value
  * @retval #UI_VIEWMGR_ERROR_NONE Successful
- * @retval #UI_VIEWMGR_ERROR_NOT_PERMITTED @a view was already inserted.
- * @retval #UI_VIEWMGR_ERROR_INVALID_PARAMETER @a view is not valid.
+ * @retval #UI_VIEWMGR_ERROR_NOT_PERMITTED @a view was already inserted
+ * @retval #UI_VIEWMGR_ERROR_INVALID_PARAMETER @a view is not valid
  *
  * @see ui_viewmgr_insert_view_after()
  */
@@ -56,10 +56,10 @@ EAPI int ui_viewmgr_insert_view_before(ui_view *view, ui_view *before);
  * @param[in] view An ui_view to insert in the ui_viewmgr view list
  * @param[in] after An ui_view that will be just inserted before the @a view. If you pass @c NULL, @a view will be inserted at the end of the view list
  *
- * @return @c 0 on success, otherwise a negative error value.
+ * @return @c 0 on success, otherwise a negative error value
  * @retval #UI_VIEWMGR_ERROR_NONE Successful
- * @retval #UI_VIEWMGR_ERROR_NOT_PERMITTED @a view was already inserted.
- * @retval #UI_VIEWMGR_ERROR_INVALID_PARAMETER @a view is not valid.
+ * @retval #UI_VIEWMGR_ERROR_NOT_PERMITTED @a view was already inserted
+ * @retval #UI_VIEWMGR_ERROR_INVALID_PARAMETER @a view is not valid
  *
  * @see ui_viewmgr_insert_view_before()
  */
@@ -73,10 +73,10 @@ EAPI int ui_viewmgr_insert_view_after(ui_view *view, ui_view *after);
  * @remarks If the view is just one left, then ui_viewmgr would be deactivated automatically since the ui application might be invalid anymore. Otherwise,
  *          the application will be terminated. It's up to system configuration.
  *
- * @return @c 0 on success, otherwise a negative error value.
+ * @return @c 0 on success, otherwise a negative error value
  * @retval #UI_VIEWMGR_ERROR_NONE Successful
- * @retval #UI_VIEWMGR_ERROR_NOT_PERMITTED No more views to pop.
- * @retval #UI_VIEWMGR_ERROR_ALREADY_IN_PROGRESS On a certain profile, it may not allow to pop multiple views at the same time.
+ * @retval #UI_VIEWMGR_ERROR_NOT_PERMITTED No more views to pop
+ * @retval #UI_VIEWMGR_ERROR_ALREADY_IN_PROGRESS On a certain profile, it may not allow to pop multiple views at the same time
  *
  * @see ui_viewmgr_deactivate()
  * @see ui_viewmgr_push_view()
@@ -89,7 +89,7 @@ EAPI int ui_viewmgr_pop_view(void);
  * @remarks ui_viewmgr window and views will be shown once this function is called.
  *          Usually this should be called after applications set their all views on initialization time.
  *
- * @return @c 0 on success, otherwise a negative error value.
+ * @return @c 0 on success, otherwise a negative error value
  * @retval #UI_VIEWMGR_ERROR_NONE Successful
  * @retval #UI_VIEWMGR_ERROR_ALREADY_IN_PROGRESS Already activated
  * @retval #UI_VIEWMGR_ERROR_NOT_PERMITTED Can't be activated. (ie, view manager has zero views.)
@@ -100,7 +100,7 @@ EAPI int ui_viewmgr_activate(void);
 
 /**
  * @brief Deactivates this view manager.
- *
+ * @since_tizen 3.0
  * @remarks ui_viewmgr window and views will be hidden once this function is called.
  *          this behavior is up ui system, but usually it hides(unmap)
  *          current window in order that application go background.
@@ -124,8 +124,14 @@ EAPI Elm_Win *ui_viewmgr_get_window(void);
 /**
  * @brief Returns a last(top) view.
  * @since_tizen 3.0
+ * @remarks The specific error code can be obtained using the get_last_result() method.
+ *          Error codes are described in Exception section.
+ *
+ * @return The view which is last view of the ui_viewmgr view list. NULL on error
+ * @exception #UI_VIEWMGR_ERROR_NONE Successfully added
+ * @exception #UI_VIEWMGR_ERROR_NOT_PERMITTED @a viewmgr has no view
  *
- * @return The view which is last view of the ui_viewmgr view list
+ * @see get_last_result()
  */
 EAPI ui_view *ui_viewmgr_get_last_view(void);
 
@@ -134,14 +140,19 @@ EAPI ui_view *ui_viewmgr_get_last_view(void);
  * @since_tizen 3.0
  * @remarks You could use the index as the page numbers of the views.
  *          the index number of views are variable since the view list is variable.
+ *          The specific error code can be obtained using the get_last_result() method.
+ *          Error codes are described in Exception section.
  *
  * @param[in] idx A index of the view which you are looking for
  *
  * @return The view which index is matched with @a idx
  *         If there were no views with index @a idx, @c NULL will be returned
+ * @exception #UI_VIEWMGR_ERROR_NONE Successfully added
+ * @exception #UI_VIEWMGR_ERROR_INVALID_PARAMETER Wrong index
  *
  * @see ui_viewmgr_get_view_index()
  * @see ui_viewmgr_get_view_count()
+ * @see get_last_result()
  */
 EAPI ui_view *ui_viewmgr_get_view_by_idx(int idx);
 
@@ -149,14 +160,19 @@ EAPI ui_view *ui_viewmgr_get_view_by_idx(int idx);
  * @brief Returns a view which is matched with the @a name.
  * @since_tizen 3.0
  * @remarks Every view have their names as their own identifiers.
+ *          The specific error code can be obtained using the get_last_result() method.
+ *          Error codes are described in Exception section.
  *
  * @param[in] name The name of the view which you are looking for
  *
  * @return The view which name is matched with @a name
  *         If there were no views name matched, @c NULL will be returned
+ * @exception #UI_VIEWMGR_ERROR_NONE Successfully added
+ * @exception #UI_VIEWMGR_ERROR_INVALID_PARAMETER @a name is NULL, otherwise there is no matched name
  *
  * @see ui_view_create()
  * @see ui_standard_view_create()
+ * @see get_last_result()
  */
 EAPI ui_view *ui_viewmgr_get_view_by_name(const char *name);
 
@@ -177,7 +193,8 @@ EAPI Eo *ui_viewmgr_get_base(void);
  *
  * @param[in] view An ui_view to query the index.
  *
- * @return An index of the given @a view on success, otherwise, -1
+ * @return An index of the given @a view on success, otherwise a negative error value
+ * @retval #UI_VIEWMGR_ERROR_INVALID_PARAMETER @a view is not valid
  */
 EAPI int ui_viewmgr_get_view_index(const ui_view *view);
 
index 04e1d4c..f8448f6 100644 (file)
@@ -49,9 +49,12 @@ public:
        virtual int setContent(T content);
 
        /**
-        *  @brief This is for unsetting a content of the view.
+        *  @brief Unsets an overlay content.
         *
-        *  @return A previous content. If it wasn't, return @c nullptr.
+        *  @return A previous content. If it wasn't, return @c nullptr
+        *
+        *  @see setContent()
+        *  @see getContent()
         */
        virtual T unsetContent();
 
@@ -86,9 +89,9 @@ public:
        virtual int deactivate() = 0;
 
        /**
-        *  @brief Return the active status of overlay.
+        *  @brief Returns the active status of overlay.
         *
-        *  @return @c true if overlay is activated, @c false otherwise.
+        *  @return @c true if overlay is activated, @c false otherwise
         *
         *  @see activate()
         *  @see deactivate()
@@ -103,9 +106,12 @@ public:
        UiIfaceView *getView();
 
        /**
-        *  @brief Return a content instance of this overlay.
+        *  @brief Returns a content of overlay.
+        *
+        *  @return A content of overlay
         *
-        *  @return content of overlay.
+        *  @see setContent()
+        *  @see unsetContent()
         */
        virtual T getContent();
 
index 5092b84..9915df8 100644 (file)
@@ -42,10 +42,9 @@ class UiIfaceView : public UiIfaceRotatable
 public:
        /**
         *  @brief This is a constructor for initializing this view resources.
-        *
+        *  @remarks if you don't set a view name, you could not look up the view with it's name. @see ui_viewmgr_get_view_by_name().
+       *
         *  @param[in] name view name.
-        *
-        *  @warning if you don't set a view name, you could not look up the view with its name. @see ui_viewmgr_view_get_by_name()
         */
        explicit UiIfaceView(const char *name = nullptr);
 
@@ -111,36 +110,45 @@ public:
        virtual int setAvailableRotations(const int *rotations, unsigned int count);
 
        /**
-        *  @brief Get the array of view's available rotations.
+        *  @brief Gets the array of view's available rotations.
+        *  @remarks @c nullptr will be returned if @a count is invalid.
+        *           The specific error code can be obtained using the get_last_result() method.
+        *           Error codes are described in Exception section.
         *
-        *  @param[out] count The number of arrays of rotations.
+        *  @param[out] count The number of arrays of rotations
         *
-        *  @return The array of rotation values.
+        *  @return The array of rotation values
+        *  @exception #UI_VIEWMGR_ERROR_NONE Successfully added
+        *  @exception #UI_VIEWMGR_ERROR_INVALID_PARAMETER @a view is invalid
         *
-        *  @warning @c nullptr will be returned if @a count is invalid.
-        *
-        *  @see setAvailableRotations()
+        *  @see setAvailableRotations
+        *  @see get_last_result()
         */
        const int *getAvailableRotations(unsigned int *count);
 
        /**
-        *  @brief Return a style name of this view.
+        *  @brief Returns a style name of this view.
+        *
+        *  @return style name of view
         *
-        *  @return style name of view. A default value is "default".
+        *  @see setTransitionStyle()
         */
        const char *getTransitionStyle();
 
        /**
-        *  @brief Return a name of this view.
+        *  @brief Returns a name of this view.
         *
-        *  @return name of view. If it doesn't have, empty string will be returned.
+        *  @return name of view
         */
        const char *getName();
 
        /**
-        *  @brief Return a content instance of this view.
+        *  @brief Returns a content of this view.
         *
-        *  @return content of view. If no contents set yet, @c nullptr.
+        *  @return content of view. If no contents set yet, @c nullptr
+        *
+        *  @see setContent()
+        *  @see unsetContent()
         */
        T getContent();
 
@@ -158,30 +166,34 @@ public:
        virtual int setContent(T content);
 
        /**
-        *  @brief Unset the view content.
+        *  @brief Unsets this view content.
+        *
+        *  @param[in] view An ui_view instance
         *
-        *  @return A previous content. If it wasn't, return @c nullptr.
+        *  @return A previous content. If it wasn't, return @c nullptr
         */
        virtual T unsetContent();
 
        /**
-        *  @brief Return a state of this view.
+        *  @brief Returns a state of this view.
+        *
+        *  @return current state of view
         *
-        *  @return current state of view.
+        *  @see UiViewState
         */
        UiViewState getState();
 
        /**
-        *  @brief Return a state of removable content.
+        *  @brief Returns a state of removable content.
         *
-        *  @return true if the view's content is removable, otherwise false.
+        *  @return @c true if the view's content is removable, otherwise @c false
         */
        bool getRemovableContent();
 
        /**
-        *  @brief Return the indicator mode of this view.
+        *  @brief Returns the indicator mode of this view.
         *
-        *  @return indicator state of view.
+        *  @return indicator state of this view
         */
        UiViewIndicator getIndicator();
 
index 6773a1e..7f6e729 100644 (file)
@@ -218,6 +218,9 @@ protected:
        /**
         *  @brief Return a view which is matched with the index @a idx.
         *
+        *  @remarks The specific error code can be obtained using the get_last_result() method.
+        *           Error codes are described in Exception section.
+        *
         *  @param[in] idx A index of the view which you are looking for.
         *
         *  @return The view which index is matched with @a idx.
@@ -226,30 +229,47 @@ protected:
         *  @note You could use the index as the page numbers of the views.
         *  @warning the index number of views are variable since the view list is variable.
         *
+        *  @exception #UI_VIEWMGR_ERROR_NONE Successfully added
+        *  @exception #UI_VIEWMGR_ERROR_INVALID_PARAMETER Wrong index
+        *
         *  @see getViewIndex()
         *  @see getViewCount()
+        *  @see get_last_result()
         */
        UiIfaceView* getView(unsigned int idx);
 
        /**
         *  @brief Return a view which is matched with the @a name.
         *
+        *  @remarks The specific error code can be obtained using the get_last_result() method.
+        *           Error codes are described in Exception section.
+        *
         *  @note Every view have their names as their own identifiers.
         *
         *  @param[in] name The name of the view which you are looking for.
         *
         *  @return The view which name is matched with @a name.
         *          If there were no views name matched, @c nullptr will be returned.
+        *  @exception #UI_VIEWMGR_ERROR_NONE Successfully added
+        *  @exception #UI_VIEWMGR_ERROR_INVALID_PARAMETER @a name is nullptr, otherwise there is no matched name
         *
-        *  @see UiIfaceView::getName().
+        *  @see UiIfaceView::getName()
+        *  @see get_last_result()
         */
        UiIfaceView *getView(const char *name);
 
        /**
         *  @brief Return a last(top) view.
         *
+        *  @remarks The specific error code can be obtained using the get_last_result() method.
+        *           Error codes are described in Exception section.
+        *
         *  @return The view which is last view of the viewmgr view list.
         *          If there were no views, @c nullptr will be returned.
+        *  @exception #UI_VIEWMGR_ERROR_NONE Successfully added
+        *  @exception #UI_VIEWMGR_ERROR_NOT_PERMITTED @a viewmgr has no view
+        *
+        *  @see get_last_result()
         */
        UiIfaceView *getLastView();
 
index a540c0a..fe0b1ae 100644 (file)
@@ -335,11 +335,15 @@ int UiStandardViewImpl::unsetContent()
 Elm_Button *UiStandardViewImpl::unsetTitleLeftBtn()
 {
        Elm_Button *btn = this->_titleLeftBtn;
-       if (!btn) return nullptr;
+       if (!btn) {
+               set_last_result(UI_VIEWMGR_ERROR_NOT_PERMITTED);
+               return nullptr;
+       }
 
        Elm_Layout *layout = this->getBase();
        if (!layout) {
                LOGE("Layout is invalid! UiStandardView(%p)", this);
+               set_last_result(UI_VIEWMGR_ERROR_RESULT_OUT_OF_RANGE);
                return btn;
        }
 
@@ -349,17 +353,22 @@ Elm_Button *UiStandardViewImpl::unsetTitleLeftBtn()
        evas_object_hide(btn);
        this->_titleLeftBtn = nullptr;
 
+       set_last_result(UI_VIEWMGR_ERROR_NONE);
        return btn;
 }
 
 Elm_Button *UiStandardViewImpl::unsetTitleRightBtn()
 {
        Elm_Button *btn = this->_titleRightBtn;
-       if (!btn) return nullptr;
+       if (!btn) {
+               set_last_result(UI_VIEWMGR_ERROR_NOT_PERMITTED);
+               return nullptr;
+       }
 
        Elm_Layout *layout = this->getBase();
        if (!layout) {
                LOGE("Layout is invalid! UiStandardView(%p)", this);
+               set_last_result(UI_VIEWMGR_ERROR_RESULT_OUT_OF_RANGE);
                return btn;
        }
 
@@ -369,16 +378,21 @@ Elm_Button *UiStandardViewImpl::unsetTitleRightBtn()
        evas_object_hide(btn);
        this->_titleRightBtn = nullptr;
 
+       set_last_result(UI_VIEWMGR_ERROR_NONE);
        return btn;
 }
 
 Elm_Toolbar *UiStandardViewImpl::unsetToolbar()
 {
        Elm_Toolbar *toolbar = this->_toolbar;
-       if (!toolbar) return nullptr;
+       if (!toolbar) {
+               set_last_result(UI_VIEWMGR_ERROR_NOT_PERMITTED);
+               return nullptr;
+       }
 
        Elm_Layout *layout = this->getBase();
        if (!layout) {
+               set_last_result(UI_VIEWMGR_ERROR_RESULT_OUT_OF_RANGE);
                LOGE("Layout is invalid! UiStandardView(%p)", this);
                return toolbar;
        }
@@ -389,6 +403,7 @@ Elm_Toolbar *UiStandardViewImpl::unsetToolbar()
        evas_object_hide(toolbar);
        this->_toolbar = nullptr;
 
+       set_last_result(UI_VIEWMGR_ERROR_NONE);
        return toolbar;
 }
 
index 4eaf005..c8646c4 100644 (file)
@@ -11,6 +11,7 @@ static int validate_menu(ui_menu *menu)
        if (!menu)
        {
                LOGE("Invalid ui_menu = nullptr");
+               set_last_result(UI_VIEWMGR_ERROR_INVALID_PARAMETER);
                return UI_VIEWMGR_ERROR_INVALID_PARAMETER;
        }
        return UI_VIEWMGR_ERROR_NONE;
@@ -28,6 +29,7 @@ EAPI Elm_Ctxpopup *ui_menu_get_content(ui_menu *menu)
 {
        if (UI_VIEWMGR_ERROR_NONE != validate_menu(menu)) return nullptr;
 
+       set_last_result(UI_VIEWMGR_ERROR_NONE);
        return menu->getContent();
 }
 
@@ -35,6 +37,7 @@ EAPI Elm_Ctxpopup *ui_menu_unset_content(ui_menu *menu)
 {
        if (UI_VIEWMGR_ERROR_NONE != validate_menu(menu)) return nullptr;
 
+       set_last_result(UI_VIEWMGR_ERROR_NONE);
        return menu->unsetContent();
 }
 
@@ -58,6 +61,7 @@ EAPI bool ui_menu_get_activated(ui_menu *menu)
 {
        if (UI_VIEWMGR_ERROR_NONE != validate_menu(menu)) return nullptr;
 
+       set_last_result(UI_VIEWMGR_ERROR_NONE);
        return menu->isActivated();
 }
 
@@ -65,6 +69,7 @@ EAPI Eo *ui_menu_get_base(ui_menu *menu)
 {
        if (UI_VIEWMGR_ERROR_NONE != validate_menu(menu)) return nullptr;
 
+       set_last_result(UI_VIEWMGR_ERROR_NONE);
        return menu->getBase();
 }
 
@@ -72,6 +77,7 @@ EAPI int ui_menu_get_degree(ui_menu *menu)
 {
        if (UI_VIEWMGR_ERROR_NONE != validate_menu(menu)) return -1;
 
+       set_last_result(UI_VIEWMGR_ERROR_NONE);
        return menu->getDegree();
 }
 
@@ -79,5 +85,6 @@ EAPI ui_view *ui_menu_get_view(ui_menu *menu)
 {
        if (UI_VIEWMGR_ERROR_NONE != validate_menu(menu)) return nullptr;
 
+       set_last_result(UI_VIEWMGR_ERROR_NONE);
        return dynamic_cast<ui_view *>(menu->getView());
 }
index 2719704..60e562c 100644 (file)
@@ -11,6 +11,7 @@ static int validate_popup(ui_popup *popup)
        if (!popup)
        {
                LOGE("Invalid ui_popup = nullptr");
+               set_last_result(UI_VIEWMGR_ERROR_INVALID_PARAMETER);
                return UI_VIEWMGR_ERROR_INVALID_PARAMETER;
        }
        return UI_VIEWMGR_ERROR_NONE;
@@ -20,11 +21,20 @@ EAPI ui_popup *ui_popup_create(ui_view *view)
 {
        if (!view)
        {
-               LOGE("view is null.");
+               set_last_result(UI_VIEWMGR_ERROR_INVALID_PARAMETER);
                return nullptr;
        }
 
-       return new ui_popup(view);
+       ui_popup *popup = new ui_popup(view);
+       if (!popup)
+       {
+               LOGE("Failed to create new ui_popup instance");
+               set_last_result(UI_VIEWMGR_ERROR_OUT_OF_MEMORY);
+               return nullptr;
+       }
+
+       set_last_result(UI_VIEWMGR_ERROR_NONE);
+       return popup;
 }
 
 EAPI int ui_popup_destroy(ui_popup *popup)
@@ -48,12 +58,16 @@ EAPI int ui_popup_set_content(ui_popup *popup, Elm_Popup *content)
 EAPI Elm_Popup *ui_popup_get_content(ui_popup *popup)
 {
        if (UI_VIEWMGR_ERROR_NONE != validate_popup(popup)) return nullptr;
+
+       set_last_result(UI_VIEWMGR_ERROR_NONE);
        return popup->getContent();
 }
 
 EAPI Elm_Popup *ui_popup_unset_content(ui_popup *popup)
 {
        if (UI_VIEWMGR_ERROR_NONE != validate_popup(popup)) return nullptr;
+
+       set_last_result(UI_VIEWMGR_ERROR_NONE);
        return popup->unsetContent();
 }
 
@@ -76,23 +90,31 @@ EAPI int ui_popup_deactivate(ui_popup *popup)
 EAPI bool ui_popup_get_activated(ui_popup *popup)
 {
        if (UI_VIEWMGR_ERROR_NONE != validate_popup(popup)) return false;
+
+       set_last_result(UI_VIEWMGR_ERROR_NONE);
        return popup->isActivated();
 }
 
 EAPI Eo *ui_popup_get_base(ui_popup *popup)
 {
        if (UI_VIEWMGR_ERROR_NONE != validate_popup(popup)) return nullptr;
+
+       set_last_result(UI_VIEWMGR_ERROR_NONE);
        return popup->getBase();
 }
 
 EAPI int ui_popup_get_degree(ui_popup *popup)
 {
        if (UI_VIEWMGR_ERROR_NONE != validate_popup(popup)) return -1;
+
+       set_last_result(UI_VIEWMGR_ERROR_NONE);
        return popup->getDegree();
 }
 
 EAPI ui_view *ui_popup_get_view(ui_popup *popup)
 {
        if (UI_VIEWMGR_ERROR_NONE != validate_popup(popup)) return nullptr;
+
+       set_last_result(UI_VIEWMGR_ERROR_NONE);
        return dynamic_cast<ui_view *>(popup->getView());
 }
index f3a1e4b..1fb815f 100644 (file)
@@ -208,6 +208,7 @@ static ui_standard_view_capi *validate_view(ui_standard_view *view)
        if (!view)
        {
                LOGE("Invalid ui_standard_view = nullptr");
+               set_last_result(UI_VIEWMGR_ERROR_INVALID_PARAMETER);
                return nullptr;
        }
 
@@ -223,6 +224,16 @@ static ui_standard_view_capi *validate_view(ui_standard_view *view)
 
 EAPI ui_standard_view* ui_standard_view_create(const char *name)
 {
+       ui_standard_view *view = new ui_standard_view_capi(name);
+
+       if (!view)
+       {
+               LOGE("Failed to create new ui_standard_view instance");
+               set_last_result(UI_VIEWMGR_ERROR_OUT_OF_MEMORY);
+               return nullptr;
+       }
+
+       set_last_result(UI_VIEWMGR_ERROR_NONE);
        return new ui_standard_view_capi(name);
 }
 
@@ -261,8 +272,13 @@ EAPI int ui_standard_view_set_title_right_btn(ui_standard_view *view, Eo *title_
 EAPI Elm_Button *ui_standard_view_get_title_right_btn(ui_standard_view *view)
 {
        ui_standard_view_capi *capi_view = validate_view(view);
-       if (!capi_view) return nullptr;
+       if (!capi_view)
+       {
+               set_last_result(UI_VIEWMGR_ERROR_INVALID_PARAMETER);
+               return nullptr;
+       }
 
+       set_last_result(UI_VIEWMGR_ERROR_NONE);
        return capi_view->getTitleRightBtn();
 }
 
@@ -287,6 +303,7 @@ EAPI Elm_Button *ui_standard_view_get_title_left_btn(ui_standard_view *view)
        ui_standard_view_capi *capi_view = validate_view(view);
        if (!capi_view) return nullptr;
 
+       set_last_result(UI_VIEWMGR_ERROR_NONE);
        return capi_view->getTitleLeftBtn();
 }
 
@@ -310,6 +327,8 @@ EAPI Elm_Toolbar *ui_standard_view_get_toolbar(ui_standard_view *view)
 {
        ui_standard_view_capi *capi_view = validate_view(view);
        if (!capi_view) return nullptr;
+
+       set_last_result(UI_VIEWMGR_ERROR_NONE);
        return capi_view->getToolbar();
 }
 
@@ -317,6 +336,7 @@ EAPI Elm_Toolbar *ui_standard_view_unset_toolbar(ui_standard_view *view)
 {
        ui_standard_view_capi *capi_view = validate_view(view);
        if (!capi_view) return nullptr;
+
        return capi_view->unsetToolbar();
 }
 
index fd8a726..81097f0 100644 (file)
@@ -207,6 +207,7 @@ static int validate_view(ui_view *view)
        if (!view)
        {
                LOGE("Invalid ui_view = nullptr");
+               set_last_result(UI_VIEWMGR_ERROR_INVALID_PARAMETER);
                return UI_VIEWMGR_ERROR_INVALID_PARAMETER;
        }
        return UI_VIEWMGR_ERROR_NONE;
@@ -214,7 +215,17 @@ static int validate_view(ui_view *view)
 
 EAPI ui_view* ui_view_create(const char *name)
 {
-       return new ui_view_capi(name);
+       ui_view *view = new ui_view_capi(name);
+
+       if (!view)
+       {
+           LOGE("Failed to create new ui_view instance");
+           set_last_result(UI_VIEWMGR_ERROR_OUT_OF_MEMORY);
+           return nullptr;
+       }
+
+       set_last_result(UI_VIEWMGR_ERROR_NONE);
+       return view;
 }
 
 EAPI int ui_view_set_event_cb(ui_view *view, ui_view_event_type_e event_type, ui_view_event_cb event_cb, void *user_data)
@@ -250,6 +261,8 @@ EAPI Eo* ui_view_get_base(ui_view *view)
 EAPI Eo *ui_view_unset_content(ui_view *view)
 {
        if (UI_VIEWMGR_ERROR_NONE != validate_view(view)) return nullptr;
+
+       set_last_result(UI_VIEWMGR_ERROR_NONE);
        return view->unsetContent();
 }
 
@@ -264,6 +277,8 @@ EAPI int ui_view_set_indicator(ui_view *view, ui_view_indicator indicator)
 EAPI ui_view_indicator ui_view_get_indicator(ui_view *view)
 {
        if (UI_VIEWMGR_ERROR_NONE != validate_view(view)) return UI_VIEW_INDICATOR_UNKNOWN;
+
+       set_last_result(UI_VIEWMGR_ERROR_NONE);
        return view->getIndicator();
 }
 
@@ -280,18 +295,25 @@ EAPI int ui_view_set_removable_content(ui_view *view, bool remove)
 EAPI bool ui_view_get_removable_content(ui_view *view)
 {
        if (UI_VIEWMGR_ERROR_NONE != validate_view(view)) return false;
+
+       set_last_result(UI_VIEWMGR_ERROR_NONE);
        return view->getRemovableContent();
 }
 
 EAPI int ui_view_get_degree(ui_view *view)
 {
        if (UI_VIEWMGR_ERROR_NONE != validate_view(view)) return -1;
+
+       set_last_result(UI_VIEWMGR_ERROR_NONE);
        return view->getDegree();
 }
 
 EAPI ui_view_orientation_mode ui_view_get_orientation_mode(ui_view *view)
 {
        if (UI_VIEWMGR_ERROR_NONE != validate_view(view)) return UI_VIEW_ORIENTATION_MODE_UNKNOWN;
+
+
+       set_last_result(UI_VIEWMGR_ERROR_NONE);
        return view->getOrientationMode();
 }
 
@@ -306,6 +328,8 @@ EAPI int ui_view_set_available_rotations(ui_view *view, const int *rotations, un
 EAPI const int *ui_view_get_available_rotations(ui_view *view, unsigned int *count)
 {
        if (UI_VIEWMGR_ERROR_NONE != validate_view(view)) return false;
+
+       set_last_result(UI_VIEWMGR_ERROR_NONE);
        return view->getAvailableRotations(count);
 }
 
@@ -320,30 +344,40 @@ EAPI int ui_view_set_transition_style(ui_view *view, const char *style)
 EAPI const char *ui_view_get_transition_style(ui_view *view)
 {
        if (UI_VIEWMGR_ERROR_NONE != validate_view(view)) return nullptr;
+
+       set_last_result(UI_VIEWMGR_ERROR_NONE);
        return view->getTransitionStyle();
 }
 
 EAPI ui_menu *ui_view_get_menu(ui_view *view)
 {
        if (UI_VIEWMGR_ERROR_NONE != validate_view(view)) return nullptr;
+
+       set_last_result(UI_VIEWMGR_ERROR_NONE);
        return const_cast<ui_menu*>(view->getMenu());
 }
 
 EAPI const char *ui_view_get_name(ui_view *view)
 {
        if (UI_VIEWMGR_ERROR_NONE != validate_view(view)) return nullptr;
+
+       set_last_result(UI_VIEWMGR_ERROR_NONE);
        return view->getName();
 }
 
 EAPI ui_view_state ui_view_get_state(ui_view *view)
 {
        if (UI_VIEWMGR_ERROR_NONE != validate_view(view)) return UI_VIEW_STATE_UNKNOWN;
+
+       set_last_result(UI_VIEWMGR_ERROR_NONE);
        return view->getState();
 }
 
 EAPI Eo *ui_view_get_content(ui_view *view)
 {
        if (UI_VIEWMGR_ERROR_NONE != validate_view(view)) return nullptr;
+
+       set_last_result(UI_VIEWMGR_ERROR_NONE);
        return view->getContent();
 }
 
@@ -367,5 +401,7 @@ EAPI int ui_view_set_content(ui_view *view, Eo *content)
 EAPI const char *ui_view_get_type(ui_view *view)
 {
        if (UI_VIEWMGR_ERROR_NONE != validate_view(view)) return false;
+
+       set_last_result(UI_VIEWMGR_ERROR_NONE);
        return dynamic_cast<ui_common_view_capi *>(view)->type;
 }
index 79d74ad..0493c2c 100644 (file)
@@ -79,7 +79,7 @@ EAPI int ui_viewmgr_get_view_index(const ui_view *view)
        if (!view)
        {
                LOGE("Invalid Parameter view = %p", view);
-               return -1;
+               return UI_VIEWMGR_ERROR_INVALID_PARAMETER;
        }
 
        return UI_VIEWMGR->getViewIndex(view);
index 2ea5ab0..e11b89e 100644 (file)
@@ -228,10 +228,14 @@ int UiIfaceViewImpl::setAvailableRotations(const int *rotations, unsigned int co
 
 const int *UiIfaceViewImpl::getAvailableRotations(unsigned int *count)
 {
-       if (!count) return nullptr;
+       if (!count) {
+               set_last_result(UI_VIEWMGR_ERROR_INVALID_PARAMETER);
+               return nullptr;
+       }
 
        static int rots[MAX_NUM_OF_AVAILABLE_ROTATIONS] = {0, 90, 180, 270};
 
+       set_last_result(UI_VIEWMGR_ERROR_NONE);
        if (this->_rotationCount > 0) {
                *count = this->_rotationCount;
                return this->_rotations;
index d68771a..0bfee94 100644 (file)
@@ -348,12 +348,14 @@ UiIfaceView *UiIfaceViewmgrImpl::getView(unsigned int idx)
 {
        if (idx >= this->_viewList.size()) {
                LOGE("Invalid idx(%d)! =? (idx range: %d ~ %d)", idx, 0, this->_viewList.size() - 1);
+               set_last_result(UI_VIEWMGR_ERROR_INVALID_PARAMETER);
                return nullptr;
        }
 
        auto it = this->_viewList.begin();
        advance(it, idx);
 
+       set_last_result(UI_VIEWMGR_ERROR_NONE);
        return *it;
 }
 
@@ -366,13 +368,20 @@ int UiIfaceViewmgrImpl::getViewIndex(const UiIfaceView *view)
                ++idx;
        }
 
-       return -1;
+       return UI_VIEWMGR_ERROR_INVALID_PARAMETER;
 }
 
 UiIfaceView *UiIfaceViewmgrImpl::getLastView()
 {
        int cnt = this->getViewCount();
 
+       if (cnt == 0)
+       {
+               set_last_result(UI_VIEWMGR_ERROR_NOT_PERMITTED);
+               return nullptr;
+       }
+
+       set_last_result(UI_VIEWMGR_ERROR_NONE);
        return this->getView(cnt - 1);
 }
 
@@ -411,7 +420,11 @@ int UiIfaceViewmgrImpl::deactivate()
 
 UiIfaceView *UiIfaceViewmgrImpl::getView(const char *name)
 {
-       if (!name) return nullptr;
+       if (!name)
+       {
+               set_last_result(UI_VIEWMGR_ERROR_INVALID_PARAMETER);
+               return nullptr;
+       }
        int nameLen = strlen(name);
 
        for (auto v : this->_viewList) {
@@ -421,10 +434,12 @@ UiIfaceView *UiIfaceViewmgrImpl::getView(const char *name)
 
                //Got you!
                if ((viewNameLen == nameLen) && !strcmp(name, viewName)) {
+                       set_last_result(UI_VIEWMGR_ERROR_NONE);
                        return v;
                }
        }
 
+       set_last_result(UI_VIEWMGR_ERROR_INVALID_PARAMETER);
        return nullptr;
 }