Remove unnecessary dummy devices 29/286429/1 accepted/tizen/unified/20230109.151013
authorWootak Jung <wootak.jung@samsung.com>
Fri, 6 Jan 2023 01:17:19 +0000 (10:17 +0900)
committerWootak Jung <wootak.jung@samsung.com>
Fri, 6 Jan 2023 01:17:33 +0000 (10:17 +0900)
Change-Id: I068707f212898cc0c23b28d8e751c4bb64cf37e5
Signed-off-by: Wootak Jung <wootak.jung@samsung.com>
SettingBluetooth/SettingBluetooth/Model/BtDevice.cs
SettingBluetooth/SettingBluetooth/View/BtDeviceView.cs
packaging/org.tizen.cssetting-bluetooth-1.0.0.tpk

index 7596cf360e8f349dcb6b2464d1386f597ce259a1..ce42ce00086edad84f91db912ecffab44fd7baa9 100644 (file)
@@ -128,15 +128,6 @@ namespace SettingBluetooth.Model
             }
         }
 
-        // for dummy instance (No devices found, Paired device)
-        internal BtDevice(string address, bool isPaired)
-        {
-            mAddress = address;
-            mName = address;
-            mIsPaired = isPaired;
-            mDeviceState = isPaired ? BtDeviceState.Paired : BtDeviceState.Idle;
-        }
-
         internal string Address
         {
             get
index 6aaed09e7ab84a571125723415a9b6464fde915d..e0dfc7b94a8e3907d5d8a407ef039cf339a29215 100644 (file)
@@ -291,7 +291,10 @@ namespace SettingBluetooth
 
         internal void RemoveAllSearchedDevices()
         {
-            mSearched.Clear();
+            if (mSearched.Count > 0)
+            {
+                mSearched.Clear();
+            }
         }
 
         internal Device FindInSearched(BtDevice btDevice)
@@ -447,8 +450,6 @@ namespace SettingBluetooth
 
             mDeviceSource = new DeviceSource();
             mDeviceView = CreateCollectionView(mDeviceSource);
-            mDeviceSource.AddToPaired(new BtDevice("dummy paired device", true)); // dummy device
-            mDeviceSource.AddToSearched(new BtDevice("dummy paired device", false)); // dummy device
             view.Add(mDeviceView);
             BtModel.GetBondedDevices();
 
index 94c2a619aaf2731db0eafa867590e6cb75c081a4..10fdd7c62396cd177a61b8b2d78689f6ccf70605 100644 (file)
Binary files a/packaging/org.tizen.cssetting-bluetooth-1.0.0.tpk and b/packaging/org.tizen.cssetting-bluetooth-1.0.0.tpk differ