update battery module to use new ecore poller functions and avoid destroying poller...
authorMike Blumenkrantz <michael.blumenkrantz@gmail.com>
Wed, 19 May 2010 09:17:09 +0000 (09:17 +0000)
committerMike Blumenkrantz <michael.blumenkrantz@gmail.com>
Wed, 19 May 2010 09:17:09 +0000 (09:17 +0000)
SVN revision: 49003

src/modules/battery/e_mod_udev.c

index 63fa1ae..233edec 100644 (file)
@@ -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)