From: Mike Blumenkrantz Date: Wed, 19 May 2010 09:17:09 +0000 (+0000) Subject: update battery module to use new ecore poller functions and avoid destroying poller... X-Git-Tag: submit/efl/20131021.015651~7426 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=9a864815ef6f89c462b07293f78f4b7c8eec066f;p=platform%2Fupstream%2Fenlightenment.git update battery module to use new ecore poller functions and avoid destroying poller objects every few seconds SVN revision: 49003 --- diff --git a/src/modules/battery/e_mod_udev.c b/src/modules/battery/e_mod_udev.c index 63fa1ae..233edec 100644 --- a/src/modules/battery/e_mod_udev.c +++ b/src/modules/battery/e_mod_udev.c @@ -202,9 +202,8 @@ _battery_udev_battery_update(const char *syspath, Battery *bat) if (!(bat = _battery_battery_find(syspath))) return _battery_udev_battery_add(syspath); } - /* reset the poller */ - ecore_poller_del(bat->poll); - bat->poll = ecore_poller_add(ECORE_POLLER_CORE, battery_config->poll_interval, _battery_udev_battery_update_poll, bat); + /* update the poller interval */ + ecore_poller_poller_interval_set(bat->poll, battery_config->poll_interval); GET_NUM(bat, present, POWER_SUPPLY_PRESENT); if (!bat->got_prop)