Sync with the latest one 75/14475/1
authorSung-jae Park <nicesj.park@samsung.com>
Sun, 5 Jan 2014 09:08:31 +0000 (18:08 +0900)
committerSung-jae Park <nicesj.park@samsung.com>
Sun, 5 Jan 2014 09:08:31 +0000 (18:08 +0900)
Change-Id: I0f9a7eb93e5f878ab3bf08a3f64cd9b8f8d1c297

include/CModule.h
packaging/liblivebox-cpp.manifest
packaging/liblivebox-cpp.spec
src/CModule.cpp
src/livebox.cpp

index 2851257..f7c66ac 100644 (file)
@@ -37,11 +37,11 @@ public:
        static CModule *Load(const char *pkgname);
        int Unload(void);
 
-       int Create(const char *id, const char *content, const char *cluster, const char *category);
+       int Create(const char *filename, const char *content, const char *cluster, const char *category);
        int NeedToCreate(const char *cluster, const char *category);
        int Destroy(CLiveBoxImpl *inst);
 
-       CLiveBoxImpl *FindLiveBox(const char *id);
+       CLiveBoxImpl *FindLiveBox(const char *filename);
 
        const char *PackageName(void) { return m_sPkgname; }
 };
index 017d22d..a76fdba 100644 (file)
@@ -1,5 +1,5 @@
 <manifest>
- <request>
-    <domain name="_"/>
- </request>
      <request>
+               <domain name="_" />
      </request>
 </manifest>
index 4623b63..246912f 100644 (file)
@@ -2,10 +2,11 @@ Name: liblivebox-cpp
 Summary: C++ adaptor for a livebox 
 Version: 0.2.8
 Release: 1
+VCS:     magnolia/apps/livebox/livebox-cpp#livebox-cpp_0.2.4-19-g18d4a8671e59384424cf0c3c189e598a8ab2aed2
 Group: HomeTF/Livebox
-License: Flora License
+License: Flora
 Source0: %{name}-%{version}.tar.gz
-Source1001:    liblivebox-cpp.manifest
+Source1001: %{name}.manifest
 BuildRequires: cmake, gettext-tools, coreutils
 BuildRequires: pkgconfig(dlog)
 BuildRequires: pkgconfig(livebox)
@@ -16,7 +17,7 @@ BuildRequires: pkgconfig(livebox-service)
 Livebox development library (C++)
 
 %package devel
-Summary: Files for livebox development.
+Summary: Files for livebox development
 Group: Development/Libraries
 Requires: %{name} = %{version}-%{release}
 
@@ -28,6 +29,12 @@ Livebox development library (C++) (dev)
 cp %{SOURCE1001} .
 
 %build
+%if 0%{?sec_build_binary_debug_enable}
+export CFLAGS="$CFLAGS -DTIZEN_DEBUG_ENABLE"
+export CXXFLAGS="$CXXFLAGS -DTIZEN_DEBUG_ENABLE"
+export FFLAGS="$FFLAGS -DTIZEN_DEBUG_ENABLE"
+%endif
+
 %if 0%{?tizen_build_binary_release_type_eng}
 export CFLAGS="${CFLAGS} -DTIZEN_ENGINEER_MODE"
 export CXXFLAGS="${CXXFLAGS} -DTIZEN_ENGINEER_MODE"
index e37cc52..8f8c967 100644 (file)
@@ -127,14 +127,14 @@ int CModule::Unload(void)
        return LB_STATUS_SUCCESS;
 }
 
