private async void NextKata() { try { if (mCollection.Count == 0) { return; } await SwipeAnimateEffect(false); CurrentPlayIndex++; if (CurrentPlayIndex > (mCollection.Count - 1)) { CurrentPlayIndex = 0; } item = mCollection[CurrentPlayIndex]; KataKor.Text = item.KataKor; KataIndo.Text = item.KataIndo; KataEng.Text = item.KataEng; PlaySuaraSound(); if (!bIsAutoPlay) { CounterTimerLabel(); } } catch { } }
public void UpdateKalimat(string sKataIndo, string sKataIndoTambah) { try { KataItems item = mCollection[CurrentPlayIndex]; item.KataIndo = sKataIndo; item.lembutlidah = sKataIndoTambah; mCollection[CurrentPlayIndex] = item; CurrentKata(); }catch { } }
private async void NextKata() { try { if (mCollection.Count == 0) { return; } await SwipeAnimateEffect(false); /* * await Kataview.TranslateTo(300, 0); * await Kataview.FadeTo(0, 1); * await Kataview.TranslateTo(-300, 0); * await Kataview.FadeTo(1, 1); * await Kataview.TranslateTo(0, 0); */ CurrentPlayIndex++; if (CurrentPlayIndex > (mCollection.Count - 1)) { CurrentPlayIndex = 0; } //Debug.WriteLine(CurrentPlayIndex.ToString()); item = mCollection[CurrentPlayIndex]; KataIndo.Text = item.KataIndo; KataKor.Text = item.KataKor; lembutlidah.Text = item.lembutlidah; //종료시 저장 //App.PlayNumberIndex = CurrentPlayIndex; //MainPage.GetMainPageInstance().SetPlayKataIndex(CurrentPlayIndex); if (!bIsAutoPlay) { CounterTimerLabel(); } PlaySuaraSound(lembutlidah.Text); } catch {} }
private async void CurrentKata() { try { if (CurrentPlayIndex < 0 || mCollection.Count == 0) { return; } item = mCollection[CurrentPlayIndex]; KataIndo.Text = item.KataIndo; KataKor.Text = item.KataKor; lembutlidah.Text = item.lembutlidah; CounterTimerLabel(); PlaySuaraSound(lembutlidah.Text); } catch {} }