tasn pushed a commit to branch master.

http://git.enlightenment.org/bindings/cxx/eflxx.git/commit/?id=524bd40d1767a3eba8b48407a217ea6979a1ddbe

commit 524bd40d1767a3eba8b48407a217ea6979a1ddbe
Author: ChunEon Park <[email protected]>
Date:   Fri Jan 20 08:38:20 2012 +0000

    BINDINGS/python, cxx, perl, vala - Elm_Genlist_Item -> Elm_Object_Item
    
    
    
    SVN revision: 67372
---
 .../src/elementaryxx/full/test_genlist.cpp         | 26 ++++++++---------
 elementaryxx/include/elementaryxx/GenItem.h        |  2 +-
 elementaryxx/include/elementaryxx/GenList.h        |  8 ++---
 elementaryxx/include/elementaryxx/GenListItem.h    | 14 ++++-----
 elementaryxx/src/GenList.cpp                       | 34 +++++++++++-----------
 elementaryxx/src/GenListItem.cpp                   | 12 ++++----
 6 files changed, 48 insertions(+), 48 deletions(-)

diff --git a/eflxx_examples/src/elementaryxx/full/test_genlist.cpp 
b/eflxx_examples/src/elementaryxx/full/test_genlist.cpp
index 102a80c..eb45b3f 100644
--- a/eflxx_examples/src/elementaryxx/full/test_genlist.cpp
+++ b/eflxx_examples/src/elementaryxx/full/test_genlist.cpp
@@ -1100,38 +1100,38 @@ void test_genlist5 (void *data, Evas_Object *obj, void 
*event_info)
 
 static void gl4_exp (Evasxx::Object &obj, void *event_info, GenList *gl)
 {
-  // TODO: why is event_info used as container for Elm_Genlist_Item?
+  // TODO: why is event_info used as container for genlist item?
 #if 0
-   Elm_Genlist_Item *it = event_info;
-   Evas_Object *gl = elm_genlist_item_genlist_get(it);
-   int val = (int)elm_genlist_item_data_get(it);
+   Elm_Object_Item *glit = event_info;
+   Evas_Object *gl = elm_genlist_item_genlist_get(glit);
+   int val = (int)elm_genlist_item_data_get(glit);
    val *= 10;
    elm_genlist_item_append(gl, &itc4,
-                          (void *)(val + 1)/* item data */, it/* parent */, 
ELM_GENLIST_ITEM_NONE, gl4_sel/* func */,
+                          (void *)(val + 1)/* item data */, glit/* parent */, 
ELM_GENLIST_ITEM_NONE, gl4_sel/* func */,
                           NULL/* func data */);
    elm_genlist_item_append(gl, &itc4,
-                          (void *)(val + 2)/* item data */, it/* parent */, 
ELM_GENLIST_ITEM_NONE, gl4_sel/* func */,
+                          (void *)(val + 2)/* item data */, glit/* parent */, 
ELM_GENLIST_ITEM_NONE, gl4_sel/* func */,
                           NULL/* func data */);
    elm_genlist_item_append(gl, &itc4,
-                          (void *)(val + 3)/* item data */, it/* parent */, 
ELM_GENLIST_ITEM_SUBITEMS, gl4_sel/* func */,
+                          (void *)(val + 3)/* item data */, glit/* parent */, 
ELM_GENLIST_ITEM_SUBITEMS, gl4_sel/* func */,
                           NULL/* func data */);
 #endif
 }
 static void gl4_con (Evasxx::Object &obj, void *event_info, GenList *gl)
 {
-   //Elm_Genlist_Item *it = event_info;
-   //elm_genlist_item_subitems_clear(it);
+   //Elm_Object_Item *glit = event_info;
+   //elm_genlist_item_subitems_clear(glit);
 }
 
 static void gl4_exp_req (Evasxx::Object &obj, void *event_info, GenList *gl)
 {
-   //Elm_Genlist_Item *it = event_info;
-   //elm_genlist_item_expanded_set(it, 1);
+   //Elm_Object_Item *glit = event_info;
+   //elm_genlist_item_expanded_set(glit, EINA_TRUE);
 }
 static void gl4_con_req (Evasxx::Object &obj, void *event_info, GenList *gl)
 {
-   //Elm_Genlist_Item *it = event_info;
-   //elm_genlist_item_expanded_set(it, 0);
+   //Elm_Object_Item *glit = event_info;
+   //elm_genlist_item_expanded_set(glit, EINA_FALSE);
 }
 
 class GenDataModel6 : public GenDataModel
diff --git a/elementaryxx/include/elementaryxx/GenItem.h 
b/elementaryxx/include/elementaryxx/GenItem.h
index 3bd5b6d..3ea078a 100644
--- a/elementaryxx/include/elementaryxx/GenItem.h
+++ b/elementaryxx/include/elementaryxx/GenItem.h
@@ -21,7 +21,7 @@ public:
   friend class GenList;
 
   virtual ~GenItem ();
-  
+
   void setSelected (bool selected);
   bool getSelected () const;
 
