From 131b93231a299ecd18475df414b5afc789473ba7 Mon Sep 17 00:00:00 2001 From: Oliver Ruiz Dorantes Date: Tue, 24 Mar 2009 21:27:53 +0000 Subject: [PATCH] Add string with mtu and max packets the device can hold git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@29681 a95241bf-73f2-0310-859d-f6bbb57e9c96 --- .../bluetooth/BluetoothDeviceView.cpp | 20 +++++++++++++++++-- src/preferences/bluetooth/InquiryPanel.cpp | 5 ++++- 2 files changed, 22 insertions(+), 3 deletions(-) diff --git a/src/preferences/bluetooth/BluetoothDeviceView.cpp b/src/preferences/bluetooth/BluetoothDeviceView.cpp index 5ae9a683c9..36c2679303 100644 --- a/src/preferences/bluetooth/BluetoothDeviceView.cpp +++ b/src/preferences/bluetooth/BluetoothDeviceView.cpp @@ -35,9 +35,10 @@ BluetoothDeviceView::BluetoothDeviceView(BRect frame, BluetoothDevice* bDevice, fClass = new BStringView("class", "- / -"); - fHCIVersionProperties = new BStringView("version", ""); + fHCIVersionProperties = new BStringView("hci", ""); fLMPVersionProperties = new BStringView("lmp", ""); fManufacturerProperties = new BStringView("manufacturer", ""); + fBuffersProperties = new BStringView("buffers", ""); fIcon = new BitmapView(new BBitmap(BRect(0, 0, 64 - 1, 64 - 1), B_RGBA32)); @@ -61,7 +62,9 @@ BluetoothDeviceView::BluetoothDeviceView(BRect frame, BluetoothDevice* bDevice, .AddGlue() .Add(fLMPVersionProperties) .AddGlue() - .Add(fManufacturerProperties) + .Add(fManufacturerProperties) + .AddGlue() + .Add(fBuffersProperties) .SetInsets(5, 25, 25, 25) ) .Add(BSpaceLayoutItem::CreateHorizontalStrut(10) @@ -119,6 +122,19 @@ BluetoothDeviceView::SetBluetoothDevice(BluetoothDevice* bDevice) if (bDevice->GetProperty("manufacturer", &value) == B_OK) str << "Manufacturer: " << GetManufacturer(value); fManufacturerProperties->SetText(str.String()); + + str = ""; + if (bDevice->GetProperty("acl_mtu", &value) == B_OK) + str << "ACL mtu: " << value; + if (bDevice->GetProperty("acl_max_pkt", &value) == B_OK) + str << " packets: " << value; + if (bDevice->GetProperty("sco_mtu", &value) == B_OK) + str << " SCO mtu: " << value; + if (bDevice->GetProperty("sco_max_pkt", &value) == B_OK) + str << " packets: " << value; + + fBuffersProperties->SetText(str.String()); + } diff --git a/src/preferences/bluetooth/InquiryPanel.cpp b/src/preferences/bluetooth/InquiryPanel.cpp index f753826f48..f8a9ef959f 100644 --- a/src/preferences/bluetooth/InquiryPanel.cpp +++ b/src/preferences/bluetooth/InquiryPanel.cpp @@ -121,7 +121,10 @@ InquiryPanel::InquiryPanel(BRect frame, LocalDevice* lDevice) if (fLocalDevice != NULL) { fMessage->SetText("Check that the bluetooth capabilities of your remote device" - " are activated. Press Inquiry to start scanning"); + " are activated. Press Inquiry to start scanning. The needed time" + " for the retrieval of the names is unknown, although should not" + " take more than 3 seconds per device. Afterwards you will be able" + " to add them to your main list, where you will be able to pair with them"); fInquiryButton->SetEnabled(true); fDiscoveryAgent = fLocalDevice->GetDiscoveryAgent(); fDiscoveryListener = new PanelDiscoveryListener(this);