client: Add network_get_type
This commit is contained in:
parent
8fd8852bf1
commit
b64ba2ba0e
|
@ -55,6 +55,17 @@ bool network_is_connected(const char *path)
|
||||||
return network->connected;
|
return network->connected;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
const char *network_get_type(const char *path)
|
||||||
|
{
|
||||||
|
const struct network *network;
|
||||||
|
const struct proxy_interface *proxy =
|
||||||
|
proxy_interface_find(IWD_NETWORK_INTERFACE, path);
|
||||||
|
|
||||||
|
network = proxy_interface_get_data(proxy);
|
||||||
|
|
||||||
|
return network->type;
|
||||||
|
}
|
||||||
|
|
||||||
void network_connect(const struct proxy_interface *proxy)
|
void network_connect(const struct proxy_interface *proxy)
|
||||||
{
|
{
|
||||||
if (!proxy)
|
if (!proxy)
|
||||||
|
|
|
@ -26,6 +26,7 @@ struct network_args {
|
||||||
};
|
};
|
||||||
|
|
||||||
bool network_is_connected(const char *path);
|
bool network_is_connected(const char *path);
|
||||||
|
const char *network_get_type(const char *path);
|
||||||
void network_connect(const struct proxy_interface *proxy);
|
void network_connect(const struct proxy_interface *proxy);
|
||||||
|
|
||||||
char *network_name_completion(const struct proxy_interface *device,
|
char *network_name_completion(const struct proxy_interface *device,
|
||||||
|
|
Loading…
Reference in New Issue