6
Chcę ukryć dicelayout (dicelout był w mainboardlinear), ale po zakończeniu animacji ekran migał z powodu View.GONE! jeśli ustawię setfillafter na true i clear View.GONE, nie mam już problemu z lampą błyskową, ale mój scrollview w mainboardlinear nie może być przewijany w tym przypadku!Ukryj widok z animacją i ustaw widoczność, aby zniknął bez błysku ekran
final RelativeLayout rLayout=(RelativeLayout)findViewById(R.id.dicelayout);
Animation animation=new TranslateAnimation(0, 0, 0, -rLayout.getHeight());
animation.setFillAfter(false);
animation.setFillBefore(true);
animation.setDuration(1000);
((LinearLayout)findViewById(R.id.mainboardlinear)).startAnimation(animation);
Thread t=new Thread(new Runnable() {
public void run() {
try {
Thread.sleep(999);
runOnUiThread(new Runnable() {
public void run() {
rLayout.setVisibility(View.GONE);
}
});
} catch (InterruptedException e) {
// TODO Auto-generated catch block
e.printStackTrace();
}
}
});
t.start();