-int CModule::Create(const char *id, const char *content, const char *cluster, const char *category)
+int CModule::Create(const char *filename, const char *content, const char *cluster, const char *category)
 {
        CLiveBoxImpl *inst;
 
        inst = (CLiveBoxImpl *)m_fNew();
        if (inst) {
                int ret;
-               ret = inst->Create(id, content, cluster, category);
+               ret = inst->Create(filename, content, cluster, category);
                if (ret < 0) {
                        delete inst;
                        return ret;
@@ -161,7 +161,7 @@ int CModule::Destroy(CLiveBoxImpl *inst)
        return LB_STATUS_SUCCESS;
 }
 
-CLiveBoxImpl *CModule::FindLiveBox(const char *id)
+CLiveBoxImpl *CModule::FindLiveBox(const char *filename)
 {
        struct dlist *l;
        void *item;
@@ -169,7 +169,7 @@ CLiveBoxImpl *CModule::FindLiveBox(const char *id)
 
        dlist_foreach(m_pList, l, item) {
                box = (CLiveBoxImpl *)item;
-               if (!strcmp(id, box->Filename())) {
+               if (!strcmp(filename, box->Filename())) {
                        return box;
                }
        }
index 03e1766..4f0006c 100644 (file)
@@ -58,7 +58,7 @@ EAPI int livebox_finalize(const char *pkgname)
        return LB_STATUS_SUCCESS;
 }
 
-EAPI int livebox_create(const char *pkgname, const char *id, const char *content, const char *cluster, const char *category)
+EAPI int livebox_create(const char *pkgname, const char *filename, const char *content, const char *cluster, const char *category)
 {
        CLiveBoxImpl *box;
        CModule *module;
@@ -69,16 +69,16 @@ EAPI int livebox_create(const char *pkgname, const char *id, const char *content
                return LB_STATUS_ERROR_INVALID;
        }
 
-       box = module->FindLiveBox(id);
+       box = module->FindLiveBox(filename);
        if (box) {
                return LB_STATUS_ERROR_NOT_EXIST;
        }
 
-       ret = module->Create(id, content, cluster, category);
+       ret = module->Create(filename, content, cluster, category);
        return ret;
 }
 
-EAPI int livebox_destroy(const char *pkgname, const char *id)
+EAPI int livebox_destroy(const char *pkgname, const char *filename)
 {
        CModule *module;
        CLiveBoxImpl *box;
@@ -89,7 +89,7 @@ EAPI int livebox_destroy(const char *pkgname, const char *id)
                return LB_STATUS_ERROR_INVALID;
        }
 
-       box = module->FindLiveBox(id);
+       box = module->FindLiveBox(filename);
        if (!box) {
                return LB_STATUS_ERROR_NOT_EXIST;
        }
@@ -98,7 +98,7 @@ EAPI int livebox_destroy(const char *pkgname, const char *id)
        return ret;
 }
 
-EAPI int livebox_need_to_update(const char *pkgname, const char *id)
+EAPI int livebox_need_to_update(const char *pkgname, const char *filename)
 {
        CLiveBoxImpl *box;
        CModule *module;
@@ -108,7 +108,7 @@ EAPI int livebox_need_to_update(const char *pkgname, const char *id)
                return LB_STATUS_ERROR_INVALID;
        }
 
-       box = module->FindLiveBox(id);
+       box = module->FindLiveBox(filename);
        if (!box) {
                return LB_STATUS_ERROR_NOT_EXIST;
        }
@@ -116,7 +116,7 @@ EAPI int livebox_need_to_update(const char *pkgname, const char *id)
        return box->NeedToUpdate();
 }
 
-EAPI int livebox_need_to_destroy(const char *pkgname, const char *id)
+EAPI int livebox_need_to_destroy(const char *pkgname, const char *filename)
 {
        CLiveBoxImpl *box;
        CModule *module;
@@ -126,7 +126,7 @@ EAPI int livebox_need_to_destroy(const char *pkgname, const char *id)
                return LB_STATUS_ERROR_INVALID;
        }
 
-       box = module->FindLiveBox(id);
+       box = module->FindLiveBox(filename);
        if (!box) {
                return LB_STATUS_ERROR_NOT_EXIST;
        }
@@ -134,7 +134,7 @@ EAPI int livebox_need_to_destroy(const char *pkgname, const char *id)
        return box->NeedToDestroy();
 }
 
-EAPI int livebox_update_content(const char *pkgname, const char *id)
+EAPI int livebox_update_content(const char *pkgname, const char *filename)
 {
        CLiveBoxImpl *box;
        CModule *module;
@@ -144,7 +144,7 @@ EAPI int livebox_update_content(const char *pkgname, const char *id)
                return LB_STATUS_ERROR_INVALID;
        }
 
-       box = module->FindLiveBox(id);
+       box = module->FindLiveBox(filename);
        if (!box) {
                return LB_STATUS_ERROR_NOT_EXIST;
        }
@@ -152,7 +152,7 @@ EAPI int livebox_update_content(const char *pkgname, const char *id)
        return box->UpdateContent();
 }
 
