public void Dispose() { if (Interlocked.Increment(ref _disposeCounter) != 1) { return; } Adapter.Dispose(); }
public void Dispose() { if (Interlocked.Increment(ref _disposeCounter) != 1) { return; } try { _adapter.Dispose(); } finally { GC.SuppressFinalize(this); } }
private void PopulateDriverList() { mAdapter.Dispose(); mAdapter = null; if (driverRepository == null) { driverRepository = new DriverRepository(); } mDrivers = driverRepository.GetAllDrivers(); mAdapter = new DriverSpinnerAdapter(this, Resource.Layout.DriverJourneyListViewRow, mDrivers, mDriverSelected); mListView.Adapter = mAdapter; }
public void Dispose() { _adapter.Dispose(); }