解决#671,蓝牙设备名称只显示一个时需要固定不能,去掉下面横线bug
authorluozheng <1732036298@qq.com>
Sat, 28 Sep 2024 09:05:53 +0000 (17:05 +0800)
committerluozheng <1732036298@qq.com>
Sat, 28 Sep 2024 09:05:53 +0000 (17:05 +0800)
code/sdk/application/wearable/fd230app/nativeui/bluetooth/src/BluetoothItemView.cpp

index 69adb8a..fc5b95f 100644 (file)
@@ -101,8 +101,9 @@ namespace OHOS
             }\r
         }\r
         WEARABLE_LOGE(WEARABLE_LOG_MODULE_APP, "index =  %d", GetViewIndex());\r
-        List<BluetoothCaseInfo> &bluetoothCaseList = BluetoothModel::GetInstance()->GetConnedDevicesCase();\r
-        if (GetViewIndex() == bluetoothCaseList.Size() - 1)\r
+        List<BluetoothCaseInfo> &btConnedDevicesList_ = BluetoothModel::GetInstance()->GetConnedDevicesCase();\r
+        std::list<BluetoothCaseInfo> &btScansDevicesList_ = BluetoothModel::GetInstance()->GetCase();\r
+        if (GetViewIndex() == btConnedDevicesList_.Size() - 1 || GetViewIndex()  == btScansDevicesList_.size() - 1)\r
         {\r
             lineImage.SetVisible(false);\r
         }\r