public static void StartRefreshDeviceList() { if (!IsRefreshing) { #pragma warning disable CS0162 if (isLogging) { Debug.Log(TAG + "StartRefreshDeviceList"); } #pragma warning restore CS0162 IsRefreshing = true; instance.InvokeRepeating("RefreshDeviceList", deviceRefreshTime, deviceRefreshTime); RefresherList.Clear(); } }
public static void StopRefreshDeviceList() { if (!IsRefreshing) { return; } #pragma warning disable CS0162 if (isLogging) { Debug.Log(TAG + "StopRefreshDeviceList"); } #pragma warning restore CS0162 if (RefresherList.Count == 0 || !IsScanning) { IsRefreshing = false; instance.CancelInvoke("RefreshDeviceList"); } RefresherList.Clear(); IsRefreshingRssiBlocked = false; instance.CancelInvoke("SetisRefreshingRssiBlocked"); }