-EAPI int livebox_clicked(const char *pkgname, const char *id, const char *event, double timestamp, double x, double y)
+EAPI int livebox_clicked(const char *pkgname, const char *filename, const char *event, double timestamp, double x, double y)
 {
        CLiveBoxImpl *box;
        CModule *module;
@@ -162,7 +162,7 @@ EAPI int livebox_clicked(const char *pkgname, const char *id, const char *event,
                return LB_STATUS_ERROR_INVALID;
        }
 
-       box = module->FindLiveBox(id);
+       box = module->FindLiveBox(filename);
        if (!box) {
                return LB_STATUS_ERROR_NOT_EXIST;
        }
@@ -170,7 +170,7 @@ EAPI int livebox_clicked(const char *pkgname, const char *id, const char *event,
        return box->Clicked(event, timestamp, x, y);
 }
 
-EAPI int livebox_content_event(const char *pkgname, const char *id, const char *emission, const char *source, struct event_info *event_info)
+EAPI int livebox_content_event(const char *pkgname, const char *filename, const char *emission, const char *source, struct event_info *event_info)
 {
        CLiveBoxImpl *box;
        CModule *module;
@@ -180,7 +180,7 @@ EAPI int livebox_content_event(const char *pkgname, const char *id, const char *
                return LB_STATUS_ERROR_INVALID;
        }
 
-       box = module->FindLiveBox(id);
+       box = module->FindLiveBox(filename);
        if (!box) {
                return LB_STATUS_ERROR_NOT_EXIST;
        }
@@ -188,7 +188,7 @@ EAPI int livebox_content_event(const char *pkgname, const char *id, const char *
        return box->ContentEvent(emission, source, event_info);
 }
 
-EAPI int livebox_resize(const char *pkgname, const char *id, int type)
+EAPI int livebox_resize(const char *pkgname, const char *filename, int type)
 {
        CLiveBoxImpl *box;
        CModule *module;
@@ -198,7 +198,7 @@ EAPI int livebox_resize(const char *pkgname, const char *id, int type)
                return LB_STATUS_ERROR_INVALID;
        }
 
-       box = module->FindLiveBox(id);
+       box = module->FindLiveBox(filename);
        if (!box) {
                return LB_STATUS_ERROR_NOT_EXIST;
        }
@@ -206,7 +206,7 @@ EAPI int livebox_resize(const char *pkgname, const char *id, int type)
        return box->Resize(type);
 }
 
-EAPI int livebox_change_group(const char *pkgname, const char *id, const char *cluster, const char *category)
+EAPI int livebox_change_group(const char *pkgname, const char *filename, const char *cluster, const char *category)
 {
        CLiveBoxImpl *box;
        CModule *module;
@@ -216,7 +216,7 @@ EAPI int livebox_change_group(const char *pkgname, const char *id, const char *c
                return LB_STATUS_ERROR_INVALID;
        }
 
-       box = module->FindLiveBox(id);
+       box = module->FindLiveBox(filename);
        if (!box) {
                return LB_STATUS_ERROR_NOT_EXIST;
        }
@@ -224,7 +224,7 @@ EAPI int livebox_change_group(const char *pkgname, const char *id, const char *c
        return box->ChangeGroup(cluster, category);
 }
 
-EAPI int livebox_get_info(const char *pkgname, const char *id, int *w, int *h, double *priority, char **content, char **title)
+EAPI int livebox_get_info(const char *pkgname, const char *filename, int *w, int *h, double *priority, char **content, char **title)
 {
        CLiveBoxImpl *box;
        CModule *module;
@@ -234,7 +234,7 @@ EAPI int livebox_get_info(const char *pkgname, const char *id, int *w, int *h, d
                return LB_STATUS_ERROR_INVALID;
        }
 
-       box = module->FindLiveBox(id);
+       box = module->FindLiveBox(filename);
        if (!box) {
                return LB_STATUS_ERROR_NOT_EXIST;
        }
@@ -254,7 +254,7 @@ EAPI int livebox_need_to_create(const char *pkgname, const char *cluster, const
        return module->NeedToCreate(cluster, category);
 }
 
-EAPI char *livebox_pinup(const char *pkgname, const char *id, int pinup)
+EAPI char *livebox_pinup(const char *pkgname, const char *filename, int pinup)
 {
        CLiveBoxImpl *box;
        CModule *module;
@@ -264,7 +264,7 @@ EAPI char *livebox_pinup(const char *pkgname, const char *id, int pinup)
                return NULL;
        }
 
-       box = module->FindLiveBox(id);
+       box = module->FindLiveBox(filename);
        if (!box) {
                return NULL;
        }
@@ -272,7 +272,7 @@ EAPI char *livebox_pinup(const char *pkgname, const char *id, int pinup)
        return box->PinUp(pinup);
 }
 
-EAPI int livebox_is_pinned_up(const char *pkgname, const char *id)
+EAPI int livebox_is_pinned_up(const char *pkgname, const char *filename)
 {
        CLiveBoxImpl *box;
        CModule *module;
@@ -282,7 +282,7 @@ EAPI int livebox_is_pinned_up(const char *pkgname, const char *id)
                return NULL;
        }
 
-       box = module->FindLiveBox(id);
+       box = module->FindLiveBox(filename);
        if (!box) {
                return NULL;
        }
@@ -290,7 +290,7 @@ EAPI int livebox_is_pinned_up(const char *pkgname, const char *id)
        return box->IsPinnedUp();
 }
 
-EAPI int livebox_system_event(const char *pkgname, const char *id, int event)
+EAPI int livebox_system_event(const char *pkgname, const char *filename, int event)
 {
        CLiveBoxImpl *box;
        CModule *module;
@@ -300,7 +300,7 @@ EAPI int livebox_system_event(const char *pkgname, const char *id, int event)
                return NULL;
        }
 
-       box = module->FindLiveBox(id);
+       box = module->FindLiveBox(filename);
        if (!box) {
                return NULL;
        }