parent
c6f69e07ee
commit
cce8cb5433
|
@ -20,11 +20,16 @@ public:
|
||||||
// EAPI void elm_need_efreet(void);
|
// EAPI void elm_need_efreet(void);
|
||||||
// EAPI void elm_need_e_dbus(void);
|
// EAPI void elm_need_e_dbus(void);
|
||||||
|
|
||||||
double getScale ();
|
static double getScale ();
|
||||||
void setScale (double scale);
|
static void setScale (double scale);
|
||||||
|
|
||||||
// EAPI Evas_Coord elm_finger_size_get(void);
|
// EAPI Evas_Coord elm_finger_size_get(void);
|
||||||
// EAPI void elm_finger_size_set(Evas_Coord size);
|
// EAPI void elm_finger_size_set(Evas_Coord size);
|
||||||
|
|
||||||
|
/*!
|
||||||
|
* Flush all caches & dump all data that can be to lean down to use less memory
|
||||||
|
*/
|
||||||
|
static void flushAll ();
|
||||||
};
|
};
|
||||||
|
|
||||||
} // end namespace Elmxx
|
} // end namespace Elmxx
|
||||||
|
|
|
@ -316,6 +316,14 @@ public:
|
||||||
*/
|
*/
|
||||||
GenListItem *append (GenListColumnConstructor *construction, const GenListItem *parent, Elm_Genlist_Item_Flags flags, GenListColumnSelector *selection);
|
GenListItem *append (GenListColumnConstructor *construction, const GenListItem *parent, Elm_Genlist_Item_Flags flags, GenListColumnSelector *selection);
|
||||||
|
|
||||||
|
GenListItem *prepend (GenListColumnConstructor *construction, const GenListItem *parent, Elm_Genlist_Item_Flags flags, GenListColumnSelector *selection);
|
||||||
|
|
||||||
|
GenListItem *insertBefore (GenListColumnConstructor *construction, const GenListItem *parent, Elm_Genlist_Item_Flags flags, GenListColumnSelector *selection);
|
||||||
|
|
||||||
|
GenListItem *insertAfter (GenListColumnConstructor *construction, const GenListItem *parent, Elm_Genlist_Item_Flags flags, GenListColumnSelector *selection);
|
||||||
|
|
||||||
|
void del (GenListItem &item);
|
||||||
|
|
||||||
GenListItem *getItemSelected () const;
|
GenListItem *getItemSelected () const;
|
||||||
|
|
||||||
/*!
|
/*!
|
||||||
|
@ -352,6 +360,16 @@ private:
|
||||||
GenList (const GenList&); // forbid copy constructor
|
GenList (const GenList&); // forbid copy constructor
|
||||||
GenList (Evasxx::Object &parent); // private construction -> use factory ()
|
GenList (Evasxx::Object &parent); // private construction -> use factory ()
|
||||||
~GenList (); // forbid direct delete -> use Object::destroy()
|
~GenList (); // forbid direct delete -> use Object::destroy()
|
||||||
|
|
||||||
|
enum InsertOperation
|
||||||
|
{
|
||||||
|
Append,
|
||||||
|
Prepend,
|
||||||
|
InsertAfter,
|
||||||
|
InsertBefore
|
||||||
|
};
|
||||||
|
|
||||||
|
GenListItem *insertInternal (GenListColumnConstructor *construction, GenList::InsertOperation op, const GenListItem *opItem, Elm_Genlist_Item_Flags flags, GenListColumnSelector *selection);
|
||||||
|
|
||||||
static void gl_sel (void *data, Evas_Object *obj, void *event_info);
|
static void gl_sel (void *data, Evas_Object *obj, void *event_info);
|
||||||
|
|
||||||
|
|
|
@ -40,5 +40,10 @@ void Application::setScale (double scale)
|
||||||
{
|
{
|
||||||
elm_scale_set (scale);
|
elm_scale_set (scale);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void Application::flushAll ()
|
||||||
|
{
|
||||||
|
elm_all_flush ();
|
||||||
|
}
|
||||||
|
|
||||||
} // end namespace Elmxx
|
} // end namespace Elmxx
|
||||||
|
|
|
@ -146,6 +146,26 @@ void GenList::glSelected (GenListColumnSelector &selection, const Evasxx::Object
|
||||||
/* operations to add items */
|
/* operations to add items */
|
||||||
|
|
||||||
GenListItem *GenList::append (GenListColumnConstructor *construction, const GenListItem *parent, Elm_Genlist_Item_Flags flags, GenListColumnSelector *selection)
|
GenListItem *GenList::append (GenListColumnConstructor *construction, const GenListItem *parent, Elm_Genlist_Item_Flags flags, GenListColumnSelector *selection)
|
||||||
|
{
|
||||||
|
insertInternal (construction, GenList::Append, parent, flags, selection);
|
||||||
|
}
|
||||||
|
|
||||||
|
GenListItem *GenList::prepend (GenListColumnConstructor *construction, const GenListItem *parent, Elm_Genlist_Item_Flags flags, GenListColumnSelector *selection)
|
||||||
|
{
|
||||||
|
insertInternal (construction, GenList::Prepend, parent, flags, selection);
|
||||||
|
}
|
||||||
|
|
||||||
|
GenListItem *GenList::insertBefore (GenListColumnConstructor *construction, const GenListItem *parent, Elm_Genlist_Item_Flags flags, GenListColumnSelector *selection)
|
||||||
|
{
|
||||||
|
insertInternal (construction, GenList::InsertBefore, parent, flags, selection);
|
||||||
|
}
|
||||||
|
|
||||||
|
GenListItem *GenList::insertAfter (GenListColumnConstructor *construction, const GenListItem *parent, Elm_Genlist_Item_Flags flags, GenListColumnSelector *selection)
|
||||||
|
{
|
||||||
|
insertInternal (construction, GenList::InsertAfter, parent, flags, selection);
|
||||||
|
}
|
||||||
|
|
||||||
|
GenListItem *GenList::insertInternal (GenListColumnConstructor *construction, GenList::InsertOperation op, const GenListItem *opItem, Elm_Genlist_Item_Flags flags, GenListColumnSelector *selection)
|
||||||
{
|
{
|
||||||
assert (mModel);
|
assert (mModel);
|
||||||
|
|
||||||
|
@ -172,12 +192,44 @@ GenListItem *GenList::append (GenListColumnConstructor *construction, const GenL
|
||||||
construction->mDataModel = mModel;
|
construction->mDataModel = mModel;
|
||||||
selection->mGenList = this;
|
selection->mGenList = this;
|
||||||
|
|
||||||
gli = elm_genlist_item_append (o, &mModel->mGLIC,
|
switch (op)
|
||||||
construction /* item data */,
|
{
|
||||||
parent ? parent->mItem : NULL /* parent */,
|
case Append:
|
||||||
flags,
|
gli = elm_genlist_item_append (o, &mModel->mGLIC,
|
||||||
GenList::gl_sel/* func */,
|
construction /* item data */,
|
||||||
selection /* func data */);
|
opItem ? opItem->mItem : NULL /* parent */,
|
||||||
|
flags,
|
||||||
|
GenList::gl_sel/* func */,
|
||||||
|
selection /* func data */);
|
||||||
|
break;
|
||||||
|
|
||||||
|
case Prepend:
|
||||||
|
gli = elm_genlist_item_prepend (o, &mModel->mGLIC,
|
||||||
|
construction /* item data */,
|
||||||
|
opItem ? opItem->mItem : NULL /* parent */,
|
||||||
|
flags,
|
||||||
|
GenList::gl_sel/* func */,
|
||||||
|
selection /* func data */);
|
||||||
|
break;
|
||||||
|
|
||||||
|
case InsertBefore:
|
||||||
|
gli = elm_genlist_item_insert_before (o, &mModel->mGLIC,
|
||||||
|
construction /* item data */,
|
||||||
|
opItem ? opItem->mItem : NULL /* parent */,
|
||||||
|
flags,
|
||||||
|
GenList::gl_sel/* func */,
|
||||||
|
selection /* func data */);
|
||||||
|
break;
|
||||||
|
|
||||||
|
case InsertAfter:
|
||||||
|
gli = elm_genlist_item_insert_after (o, &mModel->mGLIC,
|
||||||
|
construction /* item data */,
|
||||||
|
opItem ? opItem->mItem : NULL /* parent */,
|
||||||
|
flags,
|
||||||
|
GenList::gl_sel/* func */,
|
||||||
|
selection /* func data */);
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
|
||||||
GenListItem *item = GenListItem::wrap (*gli, *mModel);
|
GenListItem *item = GenListItem::wrap (*gli, *mModel);
|
||||||
|
|
||||||
|
@ -200,6 +252,11 @@ GenListItem *GenList::append (GenListColumnConstructor *construction, const GenL
|
||||||
return item;
|
return item;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void GenList::del (GenListItem &item)
|
||||||
|
{
|
||||||
|
elm_genlist_item_del (item.mItem);
|
||||||
|
}
|
||||||
|
|
||||||
GenListItem *GenList::getItemSelected () const
|
GenListItem *GenList::getItemSelected () const
|
||||||
{
|
{
|
||||||
Elm_Genlist_Item *item = elm_genlist_selected_item_get (o);
|
Elm_Genlist_Item *item = elm_genlist_selected_item_get (o);
|
||||||
|
|
Loading…
Reference in New Issue