diff --git a/elementaryxx/include/elementaryxx/GenList.h 
b/elementaryxx/include/elementaryxx/GenList.h
index fbb147e..20abaae 100644
--- a/elementaryxx/include/elementaryxx/GenList.h
+++ b/elementaryxx/include/elementaryxx/GenList.h
@@ -171,7 +171,7 @@ class GenListColumnSelector;
  * data attached to the item (e.g. its data parameter on creation) can be
  * deleted.
  *
- * Items can be added by several calls. All of them return a Elm_Genlist_Item
+ * Items can be added by several calls. All of them return a genlist 
item(Elm_Object_Item)
  * handle that is an internal member inside the genlist. They all take a data
  * parameter that is meant to be used for a handle to the applications
  * internal data (eg the struct with the original item data). The parent
@@ -371,9 +371,9 @@ private:
 
 #if 0
    /* operations to add items */
-   EAPI Elm_Genlist_Item *elm_genlist_item_prepend(Evas_Object *obj, const 
Elm_Genlist_Item_Class *itc, const void *data, Elm_Genlist_Item *parent, 
Elm_Genlist_Item_Flags flags, Evas_Smart_Cb func, const void *func_data);
-   EAPI Elm_Genlist_Item *elm_genlist_item_insert_before(Evas_Object *obj, 
const Elm_Genlist_Item_Class *itc, const void *data, Elm_Genlist_Item *parent, 
Elm_Genlist_Item *before, Elm_Genlist_Item_Flags flags, Evas_Smart_Cb func, 
const void *func_data);
-   EAPI Elm_Genlist_Item *elm_genlist_item_insert_after(Evas_Object *obj, 
const Elm_Genlist_Item_Class *itc, const void *data, Elm_Genlist_Item *parent, 
Elm_Genlist_Item *after, Elm_Genlist_Item_Flags flags, Evas_Smart_Cb func, 
const void *func_data);
+   EAPI Elm_Object_Item *elm_genlist_item_prepend(Evas_Object *obj, const 
Elm_Genlist_Item_Class *itc, const void *data, Elm_Object_Item *parent, 
Elm_Genlist_Item_Flags flags, Evas_Smart_Cb func, const void *func_data);
+   EAPI Elm_Object_Item *elm_genlist_item_insert_before(Evas_Object *obj, 
const Elm_Genlist_Item_Class *itc, const void *data, Elm_Object_Item *parent, 
Elm_Genlist_Item *before, Elm_Genlist_Item_Flags flags, Evas_Smart_Cb func, 
const void *func_data);
+   EAPI Elm_Object_Item *elm_genlist_item_insert_after(Evas_Object *obj, const 
Elm_Genlist_Item_Class *itc, const void *data, Elm_Object_Item *parent, 
Elm_Genlist_Item *after, Elm_Genlist_Item_Flags flags, Evas_Smart_Cb func, 
const void *func_data);
    /* operations to retrieve existing items */
 
 
diff --git a/elementaryxx/include/elementaryxx/GenListItem.h 
b/elementaryxx/include/elementaryxx/GenListItem.h
index 451ebcc..0ec3cc1 100644
--- a/elementaryxx/include/elementaryxx/GenListItem.h
+++ b/elementaryxx/include/elementaryxx/GenListItem.h
@@ -42,18 +42,18 @@ public:
 
   const Evasxx::Object *getEvasObject ();
 
-  static GenListItem *wrap (Elm_Genlist_Item &item, GenDataModel &model);
+  static GenListItem *wrap (Elm_Object_Item &item, GenDataModel &model);
+
+  static GenListItem *objectLink (const Elm_Object_Item *item);
+
 
-  static GenListItem *objectLink (const Elm_Genlist_Item *item);
-  
-  
 private:
-  GenListItem (Elm_Genlist_Item *item);
+  GenListItem (Elm_Object_Item *item);
 
   const void *getData ();
   void setData (const void *data);
-  
-  Elm_Gen_Item *mItem;
+
+  Elm_Object_Item *mItem;
   GenDataModel *mDataModel;
 };
 
