core: rename nm_device_can_activate -> nm_device_is_available

Becuase when the device is in >= DISCONNECTED state, that already
means it can activate if a connection is available.
This commit is contained in:
Dan Williams
2009-09-14 13:33:06 -07:00
parent 393bdd3737
commit 7a2e2cfda3
5 changed files with 12 additions and 12 deletions

View File

@@ -390,10 +390,10 @@ nm_device_get_act_request (NMDevice *self)
gboolean
nm_device_can_activate (NMDevice *self)
nm_device_is_available (NMDevice *self)
{
if (NM_DEVICE_GET_CLASS (self)->can_activate)
return NM_DEVICE_GET_CLASS (self)->can_activate (self);
if (NM_DEVICE_GET_CLASS (self)->is_available)
return NM_DEVICE_GET_CLASS (self)->is_available (self);
return TRUE;
}
@@ -3077,7 +3077,7 @@ nm_device_state_changed (NMDevice *device,
* we can't change states again from the state handler for a variety of
* reasons.
*/
if (nm_device_can_activate (device))
if (nm_device_is_available (device))
priv->unavailable_to_disconnected_id = g_idle_add (unavailable_to_disconnected, device);
break;
case NM_DEVICE_STATE_ACTIVATED: