Ejemplo n.º 1
0
        private async Task ReloadAdapter()
        {
            await Task.Run(() =>
            {
                var list = SongLoader.GetAllSongs(Activity);
                _songListAdapter.UpdateData(list);
            });

            _songListAdapter.NotifyDataSetChanged();
        }
Ejemplo n.º 2
0
        private async Task LoadSong()
        {
            if (Activity is null)
            {
                return;
            }

            await Task.Run(() =>
            {
                _songListAdapter = new SongListAdapter((AppCompatActivity)Activity, SongLoader.GetAllSongs(Activity), false);
            });

            _recyclerView.AddItemDecoration(new DividerItemDecoration(Activity, DividerItemDecoration.Vertical));
        }