--- src/adapter.c | 8 ++++++++ src/adapter.h | 1 + 2 files changed, 9 insertions(+) diff --git a/src/adapter.c b/src/adapter.c index cd104a1..2338e60 100644 --- a/src/adapter.c +++ b/src/adapter.c @@ -2772,6 +2772,14 @@ bool btd_adapter_get_powered(struct btd_adapter *adapter) return false; } +bool btd_adapter_get_connectable(struct btd_adapter *adapter) +{ + if (adapter->current_settings & MGMT_SETTING_CONNECTABLE) + return true; + + return false; +} + uint32_t btd_adapter_get_class(struct btd_adapter *adapter) { return adapter->dev_class; diff --git a/src/adapter.h b/src/adapter.h index 2610479..8d23a64 100644 --- a/src/adapter.h +++ b/src/adapter.h @@ -87,6 +87,7 @@ void adapter_foreach(adapter_cb func, gpointer user_data); bool btd_adapter_get_pairable(struct btd_adapter *adapter); bool btd_adapter_get_powered(struct btd_adapter *adapter); +bool btd_adapter_get_connectable(struct btd_adapter *adapter); uint32_t btd_adapter_get_class(struct btd_adapter *adapter); const char *btd_adapter_get_name(struct btd_adapter *adapter); -- 1.8.1.1 -- To unsubscribe from this list: send the line "unsubscribe linux-bluetooth" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html