viewmgr: interface renaming. 72/60172/1
authorWoochan Lee <wc0917.lee@samsung.com>
Wed, 24 Feb 2016 04:08:42 +0000 (13:08 +0900)
committerWoochan Lee <wc0917.lee@samsung.com>
Wed, 24 Feb 2016 04:08:42 +0000 (13:08 +0900)
ui_viewmgr_interface     ->   ui_iface_viewmgr
ui_view_interface        ->   ui_iface_view
ui_controller_interface  ->   ui_iface_controller

Change-Id: I0e9265dee6fc7f6f259dcffbac13a06f52f36c5f

15 files changed:
CMakeLists.txt
src/efl/mobile/ui_basic_view.cpp
src/efl/ui_controller.cpp
src/efl/ui_controller.h
src/efl/ui_view.cpp
src/efl/ui_view.h
src/efl/ui_viewmgr.cpp
src/efl/ui_viewmgr.h
src/interface/ui_iface_controller.cpp [moved from src/interface/ui_controller_interface.cpp with 92% similarity]
src/interface/ui_iface_controller.h [moved from src/interface/ui_controller_interface.h with 93% similarity]
src/interface/ui_iface_view.cpp [moved from src/interface/ui_view_interface.cpp with 70% similarity]
src/interface/ui_iface_view.h [moved from src/interface/ui_view_interface.h with 76% similarity]
src/interface/ui_iface_viewmgr.cpp [moved from src/interface/ui_viewmgr_interface.cpp with 65% similarity]
src/interface/ui_iface_viewmgr.h [moved from src/interface/ui_viewmgr_interface.h with 90% similarity]
src/interface/ui_viewmanager_interface.h

index 26c7143..f85c42d 100644 (file)
@@ -3,9 +3,9 @@ PROJECT(ui-viewmgr)
 SET(PACKAGE org.tizen.ui-viewmgr)
 
 SET(SRCS
-       src/interface/ui_controller_interface.cpp
-       src/interface/ui_view_interface.cpp
-       src/interface/ui_viewmgr_interface.cpp
+       src/interface/ui_iface_controller.cpp
+       src/interface/ui_iface_view.cpp
+       src/interface/ui_iface_viewmgr.cpp
        src/efl/ui_controller.cpp
        src/efl/ui_view.cpp
        src/efl/ui_viewmgr.cpp
index f1c2c13..fdabae2 100644 (file)
@@ -69,7 +69,7 @@ bool ui_basic_view::create_layout()
        }
 
        //Set software back key, if it's needed