diff --git a/elementaryxx/src/GenList.cpp b/elementaryxx/src/GenList.cpp
index 4e1c0df..d5ff95b 100644
--- a/elementaryxx/src/GenList.cpp
+++ b/elementaryxx/src/GenList.cpp
@@ -131,17 +131,17 @@ GenListItem *GenList::insertAfter 
(GenListColumnConstructor *construction, const
 GenListItem *GenList::insertInternal (GenListColumnConstructor *construction, 
GenList::InsertOperation op, const GenListItem *opItem, Elm_Genlist_Item_Flags 
flags, GenListColumnSelector *selection)
 {
   assert (mModel);
-  
-  Elm_Genlist_Item *gli;
+
+  Elm_Object_Item *gli;
   bool internalConstruction = false;
   bool internalSelection = false;
-  
+
   if (!construction)
   {
     // create internal construction object if construction==NULL was given and 
delete if after adding
     // this is needed to provide the user an easy API to add type save data to 
item append callbacks
     internalConstruction = true;
-    construction = new GenListColumnConstructor ();  
+    construction = new GenListColumnConstructor ();
   }
   
   if (!selection)
@@ -197,11 +197,11 @@ GenListItem *GenList::insertInternal 
(GenListColumnConstructor *construction, Ge
   }
 
   GenListItem *item = GenListItem::wrap (*gli, *mModel); // TODO: generic!!
-  
+
   construction->mGenItem = item;
 
   //EAPI const void *
-  //elm_genlist_item_data_get(const Elm_Genlist_Item *it)
+  //elm_genlist_item_data_get(const Elm_Object_Item *it)
   // -> returns: GenListColumnConstructor *construction
   // 1. add GenItem* to construction
 
@@ -213,7 +213,7 @@ GenListItem *GenList::insertInternal 
(GenListColumnConstructor *construction, Ge
   {
     mInternalSelList.push_back (selection);
   }
-  
+
   return item;
 }
 
@@ -224,49 +224,49 @@ void GenList::del (GenListItem &item)
 
 GenListItem *GenList::getItemSelected () const
 {
-  Elm_Genlist_Item *item = elm_genlist_selected_item_get (o);
+  Elm_Object_Item *item = elm_genlist_selected_item_get (o);
 
   if (!item)
     return NULL;
-  
+
   const GenListColumnConstructor *construction = static_cast <const 
GenListColumnConstructor*> (elm_genlist_item_data_get (item));
-  
+
   return construction->mGenItem;
 }
 
 GenListItem *GenList::getItemAtXY (const Eflxx::Point &pos, int &posret) const
 {
-  Elm_Genlist_Item *item = elm_genlist_at_xy_item_get (o, pos.x (), pos.y (), 
&posret);
+  Elm_Object_Item *item = elm_genlist_at_xy_item_get (o, pos.x (), pos.y (), 
&posret);
 
   if (!item)
     return NULL;
-  
+
   const GenListColumnConstructor *construction = static_cast <const 
GenListColumnConstructor*> (elm_genlist_item_data_get (item));
-  
+
   return construction->mGenItem;
 }
 
 GenListItem *GenList::getItemFirst () const
 {
-  Elm_Genlist_Item *item = elm_genlist_first_item_get (o);
+  Elm_Object_Item *item = elm_genlist_first_item_get (o);
 
   if (!item)
     return NULL;
 
   const GenListColumnConstructor *construction = static_cast <const 
GenListColumnConstructor*> (elm_genlist_item_data_get (item));
-  
+
   return construction->mGenItem;
 }
 
 GenListItem *GenList::getItemLast () const
 {
-  Elm_Genlist_Item *item = elm_genlist_last_item_get (o);
+  Elm_Object_Item *item = elm_genlist_last_item_get (o);
 
   if (!item)
     return NULL;
 
   const GenListColumnConstructor *construction = static_cast <const 
GenListColumnConstructor*> (elm_genlist_item_data_get (item));
-  
+
   return construction->mGenItem;
 }
 
diff --git a/elementaryxx/src/GenListItem.cpp b/elementaryxx/src/GenListItem.cpp
index e90e4ff..f5476f0 100644
--- a/elementaryxx/src/GenListItem.cpp
+++ b/elementaryxx/src/GenListItem.cpp
@@ -14,12 +14,12 @@ using namespace std;
 
 namespace Elmxx {
 
-GenListItem::GenListItem (Elm_Genlist_Item *item) :
+GenListItem::GenListItem (Elm_Object_Item *item) :
   mItem (item)
 {
 
 }
-  
+
 GenListItem::~GenListItem ()
 {
   cout << "GenListItem::~GenListItem" << endl;
@@ -28,12 +28,12 @@ GenListItem::~GenListItem ()
 
 void GenListItem::setSelected (bool selected)
 {
-  elm_gen_item_selected_set (mItem, selected);
+  elm_gen_item_selected_set (reinterpret_cast<Elm_Gen_Item *>(mItem), 
selected);
 }
 
 bool GenListItem::getSelected () const
 {
-  return elm_gen_item_selected_get (mItem);
+  return elm_gen_item_selected_get (reinterpret_cast<Elm_Gen_Item *>(mItem));
 }
 
 
@@ -113,7 +113,7 @@ const Evasxx::Object *GenListItem::getEvasObject ()
   return Evasxx::Object::objectLink (obj);
 }
 
-GenListItem *GenListItem::wrap (Elm_Genlist_Item &item, GenDataModel &model)
+GenListItem *GenListItem::wrap (Elm_Object_Item &item, GenDataModel &model)
 {
   GenListItem *genItem = new GenListItem (&item);
   genItem->mDataModel = &model;
@@ -122,7 +122,7 @@ GenListItem *GenListItem::wrap (Elm_Genlist_Item &item, 
GenDataModel &model)
   return genItem;
 }
 
-GenListItem *GenListItem::objectLink (const Elm_Genlist_Item *item)
+GenListItem *GenListItem::objectLink (const Elm_Object_Item *item)
 {
   //GenItem *item2 = static_cast <GenItem*> (const_cast <void*> 
(elm_genlist_item_data_get(item)));
   //assert (item2);

-- 


Reply via email to