本文整理汇总了C++中eina_list_remove函数的典型用法代码示例。如果您正苦于以下问题:C++ eina_list_remove函数的具体用法?C++ eina_list_remove怎么用?C++ eina_list_remove使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了eina_list_remove函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: _e_shell_surface_parent_set
static void
_e_shell_surface_parent_set(E_Client *ec, struct wl_resource *parent_resource)
{
E_Client *pc;
uint64_t pwin = 0;
if (!parent_resource)
{
ec->icccm.fetch.transient_for = EINA_FALSE;
ec->icccm.transient_for = 0;
if (ec->parent)
{
ec->parent->transients =
eina_list_remove(ec->parent->transients, ec);
if (ec->parent->modal == ec) ec->parent->modal = NULL;
ec->parent = NULL;
}
return;
}
pc = wl_resource_get_user_data(parent_resource);
if (!pc)
{
ERR("Could not get parent resource client");
return;
}
pwin = e_pixmap_window_get(pc->pixmap);
e_pixmap_parent_window_set(ec->pixmap, pwin);
/* If we already have a parent, remove it */
if (ec->parent)
{
if (pc != ec->parent)
{
ec->parent->transients =
eina_list_remove(ec->parent->transients, ec);
if (ec->parent->modal == ec) ec->parent->modal = NULL;
ec->parent = NULL;
}
}
if ((pc != ec) &&
(eina_list_data_find(pc->transients, ec) != ec))
{
pc->transients = eina_list_append(pc->transients, ec);
ec->parent = pc;
}
ec->icccm.fetch.transient_for = EINA_TRUE;
ec->icccm.transient_for = pwin;
}
示例2: etox_line_minimize
/*
* etox_line_minimize - reduce the number of bits on a line
*/
void etox_line_minimize(Etox_Line * line)
{
Evas_Object *bit, *last_bit = NULL;
Eina_List *l;
CHECK_PARAM_POINTER("line", line);
l = line->bits;
if (!l)
return;
last_bit = l->data;
l = l->next;
while (l) {
bit = l->data;
/*
* Attempt to merge the bits if possible, remove the second
* one if successful.
*/
if (etox_style_merge(last_bit, bit)) {
line->bits = eina_list_remove(line->bits, bit);
l = eina_list_data_find_list(line->bits, last_bit);
l = l->next;
}
else {
last_bit = bit;
l = l->next;
}
}
}
示例3: termpty_save_unregister
void
termpty_save_unregister(Termpty *ty)
{
termpty_backlog_lock();
ptys = eina_list_remove(ptys, ty);
termpty_backlog_unlock();
}
示例4: _gc_init
/* Gadcon Api Functions */
static E_Gadcon_Client *
_gc_init(E_Gadcon *gc, const char *name, const char *id, const char *style)
{
E_AppMenu_Instance *inst;
E_AppMenu_Context *ctxt;
EINA_SAFETY_ON_NULL_RETURN_VAL(appmenu_module, NULL);
inst = calloc(1, sizeof(E_AppMenu_Instance));
EINA_SAFETY_ON_NULL_RETURN_VAL(inst, NULL);
ctxt = appmenu_module->data;
ctxt->instances = eina_list_append(ctxt->instances, inst);
inst->evas = gc->evas;
inst->ctx = ctxt;
inst->box = evas_object_box_add(inst->evas);
evas_object_show(inst->box);
inst->gcc = e_gadcon_client_new(gc, name, id, style, inst->box);
if (!inst->gcc)
{
evas_object_del(inst->box);
ctxt->instances = eina_list_remove(ctxt->instances, inst);
free(inst);
return NULL;
}
inst->gcc->data = inst;
_gc_orient(inst->gcc, inst->gcc->gadcon->orient);
if (!ctxt->iface)
appmenu_dbus_registrar_server_init(ctxt);
return inst->gcc;
}
示例5: _cb_border_remove
static Eina_Bool
_cb_border_remove(void *data, EINA_UNUSED int type, void *event)
{
E_Event_Client *ev = event;
Client_Item *bi;
Eina_List *l;
Plugin *p = data;
EINA_LIST_FOREACH(p->clients, l, bi)
if (bi->client == ev->ec)
break;
if (!bi) return ECORE_CALLBACK_PASS_ON;
EVRY_PLUGIN_ITEMS_CLEAR(p);
p->clients = eina_list_remove(p->clients, bi);
EVRY_ITEM_FREE(bi);
EVRY_PLUGIN_ITEMS_ADD(p, p->clients, p->input, 1, 0);
EVRY_PLUGIN_UPDATE(p, EVRY_UPDATE_ADD);
return ECORE_CALLBACK_PASS_ON;
}
示例6: _gc_shutdown
static void
_gc_shutdown(E_Gadcon_Client *gcc)
{
Instance *inst;
if (!(inst = gcc->data)) return;
evas_object_event_callback_del(inst->tclock, EVAS_CALLBACK_MOUSE_DOWN,
_tclock_cb_mouse_down);
evas_object_event_callback_del(inst->tclock, EVAS_CALLBACK_MOUSE_IN,
_tclock_cb_mouse_in);
evas_object_event_callback_del(inst->tclock, EVAS_CALLBACK_MOUSE_OUT,
_tclock_cb_mouse_out);
if (inst->tclock) evas_object_del(inst->tclock);
tclock_config->instances =
eina_list_remove(tclock_config->instances, inst);
if (eina_list_count(tclock_config->instances) <= 0)
{
if (check_timer) ecore_timer_del(check_timer);
check_timer = NULL;
}
E_FREE(inst);
}
示例7: eclair_menu_pop_down
//Pop down the menu and its childrend
void eclair_menu_pop_down(Eclair_Menu *menu)
{
Eina_List *l;
Eclair_Menu_Item *item;
if (!menu)
return;
for (l = menu->items; l; l = l->next)
{
if (!(item = l->data))
continue;
eclair_menu_item_deactivate(item);
}
ecore_evas_hide(menu->window);
if (menu == _eclair_menu_root)
{
ecore_x_keyboard_ungrab();
ecore_x_pointer_ungrab();
ecore_x_window_hide(_eclair_menu_input_window);
ecore_event_handler_del(_eclair_menu_mouse_up_handler);
ecore_event_handler_del(_eclair_menu_mouse_move_handler);
_eclair_menu_root = NULL;
}
_eclair_menu_popped_menus = eina_list_remove(_eclair_menu_popped_menus, menu);
}
示例8: etox_line_merge_append
/*
* etox_line_merge_append - merge lines into the first line, empty the second
* @line1: the destination of the merged lines
* @line2: the line that will be merged with line1
*
* Returns no value. Moves the bits from line2 into line 1.
*/
void etox_line_merge_append(Etox_Line * line1, Etox_Line * line2)
{
Evas_Object *bit;
CHECK_PARAM_POINTER("line1", line1);
CHECK_PARAM_POINTER("line2", line2);
/*
* Move the bits from line2 to line1.
*/
while (line2->bits) {
bit = line2->bits->data;
line1->bits = eina_list_append(line1->bits, bit);
line2->bits = eina_list_remove(line2->bits, bit);
line1->length += etox_style_length(bit);
etox_selections_update(bit, line1);
}
/*
* Adjust the height, width and length of the merged line.
*/
line1->w += line2->w;
if (line2->h > line1->h)
line1->h = line2->h;
}
示例9: _edje_var_timer_cb
static Eina_Bool
_edje_var_timer_cb(void *data)
{
Edje_Var_Timer *et;
Edje *ed;
Embryo_Function fn;
et = data;
if (!et) return ECORE_CALLBACK_CANCEL;
ed = et->edje;
// _edje_embryo_script_reset(ed);
embryo_program_vm_push(ed->collection->script);
_edje_embryo_globals_init(ed);
embryo_parameter_cell_push(ed->collection->script, (Embryo_Cell)et->val);
ed->var_pool->timers = eina_list_remove(ed->var_pool->timers, et);
fn = et->func;
free(et);
{
void *pdata;
pdata = embryo_program_data_get(ed->collection->script);
embryo_program_data_set(ed->collection->script, ed);
embryo_program_max_cycle_run_set(ed->collection->script, 5000000);
embryo_program_run(ed->collection->script, fn);
embryo_program_data_set(ed->collection->script, pdata);
embryo_program_vm_pop(ed->collection->script);
_edje_recalc(ed);
}
return ECORE_CALLBACK_CANCEL;
}
示例10: news_config_item_del
void
news_config_item_del(News_Config_Item *nic)
{
eina_stringshare_del(nic->id);
while(eina_list_count(nic->feed_refs))
{
News_Feed_Ref *fr;
fr = eina_list_data_get(nic->feed_refs);
eina_stringshare_del(fr->name);
nic->feed_refs = eina_list_remove(nic->feed_refs, fr);
}
news->config->items = eina_list_remove(news->config->items, nic);
free(nic);
}
示例11: _ecore_evas_buffer_free
static void
_ecore_evas_buffer_free(Ecore_Evas *ee)
{
Ecore_Evas_Engine_Buffer_Data *bdata = ee->engine.data;
if (!bdata) return;
if (bdata->image)
{
Ecore_Evas *ee2;
ee2 = evas_object_data_get(bdata->image, "Ecore_Evas_Parent");
evas_object_del(bdata->image);
if (ee2)
ee2->sub_ecore_evas = eina_list_remove(ee2->sub_ecore_evas, ee);
}
else
{
bdata->free_func(bdata->data, bdata->pixels);
}
free(bdata);
ee->engine.data = NULL;
ecore_event_evas_shutdown();
}
示例12: _cb_feed_add
static void
_cb_feed_add(void *data, void *data2)
{
E_Config_Dialog_Data *cfdata;
News_Item *ni;
News_Feed *f;
Eina_List *l;
cfdata = data;
ni = cfdata->ni;
for (l=cfdata->ilist_feeds_sel; l; l=eina_list_next(l))
{
f = l->data;
if (f->item) continue;
if (news_feed_attach(f, NULL, ni))
news_feed_obj_refresh(f, 1, 1);
/* dont reselect this feed */
cfdata->ilist_feeds_sel = eina_list_remove(cfdata->ilist_feeds_sel, f);
}
news_item_refresh(ni, 1, 0, 0);
news_feed_list_ui_refresh();
news_viewer_refresh(ni->viewer);
news_config_save();
}
示例13: enlil_iptc_job_prepend
Enlil_IPTC_Job *
enlil_iptc_job_prepend(Enlil_Photo *photo,
Enlil_IPTC_Done_Cb cb,
void *data)
{
ASSERT_RETURN(photo != NULL);
Eina_List *l;
Enlil_IPTC_Job *job;
EINA_LIST_FOREACH(l_jobs, l, job)
if(job->photo == photo)
break;
if(!job)
{
job = calloc(1, sizeof(Enlil_IPTC_Job));
job->photo = photo;
job->cb = cb;
job->data = data;
}
else
l_jobs = eina_list_remove(l_jobs, job);
l_jobs = eina_list_prepend(l_jobs, job);
_job_next();
return job;
}
示例14: _job_next
static void
_job_next(void)
{
char buf[PATH_MAX];
if(running)
return;
if(!l_jobs)
return;
running = 1;
Enlil_IPTC_Job *job = eina_list_data_get(l_jobs);
l_jobs = eina_list_remove(l_jobs, job);
job_current = job;
snprintf(buf, PATH_MAX, "%s/%s", enlil_photo_path_get(job_current->photo),
enlil_photo_file_name_get(job_current->photo));
Enlil_IPTC_Thread_Data *data = calloc(1, sizeof(Enlil_IPTC_Thread_Data));
data->file = eina_stringshare_add(buf);
ecore_thread_run(_iptc_thread, _end_cb, NULL, data);
running = 1;
}
示例15: _cb_fd_handler
static Eina_Bool
_cb_fd_handler(void *data,
Ecore_Fd_Handler *fd_handler)
{
struct e_mixer_callback_desc *desc;
desc = data;
if (ecore_main_fd_handler_active_get(fd_handler, ECORE_FD_ERROR))
{
desc->handlers = eina_list_remove(desc->handlers, fd_handler);
if (!desc->handlers)
{
E_Mixer_System *s;
int (*f)(void *,
E_Mixer_System *);
void *d;
s = desc->self;
f = desc->func;
d = desc->data;
_mixer_callback_del(s, desc);
_mixer_callback_add(s, f, d);
}
return ECORE_CALLBACK_CANCEL;
}
if (!desc->idler)
desc->idler = ecore_idler_add(_cb_dispatch, desc);
return ECORE_CALLBACK_RENEW;
}