-       ui_viewmgr *viewmgr = dynamic_cast<ui_viewmgr *>(ui_view_interface::get_viewmgr());
+       ui_viewmgr *viewmgr = dynamic_cast<ui_viewmgr *>(ui_iface_view::get_viewmgr());
        if (viewmgr->need_soft_key())
        {
                Evas_Object *prev_btn = elm_button_add(layout);
index dfb9f36..1b06cc0 100644 (file)
@@ -21,7 +21,7 @@ using namespace viewmgr;
 
 ui_view * ui_controller::get_view()
 {
-       ui_view_interface *view = ui_controller_interface::get_view();
+       ui_iface_view *view = ui_iface_controller::get_view();
        if (!view) return NULL;
        return dynamic_cast<ui_view *>(view);
 }
index cbd90a4..2828c2e 100644 (file)
@@ -29,7 +29,7 @@ namespace efl_viewmgr
  *
  *  @brief UI Controller. This is a class for handling of life-cycle events from user side.
  */
-class ui_controller: public viewmgr::ui_controller_interface
+class ui_controller: public viewmgr::ui_iface_controller
 {
 public:
        ///Destructor.
index ae35ceb..b572a04 100644 (file)
@@ -20,7 +20,7 @@ using namespace efl_viewmgr;
 using namespace viewmgr;
 
 ui_view::ui_view(ui_controller *controller, const char *name, const char *style)
-               : ui_view_interface(controller, name, style)
+               : ui_iface_view(controller, name, style)
 {
 }
 
@@ -30,13 +30,13 @@ ui_view::~ui_view()
 
 Evas_Object *ui_view::set_content(Evas_Object *content)
 {
-       T pcontent = ui_view_interface::set_content(CONVERT_TO_T(content));
+       T pcontent = ui_iface_view::set_content(CONVERT_TO_T(content));
        return static_cast<Evas_Object *>(pcontent);
 }
 
 Evas_Object *ui_view::get_base()
 {
-       ui_viewmgr *viewmgr = dynamic_cast<ui_viewmgr *>(ui_view_interface::get_viewmgr());
+       ui_viewmgr *viewmgr = dynamic_cast<ui_viewmgr *>(ui_iface_view::get_viewmgr());
        if (!viewmgr)
        {
                return NULL;
@@ -60,7 +60,7 @@ void ui_view::set_indicator(ui_view_indicator indicator)
 {
        if (this->get_indicator() == indicator) return;
 
-       ui_view_interface::set_indicator(indicator);
+       ui_iface_view::set_indicator(indicator);
 
        ui_viewmgr *viewmgr = dynamic_cast<ui_viewmgr *>(this->get_viewmgr());
 
index 2f94c69..ab19882 100644 (file)
@@ -36,10 +36,10 @@ class ui_controller;
  *         UI View may have it's own show/hide transition styles. That means, it's available that views have different show/hide effects on demands.
  *         It's not mandatory but view should describe the transitions in this class.
  *
- *  @warning When the transitions are finished, the view must to call ui_viewmgr_interface :: _push_finished(), ui_viewmgr_interface :: _pop_finished() in order that
- *           The ui_viewmgr_interface keeps the view states exactly.
+ *  @warning When the transitions are finished, the view must to call ui_iface_viewmgr :: _push_finished(), ui_iface_viewmgr :: _pop_finished() in order that
+ *           The ui_iface_viewmgr keeps the view states exactly.
  */
-class ui_view: public viewmgr::ui_view_interface
+class ui_view: public viewmgr::ui_iface_view
 {
        friend class ui_viewmgr;
 
index 62b163c..6fe416d 100644 (file)
@@ -80,7 +80,7 @@ bool ui_viewmgr::create_base_layout(Evas_Object *conform)
 }
 
 ui_viewmgr::ui_viewmgr(const char *pkg, ui_key_listener *key_listener)
-               : ui_viewmgr_interface(), key_listener(key_listener)
+               : ui_iface_viewmgr(), key_listener(key_listener)
 {
        if (!pkg)
        {
@@ -150,7 +150,7 @@ ui_viewmgr::~ui_viewmgr()
 
 bool ui_viewmgr::activate()
 {
-       ui_viewmgr_interface::activate();
+       ui_iface_viewmgr::activate();
 
        elm_object_part_content_unset(this->get_base(), "elm.swallow.content");
 
@@ -177,7 +177,7 @@ bool ui_viewmgr::activate()
 
 bool ui_viewmgr::deactivate()
 {
-       ui_viewmgr_interface::deactivate();
+       ui_iface_viewmgr::deactivate();
 
        //FIXME: based on the profile, we should app to go behind or terminate.
        if (true)
@@ -198,7 +198,7 @@ bool ui_viewmgr::deactivate()
 bool ui_viewmgr::pop_view()
 {
        if (this->get_view_count() == 1) this->deactivate();
-       else if(!ui_viewmgr_interface::pop_view()) return false;
+       else if(!ui_iface_viewmgr::pop_view()) return false;
 
        ui_view *view = dynamic_cast<ui_view *>(this->get_last_view());
 
@@ -220,7 +220,7 @@ bool ui_viewmgr::pop_view()
 
 ui_view * ui_viewmgr::push_view(ui_view *view)
 {
-       ui_viewmgr_interface::push_view(view);
+       ui_iface_viewmgr::push_view(view);
 
        //Don't prepare yet if viewmgr is not activated.
        if (!this->is_activated()) return view;
@@ -245,5 +245,5 @@ ui_view * ui_viewmgr::push_view(ui_view *view)
 
 ui_view *ui_viewmgr::get_last_view()
 {
-   return dynamic_cast<ui_view *>(ui_viewmgr_interface::get_last_view());
+   return dynamic_cast<ui_view *>(ui_iface_viewmgr::get_last_view());
 }
index 78fcf04..61c7070 100644 (file)
@@ -37,7 +37,7 @@ class ui_view;
  *
  *  @warning viewmgr will remove all containing views when it's destroyed.
  */
-class ui_viewmgr: public viewmgr::ui_viewmgr_interface
+class ui_viewmgr: public viewmgr::ui_iface_viewmgr
 {
        friend class ui_view;
 
similarity index 92%
rename from src/interface/ui_controller_interface.cpp
rename to src/interface/ui_iface_controller.cpp
index c9a952b..854231f 100644 (file)
@@ -18,7 +18,7 @@
 
 using namespace viewmgr;
 
-void ui_controller_interface::set_view(ui_view_interface *view)
+void ui_iface_controller::set_view(ui_iface_view *view)
 {
        if (this->view)
        {
similarity index 93%
rename from src/interface/ui_controller_interface.h
rename to src/interface/ui_iface_controller.h
index cfed302..3ed5b3a 100644 (file)
 
 namespace viewmgr {
 
-class ui_view_interface;
+class ui_iface_view;
 
 /**
- *  @class ui_controller_interface.
+ *  @class ui_iface_controller.
  *
  *  @ingroup viewmgr
  *
  *  @brief UI Controller Interface. This interface is designed for handling of life-cycle events from user side.
  */
-class ui_controller_interface
+class ui_iface_controller
 {
-       friend class ui_view_interface;
+       friend class ui_iface_view;
 
 private:
-       ui_view_interface *view;
+       ui_iface_view *view;
 
-       void set_view(ui_view_interface *view);
+       void set_view(ui_iface_view *view);
 
 protected:
        /**
@@ -48,20 +48,20 @@ protected:
         *
         *  @see set_view()
         */
-       ui_view_interface *get_view()
+       ui_iface_view *get_view()
        {
                return this->view;
        }
 
 public:
        ///Constructor.
-       ui_controller_interface() :
+       ui_iface_controller() :
                        view(NULL)
        {
        }
 
        ///Destructor.
-       virtual ~ui_controller_interface()
+       virtual ~ui_iface_controller()
        {
        }
 
similarity index 70%
rename from src/interface/ui_view_interface.cpp
rename to src/interface/ui_iface_view.cpp
index f411ce6..07382bb 100644 (file)
 
 using namespace viewmgr;
 
-void ui_view_interface::set_event_block(bool block)
+void ui_iface_view::set_event_block(bool block)
 {
        this->event_block = block;
 }
 
-void ui_view_interface::load()
+void ui_iface_view::load()
 {
        this->state = UI_VIEW_STATE_LOAD;
        if (this->content) return;
@@ -31,7 +31,7 @@ void ui_view_interface::load()
        this->controller->load();
 }
 
-void ui_view_interface::unload()
+void ui_iface_view::unload()
 {
        this->state = UI_VIEW_STATE_UNLOAD;
        if (this->get_removable_content())
@@ -44,21 +44,21 @@ void ui_view_interface::unload()
        this->controller->unload();
 }
 
-void ui_view_interface::active()
+void ui_iface_view::active()
 {
        this->state = UI_VIEW_STATE_ACTIVE;
        if (!this->controller) return;
        this->controller->active();
 }
 
-void ui_view_interface::inactive()
+void ui_iface_view::inactive()
 {
        this->state = UI_VIEW_STATE_INACTIVE;
        if (!this->controller) return;
        this->controller->inactive();
 }
 
-void ui_view_interface::pause()
+void ui_iface_view::pause()
 {
        this->state = UI_VIEW_STATE_PAUSE;
        if (!this->content) return;
@@ -67,7 +67,7 @@ void ui_view_interface::pause()
        this->controller->pause();
 }
 
-void ui_view_interface::resume()
+void ui_iface_view::resume()
 {
        this->state = UI_VIEW_STATE_ACTIVE;
        if (state != UI_VIEW_STATE_PAUSE) return;
@@ -76,13 +76,13 @@ void ui_view_interface::resume()
        this->controller->resume();
 }
 
-void ui_view_interface::destroy()
+void ui_iface_view::destroy()
 {
        if (!this->controller) return;
        this->controller->destroy();
 }
 
-ui_view_interface::ui_view_interface(T content, ui_controller_interface *controller, const char *name, const char *style)
+ui_iface_view::ui_iface_view(T content, ui_iface_controller *controller, const char *name, const char *style)
                : content(content), controller(controller), name(string(name ? name : "")), style(string(style ? style : "")), viewmgr(NULL), state(UI_VIEW_STATE_LOAD),
                  indicator(UI_VIEW_INDICATOR_DEFAULT), event_block(false), removable_content(true)
 {
@@ -91,60 +91,60 @@ ui_view_interface::ui_view_interface(T content, ui_controller_interface *control
        controller->set_view(this);
 }
 
-ui_view_interface::ui_view_interface(ui_controller_interface *controller, const char *name, const char *style)
-               : ui_view_interface(NULL, controller, name, style)
+ui_iface_view::ui_iface_view(ui_iface_controller *controller, const char *name, const char *style)
+               : ui_iface_view(NULL, controller, name, style)
 {
        this->state = UI_VIEW_STATE_UNLOAD;
 }
 
-ui_view_interface::ui_view_interface(const char *name)
-               : ui_view_interface(NULL, name)
+ui_iface_view::ui_iface_view(const char *name)
+               : ui_iface_view(NULL, name)
 {
 
 }
 
-ui_view_interface::~ui_view_interface()
+ui_iface_view::~ui_iface_view()
 {
        this->viewmgr->remove_view(this);
        if (this->controller) delete (this->controller);
 }
 
-ui_controller_interface* ui_view_interface::set_controller(ui_controller_interface *controller)
+ui_iface_controller* ui_iface_view::set_controller(ui_iface_controller *controller)
 {
-       ui_controller_interface *prev_controller = this->controller;
+       ui_iface_controller *prev_controller = this->controller;
        this->controller = controller;
        if (controller) controller->set_view(this);
        if (prev_controller) prev_controller->set_view(NULL);
        return prev_controller;
 }
 
-T ui_view_interface::set_content(T content)
+T ui_iface_view::set_content(T content)
 {
        T prev = this->content;
        this->content = content;
        return prev;
 }
 
-bool ui_view_interface::set_style(const char *style)
+bool ui_iface_view::set_style(const char *style)
 {
        this->style.assign(style);
        return true;
 }
 
-bool ui_view_interface::set_name(const char *name)
+bool ui_iface_view::set_name(const char *name)
 {
        this->name.assign(name);
        return true;
 }
 
-void ui_view_interface::set_removable_content(bool removable)
+void ui_iface_view::set_removable_content(bool removable)
 {
        this->removable_content = removable;
 
        //FIXME: If this api is called on unload state? should we remove content right now?
 }
 
-void ui_view_interface::set_indicator(ui_view_indicator indicator)
+void ui_iface_view::set_indicator(ui_view_indicator indicator)
 {
        this->indicator = indicator;
 }
similarity index 76%
rename from src/interface/ui_view_interface.h
rename to src/interface/ui_iface_view.h
index 57950c2..6968f03 100644 (file)
@@ -25,11 +25,11 @@ typedef void* T;
 
 namespace viewmgr {
 
-class ui_viewmgr_interface;
-class ui_controller_interface;
+class ui_iface_viewmgr;
+class ui_iface_controller;
 
 /**
- *  @class ui_view_interface
+ *  @class ui_iface_view
  *
  *  @ingroup viewmgr
  *
@@ -37,13 +37,13 @@ class ui_controller_interface;
  *         UI View may have it's own show/hide transition styles. That means, it's available that views have different show/hide effects on demands.
  *         It's not mandatory but view should describe the transitions in this class.
  *
- *  @warning When the transitions are finished, the view must to call ui_viewmgr_interface :: _push_finished(), ui_viewmgr_interface :: _pop_finished() in order that
- *           The ui_viewmgr_interface keeps the view states exactly.
+ *  @warning When the transitions are finished, the view must to call ui_iface_viewmgr :: _push_finished(), ui_iface_viewmgr :: _pop_finished() in order that
+ *           The ui_iface_viewmgr keeps the view states exactly.
  */
-class ui_view_interface
+class ui_iface_view
 {
-       friend class ui_viewmgr_interface;
-       friend class ui_controller_interface;
+       friend class ui_iface_viewmgr;
+       friend class ui_iface_controller;
 
 private:
        /// View state definition
@@ -58,10 +58,10 @@ private:
        };
 
        T content;                              ///< A content instance for a screen as a view.
-       ui_controller_interface *controller;    ///< View life-cycle controller interface.
+       ui_iface_controller *controller;    ///< View life-cycle controller interface.
        string name;                            ///< View name.
        string style;                           ///< View style name.
-       ui_viewmgr_interface *viewmgr;          ///< Viewmgr which this view belongs to.
+       ui_iface_viewmgr *viewmgr;          ///< Viewmgr which this view belongs to.
        ui_view_state state;                    ///< View state.
        ui_view_indicator indicator;            ///< View indicator mode.
        bool event_block;                       ///< State of event block.
@@ -72,7 +72,7 @@ protected:
        /** @brief toggle event block.
         *
         *  @note This interface is designed for toggling touch event on view transition.
-        *        ui_viewmgr_interface will call this interface for notifying event blocking toggling on transition time.
+        *        ui_iface_viewmgr will call this interface for notifying event blocking toggling on transition time.
         *
         *  @param block @c true, when blocking is enabled, otherwise @c false.
         */
@@ -80,57 +80,57 @@ protected:
 
        /** @brief view load state.
         *
-        *  @note this state will be triggered by ui_viewmgr_interface.
+        *  @note this state will be triggered by ui_iface_viewmgr.
         *
-        *  @see ui_controller_interface for this state in detail.
+        *  @see ui_iface_controller for this state in detail.
         */
        virtual void load();
 
        /** @brief view unload state.
         *
-        *  @note this state will be triggered by ui_viewmgr_interface.
+        *  @note this state will be triggered by ui_iface_viewmgr.
         *
-        *  @see ui_controller_interface for this state in detail.
+        *  @see ui_iface_controller for this state in detail.
         */
        virtual void unload();
 
        /** @brief view active state.
         *
-        *  @note this state will be triggered by ui_viewmgr_interface.
+        *  @note this state will be triggered by ui_iface_viewmgr.
         *
-        *  @see ui_controller_interface for this state in detail.
+        *  @see ui_iface_controller for this state in detail.
         */
        virtual void active();
 
        /** @brief view inactive state.
         *
-        *  @note this state will be triggered by ui_viewmgr_interface.
+        *  @note this state will be triggered by ui_iface_viewmgr.
         *
-        *  @see ui_controller_interface for this state in detail.
+        *  @see ui_iface_controller for this state in detail.
         */
        virtual void inactive();
 
        /** @brief view pause state.
         *
-        *  @note this state will be triggered by ui_viewmgr_interface.
+        *  @note this state will be triggered by ui_iface_viewmgr.
         *
-        *  @see ui_controller_interface for this state in detail.
+        *  @see ui_iface_controller for this state in detail.
         */
        virtual void pause();
 
        /** @brief view resume state.
         *
-        *  @note this state will be triggered by ui_viewmgr_interface.
+        *  @note this state will be triggered by ui_iface_viewmgr.
         *
-        *  @see ui_controller_interface for this state in detail.
+        *  @see ui_iface_controller for this state in detail.
         */
        virtual void resume();
 
        /** @brief view destroy state.
         *
-        *  @note this state will be triggered by ui_viewmgr_interface.
+        *  @note this state will be triggered by ui_iface_viewmgr.
         *
-        *  @see ui_controller_interface for this state in detail.
+        *  @see ui_iface_controller for this state in detail.
         */
        virtual void destroy();
 
@@ -147,14 +147,14 @@ protected:
        }
 
        /// Return a controller of this view.
-       ui_controller_interface* get_controller()
+       ui_iface_controller* get_controller()
        {
                return this->controller;
        }
 
        /** @brief Return a viewmgr which this view is belonging to.
         */
-       ui_viewmgr_interface *get_viewmgr()
+       ui_iface_viewmgr *get_viewmgr()
        {
                return this->viewmgr;
        }
@@ -162,13 +162,13 @@ protected:
        /** @brief This is for replacing or setting a controller of the view.
         *
         *  @return A previous controller. If it wasn't, the return value will be @c NULL.
-        *  @note this state will be triggered by ui_viewmgr_interface.
+        *  @note this state will be triggered by ui_iface_viewmgr.
         *  @param controller a new controller. It allows @c NULL for canceling the previous controller.
         *
-        *  @warning Be aware deletion of controller passed here will be taken cover by ui_view_interface.
-        *           If you want to keep the controller for any reasons, please unset it using set_controller() before ui_view_interface is deleted.
+        *  @warning Be aware deletion of controller passed here will be taken cover by ui_iface_view.
+        *           If you want to keep the controller for any reasons, please unset it using set_controller() before ui_iface_view is deleted.
         */
-       ui_controller_interface* set_controller(ui_controller_interface *controller);
+       ui_iface_controller* set_controller(ui_iface_controller *controller);
 
 public:
        /** @brief This is a constructor for initializing this view resources.
@@ -177,17 +177,17 @@ public:
         *  @param controller view life-cycle controller interface.
         *  @param name view name.
         *
-        *  @warning Be aware the deletion of controller passed here will be covered by ui_view_interface.
-        *           If you want to keep it for any reasons, please unset it using set_controller() before ui_view_interface is deleted.
+        *  @warning Be aware the deletion of controller passed here will be covered by ui_iface_view.
+        *           If you want to keep it for any reasons, please unset it using set_controller() before ui_iface_view is deleted.
         */
-       ui_view_interface(T content, ui_controller_interface *controller, const char *name, const char *style = NULL);
+       ui_iface_view(T content, ui_iface_controller *controller, const char *name, const char *style = NULL);
        ///Constructor for initializing with controller.
-       ui_view_interface(ui_controller_interface *controller, const char *name = NULL, const char *style = NULL);
+       ui_iface_view(ui_iface_controller *controller, const char *name = NULL, const char *style = NULL);
        ///Constructor for initializing with name.
-       ui_view_interface(const char *name = NULL);
+       ui_iface_view(const char *name = NULL);
 
        ///Destructor for terminating view.
-       virtual ~ui_view_interface();
+       virtual ~ui_iface_view();
 
        /** @brief This is for replacing or setting a content of the view.
         *
similarity index 65%
rename from src/interface/ui_viewmgr_interface.cpp
rename to src/interface/ui_iface_viewmgr.cpp
index 18a4003..f7b8ba6 100644 (file)
 using namespace viewmgr;
 
 //FIXME: Read system profile to decide whether support software key or not.
-bool ui_viewmgr_interface::soft_key = true;
+bool ui_iface_viewmgr::soft_key = true;
 //FIXME: Read system profile to decide whether support event block or not.
-bool ui_viewmgr_interface::event_block = true;
+bool ui_iface_viewmgr::event_block = true;
 
-bool ui_viewmgr_interface::need_soft_key()
+bool ui_iface_viewmgr::need_soft_key()
 {
-       return ui_viewmgr_interface::soft_key;
+       return ui_iface_viewmgr::soft_key;
 }
 
-bool ui_viewmgr_interface::connect_view(ui_view_interface *view)
+bool ui_iface_viewmgr::connect_view(ui_iface_view *view)
 {
        if (view->viewmgr)
        {
@@ -40,23 +40,23 @@ bool ui_viewmgr_interface::connect_view(ui_view_interface *view)
        return true;
 }
 
-bool ui_viewmgr_interface::disconnect_view(ui_view_interface *view)
+bool ui_iface_viewmgr::disconnect_view(ui_iface_view *view)
 {
        if (!view->viewmgr) return false;
        view->viewmgr = NULL;
        return true;
 }
 
-void ui_viewmgr_interface::set_event_block(ui_view_interface *view, bool block)
+void ui_iface_viewmgr::set_event_block(ui_iface_view *view, bool block)
 {
 
-       if (!ui_viewmgr_interface::event_block) return;
+       if (!ui_iface_viewmgr::event_block) return;
        view->set_event_block(block);
 }
 
-bool ui_viewmgr_interface::push_view_finished(ui_view_interface *view)
+bool ui_iface_viewmgr::push_view_finished(ui_iface_view *view)
 {
-       ui_view_interface *last = this->view_list.back();
+       ui_iface_view *last = this->view_list.back();
 
        //The previous view has been pushed. This should be unload.
        if (last != view)
@@ -72,9 +72,9 @@ bool ui_viewmgr_interface::push_view_finished(ui_view_interface *view)
        return true;
 }
 
-bool ui_viewmgr_interface::pop_view_finished(ui_view_interface *view)
+bool ui_iface_viewmgr::pop_view_finished(ui_iface_view *view)
 {
-       ui_view_interface *last = this->view_list.back();
+       ui_iface_view *last = this->view_list.back();
 
        //This view has been popped. It should be destroyed.
        if (last == view)
@@ -92,17 +92,17 @@ bool ui_viewmgr_interface::pop_view_finished(ui_view_interface *view)
        return true;
 }
 
-ui_viewmgr_interface::ui_viewmgr_interface()
+ui_iface_viewmgr::ui_iface_viewmgr()
                : activated(false)
 {
 }
 
-ui_viewmgr_interface::~ui_viewmgr_interface()
+ui_iface_viewmgr::~ui_iface_viewmgr()
 {
        //Terminate views
-       for (typename std::list<ui_view_interface*>::reverse_iterator it = this->view_list.rbegin(); it != this->view_list.rend(); it++)
+       for (typename std::list<ui_iface_view*>::reverse_iterator it = this->view_list.rbegin(); it != this->view_list.rend(); it++)
        {
-               ui_view_interface *view = *it;
+               ui_iface_view *view = *it;
                view->inactive();
                view->unload();
                view->destroy();
@@ -113,8 +113,8 @@ ui_viewmgr_interface::~ui_viewmgr_interface()
        ui_app_exit();
 }
 
-ui_view_interface *
-ui_viewmgr_interface::push_view(ui_view_interface *view)
+ui_iface_view *
+ui_iface_viewmgr::push_view(ui_iface_view *view)
 {
        if (!view)
        {
@@ -128,7 +128,7 @@ ui_viewmgr_interface::push_view(ui_view_interface *view)
                return NULL;
        }
 
-       ui_view_interface *pview;
+       ui_iface_view *pview;
 
        //Previous view
        if (this->view_list.size())
@@ -154,7 +154,7 @@ ui_viewmgr_interface::push_view(ui_view_interface *view)
        return view;
 }
 
-bool ui_viewmgr_interface::pop_view()
+bool ui_iface_viewmgr::pop_view()
 {
        //No more view? destroy viewmgr?
        if (this->get_view_count() == 0)
@@ -166,7 +166,7 @@ bool ui_viewmgr_interface::pop_view()
        if (this->get_view_count() == 1)
        {
                //destroy viewmgr?
-               ui_view_interface *view = this->view_list.back();
+               ui_iface_view *view = this->view_list.back();
                view->inactive();
                view->unload();
                view->destroy();
@@ -176,7 +176,7 @@ bool ui_viewmgr_interface::pop_view()
        }
 
        //last page to be popped.
-       ui_view_interface *view = this->view_list.back();
+       ui_iface_view *view = this->view_list.back();
        view->inactive();
        this->set_event_block(view, true);
 
@@ -184,7 +184,7 @@ bool ui_viewmgr_interface::pop_view()
        //Make this getter method? or define instance?
        //previous page to be current active.
        auto nx = std::prev(this->view_list.end(), 2);
-       ui_view_interface *pview = *nx;
+       ui_iface_view *pview = *nx;
        pview->load();
        pview->inactive();
        this->set_event_block(pview, true);
@@ -199,19 +199,19 @@ bool ui_viewmgr_interface::pop_view()
        return true;
 }
 
-bool ui_viewmgr_interface::insert_view_before(ui_view_interface *view, ui_view_interface *before)
+bool ui_iface_viewmgr::insert_view_before(ui_iface_view *view, ui_iface_view *before)
 {
        //TODO: ...
        return true;
 }
 
-bool ui_viewmgr_interface::insert_view_after(ui_view_interface *view, ui_view_interface *after)
+bool ui_iface_viewmgr::insert_view_after(ui_iface_view *view, ui_iface_view *after)
 {
        //TODO: ...
        return true;
 }
 
-bool ui_viewmgr_interface::remove_view(ui_view_interface *view)
+bool ui_iface_viewmgr::remove_view(ui_iface_view *view)
 {
        this->view_list.remove(view);
        this->disconnect_view(view);
@@ -220,24 +220,24 @@ bool ui_viewmgr_interface::remove_view(ui_view_interface *view)
        return true;
 }
 
-ui_view_interface*
-ui_viewmgr_interface::get_view(unsigned int idx)
+ui_iface_view*
+ui_iface_viewmgr::get_view(unsigned int idx)
 {
        if (idx < 0 || idx >= this->view_list.size())
        {
                LOGE("Invalid idx(%d)! =? (idx range: %d ~ %d)", idx, 0, this->view_list.size() - 1);
                return NULL;
        }
-       typename std::list<ui_view_interface*>::iterator it = this->view_list.begin();
+       typename std::list<ui_iface_view*>::iterator it = this->view_list.begin();
        std::advance(it, idx);
        return *it;
 }
 
-int ui_viewmgr_interface::get_view_index(const ui_view_interface *view)
+int ui_iface_viewmgr::get_view_index(const ui_iface_view *view)
 {
        int idx = 0;
 
-       for (typename std::list<ui_view_interface*>::iterator it = this->view_list.begin(); it != this->view_list.end(); it++)
+       for (typename std::list<ui_iface_view*>::iterator it = this->view_list.begin(); it != this->view_list.end(); it++)
        {
                if (view == *it) return idx;
                ++idx;
@@ -246,39 +246,39 @@ int ui_viewmgr_interface::get_view_index(const ui_view_interface *view)
        return -1;
 }
 
-ui_view_interface *
-ui_viewmgr_interface::get_last_view()
+ui_iface_view *
+ui_iface_viewmgr::get_last_view()
 {
        int cnt = this->get_view_count();
        return this->get_view(cnt - 1);
 }
 
-bool ui_viewmgr_interface::activate()
+bool ui_iface_viewmgr::activate()
 {
        if (this->activated) return false;
        this->activated = true;
        return true;
 }
 
-bool ui_viewmgr_interface::deactivate()
+bool ui_iface_viewmgr::deactivate()
 {
        if (!this->activated) return false;
        this->activated = false;
        return true;
 }
 
-ui_view_interface *ui_viewmgr_interface::get_view(const char *name)
+ui_iface_view *ui_iface_viewmgr::get_view(const char *name)
 {
        //FIXME: ...
        return NULL;
 }
 
-bool ui_viewmgr_interface::is_activated()
+bool ui_iface_viewmgr::is_activated()
 {
        return this->activated;
 }
 
-unsigned int ui_viewmgr_interface::get_view_count()
+unsigned int ui_iface_viewmgr::get_view_count()
 {
        return this->view_list.size();
 }
similarity index 90%
rename from src/interface/ui_viewmgr_interface.h
rename to src/interface/ui_iface_viewmgr.h
index 1b38b71..459976b 100644 (file)
@@ -23,10 +23,10 @@ using namespace std;
 
 namespace viewmgr {
 
-class ui_view_interface;
+class ui_iface_view;
 
 /**
- *  @class ui_viewmgr_interface
+ *  @class ui_iface_viewmgr
  *
  *  @ingroup viewmgr
  *
@@ -36,14 +36,14 @@ class ui_view_interface;
  *
  *  @warning viewmgr will remove all containing views when it's destroyed.
  */
-class ui_viewmgr_interface
+class ui_iface_viewmgr
 {
-       friend class ui_view_interface;
+       friend class ui_iface_view;
 
 private:
        static bool soft_key;               //If system doesn't support HW back key, then this value is @c true.
        static bool event_block;            //Event block on view transition. This value should be configurable by system.
-       list<ui_view_interface*> view_list; //View list.
+       list<ui_iface_view*> view_list; //View list.
        bool activated;                     //Activated status of this viewmgr.
 
        /**
@@ -56,7 +56,7 @@ private:
         *  @warning If the given view is already connected to a viewmgr, this call will be failed.
         *  @see disconnect_view()
         */
-       bool connect_view(ui_view_interface *view);
+       bool connect_view(ui_iface_view *view);
 
        /**
         *  @brief Disconnect a given view from this viewmgr.
@@ -67,7 +67,7 @@ private:
         *
         *  @see connect_view()
         */
-       bool disconnect_view(ui_view_interface *view);
+       bool disconnect_view(ui_iface_view *view);
 
        /**
         *  @brief Toggle event blocking to the given view.
@@ -79,7 +79,7 @@ private:
         *  @param view A view to toggle event blocking.
         *  @param block @c true is blocking event, otherwise @c false.
         */
-       void set_event_block(ui_view_interface *view, bool block);
+       void set_event_block(ui_iface_view *view, bool block);
 
 protected:
        /**
@@ -91,7 +91,7 @@ protected:
         *
         *  @warning This function must be called when push transition is finished.
         */
-       bool push_view_finished(ui_view_interface *view);
+       bool push_view_finished(ui_iface_view *view);
 
        /**
         *  @brief This function is designed for finishing process for pop transition.
@@ -104,7 +104,7 @@ protected:
         *
         *  @warning This function must be called when push transition is finished.
         */
-       bool pop_view_finished(ui_view_interface *view);
+       bool pop_view_finished(ui_iface_view *view);
 
 #if 0
        /**
@@ -114,7 +114,7 @@ protected:
         *
         *  @warning Don't modify this view list.
         */
-       const list<ui_view_interface*>* const get_view_list()
+       const list<ui_iface_view*>* const get_view_list()
        {
                return &this->view_list;
        }
@@ -137,7 +137,7 @@ protected:
         *  @see insert_view_after()
         *  @see pop_view()
         */
-       ui_view_interface *push_view(ui_view_interface *view);
+       ui_iface_view *push_view(ui_iface_view *view);
 
        /**
         *  @brief Pop the top(last) view from this viewmgr view list.
@@ -162,7 +162,7 @@ protected:
         *
         *  @return @c true on success or @c false otherwise.
         */
-       bool insert_view_before(ui_view_interface *view, ui_view_interface *before);
+       bool insert_view_before(ui_iface_view *view, ui_iface_view *before);
 
        /**
         *  @brief Insert a view in this viewmgr view list. Specifically, insert a given @p view right after of the given view, @after.
@@ -172,7 +172,7 @@ protected:
         *
         *  @return @c true on success or @c false otherwise.
         */
-       bool insert_view_after(ui_view_interface *view, ui_view_interface *after);
+       bool insert_view_after(ui_iface_view *view, ui_iface_view *after);
 
        /**
         *  @brief Remove the given view from this viewmgr view list.
@@ -185,7 +185,7 @@ protected:
         *  @see insert_view_after()
         *  @see push_view()
         */
-       bool remove_view(ui_view_interface *view);
+       bool remove_view(ui_iface_view *view);
 
        /**
         *  @brief Return a view which is matched with the index @p idx.
@@ -201,7 +201,7 @@ protected:
         *  @see get_view_index()
         *  @see get_view_count()
         */
-       ui_view_interface* get_view(unsigned int idx);
+       ui_iface_view* get_view(unsigned int idx);
 
        /**
         *  @brief Return a view which is matched with the @p name.
@@ -213,16 +213,16 @@ protected:
         *  @return The view which name is matched with @p name.
         *          If there were no views name matched, @c NULL will be returned.
         *
-        *  @see ui_view_interface::set_name()
+        *  @see ui_iface_view::set_name()
         */
-       ui_view_interface *get_view(const char *name);
+       ui_iface_view *get_view(const char *name);
 
        /**
         *  @brief Return a last(top) view.
         *
         *  @return The view which is last view of the viewmgr view list.
         */
-       ui_view_interface *get_last_view();
+       ui_iface_view *get_last_view();
 
        /**
         *  @brief Return a view index(page) number of the given view.
@@ -234,14 +234,14 @@ protected:
         *
         *  @warning The index number of views are variable since the view list is variable.
         */
-       int get_view_index(const ui_view_interface *view);
+       int get_view_index(const ui_iface_view *view);
 
 public:
        ///Constructor.
-       ui_viewmgr_interface();
+       ui_iface_viewmgr();
 
        ///Destructor.
-       virtual ~ui_viewmgr_interface();
+       virtual ~ui_iface_viewmgr();
 
        /**
         *  @brief Activate this view manager.
index 235e8e5..d5e10b0 100644 (file)
@@ -35,8 +35,8 @@ enum ui_view_indicator
        UI_VIEW_INDICATOR_LAST
 };
 
-#include "ui_viewmgr_interface.h"
-#include "ui_view_interface.h"
-#include "ui_controller_interface.h"
+#include "ui_iface_viewmgr.h"
+#include "ui_iface_view.h"
+#include "ui_iface_controller.h"
 
 #endif /* UI_VIEWMANAGER_INTERFACE_H */